diff options
Diffstat (limited to 'Master/tlpkg/tlgs/lib')
184 files changed, 0 insertions, 60866 deletions
diff --git a/Master/tlpkg/tlgs/lib/EndOfTask.ps b/Master/tlpkg/tlgs/lib/EndOfTask.ps deleted file mode 100644 index 45a8ca02bfc..00000000000 --- a/Master/tlpkg/tlgs/lib/EndOfTask.ps +++ /dev/null @@ -1 +0,0 @@ -
\ No newline at end of file diff --git a/Master/tlpkg/tlgs/lib/FAPIcidfmap b/Master/tlpkg/tlgs/lib/FAPIcidfmap deleted file mode 100644 index 697a2a17667..00000000000 --- a/Master/tlpkg/tlgs/lib/FAPIcidfmap +++ /dev/null @@ -1,32 +0,0 @@ -%!
-% $Id: FAPIcidfmap 6826 2006-05-31 15:29:52Z leonardo $
-% This is a sample map file for FAPI CID fonts.
-
-%
-% The map is a set of records like this :
-%
-% /CIDfont_name options_dict ;
-%
-% where options_dict is a dictionary with the following entries :
-%
-% Key Type Description
-% Path string Absolute path to font file, or relative path to font file from
-% the GS_EXTFONTPATH value.
-% CIDFontType interger PostScript type for this CID font. Only 0 is currently allowed.
-% Note that this is unrelated to the real type of the font file -
-% the bridge will perform format conversion.
-% FAPI name Name of the renderer to be used with the font. Only /UFST is now allowed.
-% SubfontId integer (optional) Index of the font in font collection, such as FCO or TTC.
-% It is being ignored if /Path doesn't specify a collection.
-% Default value is 0.
-% CSI array Must have strongly 2 elements.
-% The first element of the array specifies Ordering of CIDSystemInfo.
-% The second element specifies Supplement of CIDSystemInfo.
-%
-% Use regular Postscript syntax.
-%
-% Examples :
-%
-% /Ryumin-Medium << /Path (msgothic.ttc) /CIDFontType 0 /FAPI /UFST /CSI [(Japan1) 2] >> ;
-% /HeiseiKakuGo-W5 << /Path (F:/WIN2000/Fonts/BATANG.TTC) /CIDFontType 0 /FAPI /UFST /CSI [(Japan1) 2] >> ;
-
diff --git a/Master/tlpkg/tlgs/lib/FAPIconfig b/Master/tlpkg/tlgs/lib/FAPIconfig deleted file mode 100644 index c4e2d781d7c..00000000000 --- a/Master/tlpkg/tlgs/lib/FAPIconfig +++ /dev/null @@ -1,14 +0,0 @@ -%!
-% $Id: FAPIconfig 6870 2006-06-20 16:31:15Z leonardo $
-% This is configuration file for FAPI client.
-
-/FontPath (/Fonts) % A default directory for FAPI-handled font files path in FAPIfontmap.
-/CIDFontPath (/CIDFonts) % A default directory for FAPI-handled CID font files path in FAPIcidfmap.
-/HookDiskFonts [1 2 9 11 42] % FontType values for disk PS fonts to be redirected to FAPI.
-/HookEmbeddedFonts [1 2 9 11 42] % FontType values for embedded PS fonts to be redirected to FAPI.
-
-% Values allowed for HookDiskFonts and HookEmbeddedFonts are 1, 2, 9, 11, 42.
-% "Disk fonts" are fonts being installed to Ghostscript with 'lib/Fontmap' or with GS_FONTPATH,
-% and CID font resource files.
-% "Embedded fonts" are fonts and CID fonts being embedded into a document.
-
diff --git a/Master/tlpkg/tlgs/lib/FAPIconfig-FCO b/Master/tlpkg/tlgs/lib/FAPIconfig-FCO deleted file mode 100644 index 2d6966bf850..00000000000 --- a/Master/tlpkg/tlgs/lib/FAPIconfig-FCO +++ /dev/null @@ -1,14 +0,0 @@ -%!
-% $Id: FAPIconfig-FCO 6998 2006-08-18 04:42:11Z ray $
-% This is configuration file for FAPI client.
-
-/FontPath () % A default directory for FAPI-handled font files path in FAPIfontmap.
-/CIDFontPath () % A default directory for FAPI-handled CID font files path in FAPIcidfmap.
-/HookDiskFonts [] % FontType values for disk PS fonts to be redirected to FAPI.
-/HookEmbeddedFonts [] % FontType values for embedded PS fonts to be redirected to FAPI.
-
-% Values allowed for HookDiskFonts and HookEmbeddedFonts are 1, 2, 9, 11, 42.
-% "Disk fonts" are fonts being installed to Ghostscript with 'lib/Fontmap' or with GS_FONTPATH,
-% and CID font resource files.
-% "Embedded fonts" are fonts and CID fonts being embedded into a document.
-
diff --git a/Master/tlpkg/tlgs/lib/FAPIfontmap b/Master/tlpkg/tlgs/lib/FAPIfontmap deleted file mode 100644 index a3d4ca3f345..00000000000 --- a/Master/tlpkg/tlgs/lib/FAPIfontmap +++ /dev/null @@ -1,33 +0,0 @@ -%!
-% $Id: FAPIfontmap 6870 2006-06-20 16:31:15Z leonardo $
-% This is a sample map file for FAPI fonts.
-
-%
-% The map is a set of records like this :
-%
-% /font_name options_dict ;
-%
-% where options_dict is a dictionary with the following entries :
-%
-% Key Type Description
-% Path string Absolute path to font file, or relative path to font file from
-% the GS_EXTFONTPATH value.
-% FontType interger PostScript type for this font. Only 1 and 42 are currently allowed.
-% Note that this is unrelated to the real type of the font file -
-% the bridge will perform format conversion.
-% FAPI name Name of the renderer to be used with the font. Only /AgfaUFST is now allowed.
-% SubfontId integer (optional) Index of the font in font collection, such as FCO or TTC.
-% It is being ignored if /Path doesn't specify a collection.
-% Default value is 0.
-% Decoding name (optional) The name of a Decoding resource to be used with the font.
-% If specified, "xlatmap" doesn't work for this font.
-%
-% Use regular Postscript syntax.
-%
-% Examples :
-%
-% /ArialTT << /Path (arial.ttf) /FontType 1 /FAPI /UFST >> ;
-% /CourierTT << /Path (F:/WIN2000/Fonts/cour.ttf) /FontType 1 /FAPI /UFST >> ;
-% /FCO1 << /Path (F:/AFPL/ufst/fontdata/MTFONTS/PCLPS3/MT1/PCLP3__G.FCO) /FontType 42 /FAPI /UFST /SubfontId 10 >> ;
-%
-
diff --git a/Master/tlpkg/tlgs/lib/FCOfontmap-PCLPS2 b/Master/tlpkg/tlgs/lib/FCOfontmap-PCLPS2 deleted file mode 100644 index ba7526f13ee..00000000000 --- a/Master/tlpkg/tlgs/lib/FCOfontmap-PCLPS2 +++ /dev/null @@ -1,107 +0,0 @@ -% Copyright (C) 2001, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: FCOfontmap-PCLPS2 8269 2007-10-03 17:37:35Z ray $
-
-% May add general FAPIfontmap records here like this :
-/Wingdings-Regular << /Path FCOfontfile2 /FontType 1 /FAPI /UFST /SubfontId 0 /Encoding /Wingdings /Decoding /FCO_Wingdings>> ;
-
-% Mapping Postscript fonts to pclp2_xj.fco FCO members :
-FCOfontfile ReadFCOfontmap:
-0 Albertus-Medium
-1 Albertus-ExtraBold
-2 AntiqueOlive
-3 AntiqueOlive-Italic
-4 AntiqueOlive-Bold
-5 Arial
-6 Arial-Italic
-7 Arial-Bold
-8 Arial-BoldItalic
-9 Clarendon-Condensed-Bold
-10 Coronet
-11 CourierHP
-12 CourierHP-Italic
-13 CourierHP-Bold
-14 CourierHP-BoldItalic
-15 Garamond-Antiqua
-16 Garamond-Kursiv
-17 Garamond-Halbfett
-18 Garamond-KursivHalbfett
-19 LetterGothic
-20 LetterGothic-Italic
-21 LetterGothic-Bold
-22 Marigold
-23 CGOmega
-24 CGOmega-Italic
-25 CGOmega-Bold
-26 CGOmega-BoldItalic
-27 SymbolMT SymbolEncoding FCO_Symbol
-28 CGTimes
-29 CGTimes-Italic
-30 CGTimes-Bold
-31 CGTimes-BoldItalic
-32 TimesNewRoman
-33 TimesNewRoman-Italic
-34 TimesNewRoman-Bold
-35 TimesNewRoman-BoldItalic
-36 UniversMedium
-37 UniversMedium-Italic
-38 Univers-Bold
-39 Univers-BoldItalic
-40 Univers-Condensed-Medium
-41 Univers-Condensed-MediumItalic
-42 Univers-Condensed-Bold
-43 Univers-Condensed-BoldItalic
-44 Courier-
-45 Courier-Italic
-46 Courier-Bold-
-47 Courier-BoldItalic
-48 AvantGarde-Book
-49 AvantGarde-BookOblique
-50 AvantGarde-Demi
-51 AvantGarde-DemiOblique
-52 Bookman-Light
-53 Bookman-LightItalic
-54 Bookman-Demi
-55 Bookman-DemiItalic
-56 Courier
-57 Courier-Oblique
-58 Courier-Bold
-59 Courier-BoldOblique
-60 Helvetica
-61 Helvetica-Oblique
-62 Helvetica-Bold
-63 Helvetica-BoldOblique
-64 Helvetica-Narrow
-65 Helvetica-Narrow-Oblique
-66 Helvetica-Narrow-Bold
-67 Helvetica-Narrow-BoldOblique
-68 NewCenturySchlbk-Roman
-69 NewCenturySchlbk-Italic
-70 NewCenturySchlbk-Bold
-71 NewCenturySchlbk-BoldItalic
-72 Palatino-Roman
-73 Palatino-Italic
-74 Palatino-Bold
-75 Palatino-BoldItalic
-76 Symbol SymbolEncoding FCO_Symbol
-77 Times-Roman
-78 Times-Italic
-79 Times-Bold
-80 Times-BoldItalic
-81 ZapfChancery-MediumItalic
-82 ZapfDingbats DingbatsEncoding FCO_Dingbats
-EndFCOfontmap
-%EOF
diff --git a/Master/tlpkg/tlgs/lib/FCOfontmap-PCLPS3 b/Master/tlpkg/tlgs/lib/FCOfontmap-PCLPS3 deleted file mode 100644 index f84fb72417d..00000000000 --- a/Master/tlpkg/tlgs/lib/FCOfontmap-PCLPS3 +++ /dev/null @@ -1,198 +0,0 @@ -% Copyright (C) 2001, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: FCOfontmap-PCLPS3 8269 2007-10-03 17:37:35Z ray $
-
-% May add general FAPIfontmap records here like this :
-/Wingdings-Regular << /Path FCOfontfile2 /FontType 1 /FAPI /UFST /SubfontId 0 /Encoding /Wingdings /Decoding /FCO_Wingdings>> ;
-
-% Mapping Postscript fonts to pclp2_xj.fco FCO members :
-FCOfontfile ReadFCOfontmap:
-0 Albertus-Medium
-1 Albertus-ExtraBold
-2 AntiqueOlive
-3 AntiqueOlive-Italic
-4 AntiqueOlive-Bold
-5 Arial
-6 Arial-Italic
-7 Arial-Bold
-8 Arial-BoldItalic
-9 Clarendon-Condensed-Bold
-10 Coronet
-11 CourierHP
-12 CourierHP-Italic
-13 CourierHP-Bold
-14 CourierHP-BoldItalic
-15 Garamond-Antiqua
-16 Garamond-Kursiv
-17 Garamond-Halbfett
-18 Garamond-KursivHalbfett
-19 LetterGothic
-20 LetterGothic-Italic
-21 LetterGothic-Bold
-22 Marigold
-23 CGOmega
-24 CGOmega-Italic
-25 CGOmega-Bold
-26 CGOmega-BoldItalic
-27 SymbolMT SymbolEncoding FCO_Symbol
-28 CGTimes
-29 CGTimes-Italic
-30 CGTimes-Bold
-31 CGTimes-BoldItalic
-32 TimesNewRoman
-33 TimesNewRoman-Italic
-34 TimesNewRoman-Bold
-35 TimesNewRoman-BoldItalic
-36 Univers-Medium
-37 Univers-MediumItalic
-38 Univers-Bold
-39 Univers-BoldItalic
-40 Univers-Condensed-Medium
-41 Univers-Condensed-MediumItalic
-42 Univers-Condensed-Bold
-43 Univers-Condensed-BoldItalic
-44 Courier
-45 Courier-Italic
-46 Courier-Bold
-47 Courier-BoldItalic
-48 AlbertusMT-Light
-49 AlbertusMT
-50 AlbertusMT-Italic
-51 AntiqueOlive-Roman
-52 AntiqueOlive-Italic
-53 AntiqueOlive-Bold
-54 AntiqueOlive-Compact
-55 AvantGarde-Book
-56 AvantGarde-BookOblique
-57 AvantGarde-Demi
-58 AvantGarde-DemiOblique
-59 Bodoni
-60 Bodoni-Italic
-61 Bodoni-Bold
-62 Bodoni-BoldItalic
-63 Bodoni-Poster
-64 Bodoni-PosterCompressed
-65 Bookman-Light
-66 Bookman-LightItalic
-67 Bookman-Demi
-68 Bookman-DemiItalic
-69 Candid
-70 Apple-Chancery
-71 Chicago
-72 Clarendon-Light
-73 Clarendon
-74 Clarendon-Bold
-75 CooperBlack
-76 CooperBlack-Italic
-77 Copperplate-ThirtyTwoBC
-78 Copperplate-ThirtyThreeBC
-79 Coronet-Regular
-80 Courier
-81 Courier-Oblique
-82 Courier-Bold
-83 Courier-BoldOblique
-84 Eurostile
-85 Eurostile-Bold
-86 Eurostile-ExtendedTwo
-87 Eurostile-BoldExtendedTwo
-88 StempelGaramond-Roman
-89 StempelGaramond-Italic
-90 StempelGaramond-Bold
-91 StempelGaramond-BoldItalic
-92 Geneva
-93 GillSans-Light
-94 GillSans-LightItalic
-95 GillSans
-96 GillSans-Italic
-97 GillSans-Bold
-98 GillSans-BoldItalic
-99 GillSans-ExtraBold
-100 GillSans-Condensed
-101 GillSans-BoldCondensed
-102 Goudy
-103 Goudy-Italic
-104 Goudy-Bold
-105 Goudy-BoldItalic
-106 Goudy-ExtraBold
-107 Helvetica-Condensed
-108 Helvetica-Condensed-Oblique
-109 Helvetica-Condensed-Bold
-110 Helvetica-Condensed-BoldObl
-111 Helvetica
-112 Helvetica-Oblique
-113 Helvetica-Bold
-114 Helvetica-BoldOblique
-115 Helvetica-Narrow
-116 Helvetica-Narrow-Oblique
-117 Helvetica-Narrow-Bold
-118 Helvetica-Narrow-BoldOblique
-119 HoeflerText-Regular
-120 HoeflerText-Italic
-121 HoeflerText-Black
-122 HoeflerText-BlackItalic
-123 HoeflerText-Ornaments
-124 JoannaMT
-125 JoannaMT-Italic
-126 JoannaMT-Bold
-127 JoannaMT-BoldItalic
-128 LetterGothic
-129 LetterGothic-Slanted
-130 LetterGothic-Bold
-131 LetterGothic-BoldSlanted
-132 LubalinGraph-Book
-133 LubalinGraph-BookOblique
-134 LubalinGraph-Demi
-135 LubalinGraph-DemiOblique
-136 Monaco
-137 MonaLisa-Recut
-138 NewYork
-139 NewCenturySchlbk-Roman
-140 NewCenturySchlbk-Italic
-141 NewCenturySchlbk-Bold
-142 NewCenturySchlbk-BoldItalic
-143 Optima
-144 Optima-Italic
-145 Optima-Bold
-146 Optima-BoldItalic
-147 Oxford
-148 Palatino-Roman
-149 Palatino-Italic
-150 Palatino-Bold
-151 Palatino-BoldItalic
-152 Symbol SymbolEncoding FCO_Symbol
-153 Taffy
-154 Times-Roman
-155 Times-Italic
-156 Times-Bold
-157 Times-BoldItalic
-158 Univers
-159 Univers-Oblique
-160 Univers-Bold
-161 Univers-BoldOblique
-162 Univers-Condensed
-163 Univers-CondensedOblique
-164 Univers-CondensedBold
-165 Univers-CondensedBoldOblique
-166 Univers-Light
-167 Univers-LightOblique
-168 Univers-Extended
-169 Univers-ExtendedObl
-170 Univers-BoldExt
-171 Univers-BoldExtObl
-172 ZapfChancery-MediumItalic
-173 ZapfDingbats DingbatsEncoding FCO_Dingbats
-EndFCOfontmap
-%EOF
diff --git a/Master/tlpkg/tlgs/lib/FCOfontmap-PS3 b/Master/tlpkg/tlgs/lib/FCOfontmap-PS3 deleted file mode 100644 index ec5f91e3747..00000000000 --- a/Master/tlpkg/tlgs/lib/FCOfontmap-PS3 +++ /dev/null @@ -1,159 +0,0 @@ -% Copyright (C) 2001, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: FCOfontmap-PS3 8269 2007-10-03 17:37:35Z ray $
-
-% May add general FAPIfontmap records here like this :
-/Wingdings-Regular << /Path FCOfontfile2 /FontType 1 /FAPI /UFST /SubfontId 0 /Encoding /Wingdings /Decoding /FCO_Wingdings>> ;
-
-% Mapping Postscript fonts to ps3___xh.fco FCO members :
-FCOfontfile ReadFCOfontmap:
-0 AlbertusMT-Light
-1 AlbertusMT
-2 AlbertusMT-Italic
-3 AntiqueOlive-Roman
-4 AntiqueOlive-Italic
-5 AntiqueOlive-Bold
-6 AntiqueOlive-Compact
-7 ArialMT
-8 Arial-ItalicMT
-9 Arial-BoldMT
-10 Arial-BoldItalicMT
-11 AvantGarde-Book
-12 AvantGarde-BookOblique
-13 AvantGarde-Demi
-14 AvantGarde-DemiOblique
-15 Bodoni
-16 Bodoni-Italic
-17 Bodoni-Bold
-18 Bodoni-BoldItalic
-19 Bodoni-Poster
-20 Bodoni-PosterCompressed
-21 Bookman-Light
-22 Bookman-LightItalic
-23 Bookman-Demi
-24 Bookman-DemiItalic
-% 25 Candid % Disabled due to unknown glyph names.
-26 Apple-Chancery
-27 Chicago
-28 Clarendon-Light
-29 Clarendon
-30 Clarendon-Bold
-31 CooperBlack
-32 CooperBlack-Italic
-33 Copperplate-ThirtyTwoBC
-34 Copperplate-ThirtyThreeBC
-35 Coronet-Regular
-36 Courier
-37 Courier-Oblique
-38 Courier-Bold
-39 Courier-BoldOblique
-40 Eurostile
-41 Eurostile-Bold
-42 Eurostile-ExtendedTwo
-43 Eurostile-BoldExtendedTwo
-44 StempelGaramond-Roman
-45 StempelGaramond-Italic
-46 StempelGaramond-Bold
-47 StempelGaramond-BoldItalic
-48 Geneva
-49 GillSans-Light
-50 GillSans-LightItalic
-51 GillSans
-52 GillSans-Italic
-53 GillSans-Bold
-54 GillSans-BoldItalic
-55 GillSans-ExtraBold
-56 GillSans-Condensed
-57 GillSans-BoldCondensed
-58 Goudy
-59 Goudy-Italic
-60 Goudy-Bold
-61 Goudy-BoldItalic
-62 Goudy-ExtraBold
-63 Helvetica-Condensed
-64 Helvetica-Condensed-Oblique
-65 Helvetica-Condensed-Bold
-66 Helvetica-Condensed-BoldObl
-67 Helvetica
-68 Helvetica-Oblique
-69 Helvetica-Bold
-70 Helvetica-BoldOblique
-71 Helvetica-Narrow
-72 Helvetica-Narrow-Oblique
-73 Helvetica-Narrow-Bold
-74 Helvetica-Narrow-BdOblique
-75 HoeflerText-Regular
-76 HoeflerText-Italic
-77 HoeflerText-Black
-78 HoeflerText-BlackItalic
-79 HoeflerText-Ornaments
-80 JoannaMT
-81 JoannaMT-Italic
-82 JoannaMT-Bold
-83 JoannaMT-BoldItalic
-84 LetterGothic
-85 LetterGothic-Slanted
-86 LetterGothic-Bold
-87 LetterGothic-BoldSlanted
-88 LubalinGraph-Book
-89 LubalinGraph-BookOblique
-90 LubalinGraph-Demi
-91 LubalinGraph-DemiOblique
-92 Marigold
-93 Monaco
-94 MonaLisa-Recut
-95 NewYork
-96 NewCenturySchlbk-Roman
-97 NewCenturySchlbk-Italic
-98 NewCenturySchlbk-Bold
-99 NewCenturySchlbk-BoldItalic
-100 Optima
-101 Optima-Italic
-102 Optima-Bold
-103 Optima-BoldItalic
-104 Oxford
-105 Palatino-Roman
-106 Palatino-Italic
-107 Palatino-Bold
-108 Palatino-BoldItalic
-109 Symbol SymbolEncoding FCO_Symbol
-110 Taffy
-111 Times-Roman
-112 Times-Italic
-113 Times-Bold
-114 Times-BoldItalic
-115 TimesNewRomanPSMT
-116 TimesNewRomanPS-ItalicMT
-117 TimesNewRomanPS-BoldMT
-118 TimesNewRomanPS-BdItMT
-119 Univers
-120 Univers-Oblique
-121 Univers-Bold
-122 Univers-BoldOblique
-123 Univers-Condensed
-124 Univers-CondensedOblique
-125 Univers-CondensedBold
-126 Univers-CondensedBdOblique
-127 Univers-Light
-128 Univers-LightOblique
-129 Univers-Extended
-130 Univers-ExtendedObl
-131 Univers-BoldExt
-132 Univers-BoldExtObl
-133 ZapfChancery-MediumItalic
-134 ZapfDingbats DingbatsEncoding FCO_Dingbats
-EndFCOfontmap
-%EOF
diff --git a/Master/tlpkg/tlgs/lib/Fontmap b/Master/tlpkg/tlgs/lib/Fontmap deleted file mode 100644 index 300f6290eac..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap +++ /dev/null @@ -1,8 +0,0 @@ -%!
-%% $Id$
-
-% See Fontmap.GS for the syntax of real Fontmap files.
-%% Replace 1 (Fontmap.GS)
-
-%(Fontmap.GS) .runlibfile
-(Fontmap.TeXLive) .runlibfile
diff --git a/Master/tlpkg/tlgs/lib/Fontmap.ATB b/Master/tlpkg/tlgs/lib/Fontmap.ATB deleted file mode 100644 index e4f8d61c837..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.ATB +++ /dev/null @@ -1,168 +0,0 @@ -% Copyright (C) 1994 Aladdin Enterprises. All rights reserved. -% -% This software is provided AS-IS with no warranty, either express or -% implied. -% -% This software is distributed under license and may not be copied, -% modified or distributed except as expressly authorized under the terms -% of the license contained in the file LICENSE in this distribution. -% -% For more information about licensing, please refer to -% http://www.ghostscript.com/licensing/. For information on -% commercial licensing, go to http://www.artifex.com/licensing/ or -% contact Artifex Software, Inc., 101 Lucas Valley Road #110, -% San Rafael, CA 94903, U.S.A., +1(415)492-9861. - -% $Id: Fontmap.ATB 6300 2005-12-28 19:56:24Z giles $ -% Fontmap.ATB - an alternative Fontmap for Ghostscript, -% suitable for use with the 65 Adobe Type Manager fonts -% supplied with Adobe Type Basics. - -% Before you use ATM fonts with Ghostscript, please read carefully -% the license that accompanies the ATM fonts; neither Aladdin Enterprises -% nor any other distributor of Ghostscript takes any responsibility for -% any possible violations of such licenses. - -% The 65 Adobe Type Basics ATM fonts - -%disk 1 -/Bookman-Light (bkl_____.pfb) ; -/Bookman-Demi (bkd_____.pfb) ; -/Bookman-DemiItalic (bkdi____.pfb) ; -/Bookman-LightItalic (bkli____.pfb) ; -/Courier (com_____.pfb) ; -/Courier-Bold (cob_____.pfb) ; -/Courier-BoldOblique (cobo____.pfb) ; -/Courier-Oblique (coo_____.pfb) ; -/Helvetica (hv______.pfb) ; -/Helvetica-Bold (hvb_____.pfb) ; -/Helvetica-BoldOblique (hvbo____.pfb) ; -/Helvetica-Oblique (hvo_____.pfb) ; -/Helvetica-Narrow (hvn_____.pfb) ; -/Helvetica-Narrow-Bold (hvnb____.pfb) ; -/Helvetica-Narrow-BoldOblique (hvnbo___.pfb) ; -/Helvetica-Narrow-Oblique (hvno____.pfb) ; -/Palatino-Roman (por_____.pfb) ; -/Palatino-Bold (pob_____.pfb) ; -/Palatino-BoldItalic (pobi____.pfb) ; -/Palatino-Italic (poi_____.pfb) ; -/Symbol (sy______.pfb) ; -/Times-Roman (tir_____.pfb) ; -/Times-Bold (tib_____.pfb) ; -/Times-BoldItalic (tibi____.pfb) ; -/Times-Italic (tii_____.pfb) ; - -% disk2 -/AGaramond-Regular (gdrg____.pfb) ; -/AGaramond-Italic (gdi_____.pfb) ; -/AGaramond-Bold (gdb_____.pfb) ; -/AGaramond-BoldItalic (gdbi____.pfb) ; -/Americana (am______.pfb) ; -/Americana-ExtraBold (ameb____.pfb) ; -/AvantGarde-Book (agw_____.pfb) ; -/AvantGarde-Demi (agd_____.pfb) ; -/AvantGarde-DemiOblique (agdo____.pfb) ; -/AvantGarde-BookOblique (agwo____.pfb) ; -/Carta (cr______.pfb) ; -/Kaufmann (kf______.pfb) ; -/Lithos-Regular (lorg____.pfb) ; -/Lithos-Black (lobl____.pfb) ; -/NewCenturySchlbk-Roman (ncr_____.pfb) ; -/NewCenturySchlbk-Bold (ncb_____.pfb) ; -/NewCenturySchlbk-BoldItalic (ncbi____.pfb) ; -/NewCenturySchlbk-Italic (nci_____.pfb) ; -/Parisian (pn______.pfb) ; -/ParkAvenue (pa______.pfb) ; -/Tekton (tkrg____.pfb) ; -/Tekton-Bold (tkb_____.pfb) ; -/Trajan-Bold (tjb_____.pfb) ; -/ZapfChancery-MediumItalic (zcmi____.pfb) ; -/ZapfDingbats (zd______.pfb) ; - -%disk 3 -/ACaslon-Regular (awrg____.pfb) ; -/ACaslon-Semibold (awsb____.pfb) ; -/ACaslon-SemiboldItalic (awsbi___.pfb) ; -/ACaslon-Italic (awi_____.pfb) ; -/Barmeno-Regular (bfrg____.pfb) ; -/Barmeno-Medium (bfm_____.pfb) ; -/Barmeno-Bold (bfb_____.pfb) ; -/Barmeno-ExtraBold (bfeb____.pfb) ; -/Blackoak (bo______.pfb) ; -/Formata-Regular (fmrg____.pfb) ; -/Formata-Medium (fmm_____.pfb) ; -/Formata-MediumItalic (fmmi____.pfb) ; -/Formata-Italic (fmi_____.pfb) ; -/Poetica-SuppOrnaments (pvor____.pfb) ; -/WoodtypeOrnaments-Two (woor2___.pfb) ; - - -% Fonts converted from bitmaps. - -/Charter-Roman (bchr.gsf) ; -/Charter-Italic (bchri.gsf) ; -/Charter-Bold (bchb.gsf) ; -/Charter-BoldItalic (bchbi.gsf) ; - -/ZapfChancery (zcr.gsf) ; -/ZapfChancery-Oblique (zcro.gsf) ; -/ZapfChancery-Bold (zcb.gsf) ; - -% Fonts from the X11R5 distribution. - -/Utopia-Regular (putr.gsf) ; -/Utopia-Italic (putri.gsf) ; -/Utopia-Bold (putb.gsf) ; -/Utopia-BoldItalic (putbi.gsf) ; - -% Shareware fonts. See FONTMAP.GS for the copyright statements. - -/Shareware-Cyrillic-Regular (fcyr.gsf) ; -/Shareware-Cyrillic-Italic (fcyri.gsf) ; -% Aliases -/Cyrillic /Cyrillic-Regular ; -/Cyrillic-Regular /Shareware-Cyrillic-Regular ; -/Cyrillic-Italic /Shareware-Cyrillic-Italic ; - -/Calligraphic-Hiragana (fhirw.gsf) ; -/Calligraphic-Katakana (fkarw.gsf) ; - -% Fonts converted from Hershey outlines. - -/Hershey-Gothic-English (hrge_r.gsf) 4290000 ; -/Hershey-Gothic-English-Bold (hrge_rb.gsf) 4290030 ; -/Hershey-Gothic-English-Oblique (hrge_ro.gsf) 4290010 ; - -/Hershey-Gothic-German (hrgr_r.gsf) 4291000 ; -/Hershey-Gothic-German-Bold (hrgr_rb.gsf) 4291030 ; -/Hershey-Gothic-German-Oblique (hrgr_ro.gsf) 4291010 ; - -/Hershey-Gothic-Italian (hrit_r.gsf) 4292000 ; -/Hershey-Gothic-Italian-Bold (hrit_rb.gsf) 4292030 ; -/Hershey-Gothic-Italian-Oblique (hrit_ro.gsf) 4292010 ; - -/Hershey-Greek-Complex (hrgk_c.gsf) 4293200 ; -/Hershey-Greek-Simplex (hrgk_s.gsf) 4293100 ; - -/Hershey-Plain (hrpl_r.gsf) 4294000 ; -/Hershey-Plain-Bold (hrpl_rb.gsf) 4294030 ; -/Hershey-Plain-Oblique (hrpl_ro.gsf) 4294010 ; -/Hershey-Plain-Simplex (hrpl_s.gsf) 4294100 ; -/Hershey-Plain-Simplex-Bold (hrpl_sb.gsf) 4294130 ; -/Hershey-Plain-Simplex-Bold-Oblique (hrpl_sbo.gsf) 4294140 ; -/Hershey-Plain-Simplex-Oblique (hrpl_so.gsf) 4294110 ; -/Hershey-Plain-Triplex (hrpl_t.gsf) 4294300 ; -/Hershey-Plain-Triplex-Italic (hrpl_ti.gsf) 4294320 ; -/Hershey-Plain-Triplex-Bold (hrpl_tb.gsf) 4294330 ; -/Hershey-Plain-Triplex-Bold-Italic (hrpl_tbi.gsf) 4294350 ; - -/Hershey-Script-Complex (hrsc_c.gsf) 4295200 ; -/Hershey-Script-Complex-Bold (hrsc_cb.gsf) 4295230 ; -/Hershey-Script-Complex-Oblique (hrsc_co.gsf) 4295210 ; -/Hershey-Script-Simplex (hrsc_s.gsf) 4295100 ; -/Hershey-Script-Simplex-Bold (hrsc_sb.gsf) 4295130 ; -/Hershey-Script-Simplex-Oblique (hrsc_so.gsf) 4295110 ; - -% This font, and only this font among the Hershey fonts, uses -% the SymbolEncoding. -/Hershey-Symbol (hrsy_r.gsf) 4296000 ; diff --git a/Master/tlpkg/tlgs/lib/Fontmap.ATM b/Master/tlpkg/tlgs/lib/Fontmap.ATM deleted file mode 100644 index f4586c32080..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.ATM +++ /dev/null @@ -1,185 +0,0 @@ -% Copyright (C) 1990, 1992, 1994, 1996 Aladdin Enterprises. All rights reserved. -% -% This software is provided AS-IS with no warranty, either express or -% implied. -% -% This software is distributed under license and may not be copied, -% modified or distributed except as expressly authorized under the terms -% of the license contained in the file LICENSE in this distribution. -% -% For more information about licensing, please refer to -% http://www.ghostscript.com/licensing/. For information on -% commercial licensing, go to http://www.artifex.com/licensing/ or -% contact Artifex Software, Inc., 101 Lucas Valley Road #110, -% San Rafael, CA 94903, U.S.A., +1(415)492-9861. - -% $Id: Fontmap.ATM 6300 2005-12-28 19:56:24Z giles $ -% Fontmap.ATM - an alternative Fontmap for Ghostscript, -% suitable for use with Adobe Type Manager fonts. - -% Before you use ATM fonts with Ghostscript, please read carefully -% the license that accompanies the ATM fonts; neither Aladdin Enterprises -% nor any other distributor of Ghostscript takes any responsibility for -% any possible violations of such licenses. - -% -% -% Fonts contributed by: -% URW++ Design and Development Incorporated -% Poppenbuetteler Bogen 29A -% D-22399 Hamburg -% Germany -% tel. +49 (40) 60 60 50 -% fax +49 (40) 60 60 51 11 -% http://www.urwpp.de -% for distribution under the GNU License and Aladdin Free Public License. -% See the notice at the head of this Fontmap file for licensing terms. -% Each of these fonts is individually covered by the license: -% for licensing purposes, they are not "part of" any larger entity. -% The following notice applies to these fonts: -% -% Copyright URW Software, Copyright 1994 by URW. -% - -% Actual fonts - -/URWBookmanL-DemiBold (b018015l.pfb) ; -/URWBookmanL-DemiBoldItal (b018035l.pfb) ; -/URWBookmanL-Ligh (b018012l.pfb) ; -/URWBookmanL-LighItal (b018032l.pfb) ; - -/NimbusMonL-Regu (n022003l.pfb) ; -/NimbusMonL-ReguObli (n022023l.pfb) ; -/NimbusMonL-Bold (n022004l.pfb) ; -/NimbusMonL-BoldObli (n022024l.pfb) ; - -/URWGothicL-Book (a010013l.pfb) ; -/URWGothicL-BookObli (a010033l.pfb) ; -/URWGothicL-Demi (a010015l.pfb) ; -/URWGothicL-DemiObli (a010035l.pfb) ; - -/NimbusSanL-Regu (n019003l.pfb) ; -/NimbusSanL-ReguItal (n019023l.pfb) ; -/NimbusSanL-Bold (n019004l.pfb) ; -/NimbusSanL-BoldItal (n019024l.pfb) ; - -/NimbusSanL-ReguCond (n019043l.pfb) ; -/NimbusSanL-ReguCondItal (n019063l.pfb) ; -/NimbusSanL-BoldCond (n019044l.pfb) ; -/NimbusSanL-BoldCondItal (n019064l.pfb) ; - -/URWPalladioL-Roma (p052003l.pfb) ; -/URWPalladioL-Ital (p052023l.pfb) ; -/URWPalladioL-Bold (p052004l.pfb) ; -/URWPalladioL-BoldItal (p052024l.pfb) ; - -/CenturySchL-Roma (c059013l.pfb) ; -/CenturySchL-Ital (c059033l.pfb) ; -/CenturySchL-Bold (c059016l.pfb) ; -/CenturySchL-BoldItal (c059036l.pfb) ; - -/NimbusRomNo9L-Regu (n021003l.pfb) ; -/NimbusRomNo9L-ReguItal (n021023l.pfb) ; -/NimbusRomNo9L-Medi (n021004l.pfb) ; -/NimbusRomNo9L-MediItal (n021024l.pfb) ; - -/StandardSymL (s050000l.pfb) ; - -/URWChanceryL-MediItal (z003034l.pfb) ; - -/Dingbats (d050000l.pfb) ; - -% Aliases - -/Bookman-Demi /URWBookmanL-DemiBold ; -/Bookman-DemiItalic /URWBookmanL-DemiBoldItal ; -/Bookman-Light /URWBookmanL-Ligh ; -/Bookman-LightItalic /URWBookmanL-LighItal ; - -/Courier /NimbusMonL-Regu ; -/Courier-Oblique /NimbusMonL-ReguObli ; -/Courier-Bold /NimbusMonL-Bold ; -/Courier-BoldOblique /NimbusMonL-BoldObli ; - -/AvantGarde-Book /URWGothicL-Book ; -/AvantGarde-BookOblique /URWGothicL-BookObli ; -/AvantGarde-Demi /URWGothicL-Demi ; -/AvantGarde-DemiOblique /URWGothicL-DemiObli ; - -/Helvetica /NimbusSanL-Regu ; -/Helvetica-Oblique /NimbusSanL-ReguItal ; -/Helvetica-Bold /NimbusSanL-Bold ; -/Helvetica-BoldOblique /NimbusSanL-BoldItal ; - -/Helvetica-Narrow /NimbusSanL-ReguCond ; -/Helvetica-Narrow-Oblique /NimbusSanL-ReguCondItal ; -/Helvetica-Narrow-Bold /NimbusSanL-BoldCond ; -/Helvetica-Narrow-BoldOblique /NimbusSanL-BoldCondItal ; - -/Palatino-Roman /URWPalladioL-Roma ; -/Palatino-Italic /URWPalladioL-Ital ; -/Palatino-Bold /URWPalladioL-Bold ; -/Palatino-BoldItalic /URWPalladioL-BoldItal ; - -/NewCenturySchlbk-Roman /CenturySchL-Roma ; -/NewCenturySchlbk-Italic /CenturySchL-Ital ; -/NewCenturySchlbk-Bold /CenturySchL-Bold ; -/NewCenturySchlbk-BoldItalic /CenturySchL-BoldItal ; - -/Times-Roman /NimbusRomNo9L-Regu ; -/Times-Italic /NimbusRomNo9L-ReguItal ; -/Times-Bold /NimbusRomNo9L-Medi ; -/Times-BoldItalic /NimbusRomNo9L-MediItal ; - -/Symbol /StandardSymL ; - -/ZapfChancery-MediumItalic /URWChanceryL-MediItal ; - -/ZapfDingbats /Dingbats ; - - -% ATM fonts. - -/Courier (com_____.pfb) ; -/Courier-Oblique (coo_____.pfb) ; -/Courier-Bold (cob_____.pfb) ; -/Courier-BoldOblique (cobo____.pfb) ; - -/Helvetica (hv______.pfb) ; -/Helvetica-Oblique (hvo_____.pfb) ; -/Helvetica-Bold (hvb_____.pfb) ; -/Helvetica-BoldOblique (hvbo____.pfb) ; - -/Symbol (sy______.pfb) ; - -/Times-Roman (tir_____.pfb) ; -/Times-Italic (tii_____.pfb) ; -/Times-Bold (tib_____.pfb) ; -/Times-BoldItalic (tibi____.pfb) ; - - -% More fonts from Adobe Type Manager for MS Windows. - -/TektonMM (zjrg____.pfb) ; - -/Boulevard (qtrg____.pfb) ; -/Anna (iarg____.pfb) ; - -/PopplLaudatio-Regular (pyrg____.pfb) ; -/PopplLaudatio-Medium (pym_____.pfb) ; -/PopplLaudatio-Italic (pyi_____.pfb) ; -/PopplLaudatio-MediumItalic (pymi____.pfb) ; - -/Boton-Regular (tnr_____.pfb) ; -/Boton-Medium (tnm_____.pfb) ; -/Boton-Italic (tni_____.pfb) ; -/Boton-MediumItalic (tnmi____.pfb) ; - -/BaskervilleBE-Regular (virg____.pfb) ; -/BaskervilleBE-Medium (vim_____.pfb) ; -/BaskervilleBE-Italic (vii_____.pfb) ; -/BaskervilleBE-MediumItalic (vimi____.pfb) ; - -/Giddyup (wg______.pfb) ; -/Giddyup-Thangs (wgtha___.pfb) ; - diff --git a/Master/tlpkg/tlgs/lib/Fontmap.GS b/Master/tlpkg/tlgs/lib/Fontmap.GS deleted file mode 100644 index 551da508240..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.GS +++ /dev/null @@ -1,412 +0,0 @@ -% Copyright (C) 1996, 1999 Aladdin Enterprises. All rights reserved. -% -% This software is provided AS-IS with no warranty, either express or -% implied. -% -% This software is distributed under license and may not be copied, -% modified or distributed except as expressly authorized under the terms -% of the license contained in the file LICENSE in this distribution. -% -% For more information about licensing, please refer to -% http://www.ghostscript.com/licensing/. For information on -% commercial licensing, go to http://www.artifex.com/licensing/ or -% contact Artifex Software, Inc., 101 Lucas Valley Road #110, -% San Rafael, CA 94903, U.S.A., +1(415)492-9861. - -% $Id: Fontmap.GS 8487 2008-01-17 03:16:02Z alexcher $ -% Fontmap - standard font catalog for Ghostscript. - -% ---------------------------------------------------------------- - -% This file is a catalog of fonts known to Ghostscript. Any font -% that is to be loaded automatically when named must be in this catalog, -% except for fonts that Ghostscript finds automatically in directories -% named in the GS_FONTPATH environment variable. - -% Each font has an entry consisting of three items: -% -% - The name by which the font is known inside Ghostscript -% (a Ghostscript name preceded by a `/', or a string enclosed -% in parentheses). This is used to find the file from which -% a font of a given name should be loaded. -% -% - Information depending on whether this is a real font or a -% font alias: -% -% - For real fonts, the name of the Ghostscript font -% file (a Ghostscript string, enclosed in parentheses). -% The filename should include the extension, which (by -% convention) is `.gsf'. `.pfa' and `.pfb' files are -% also usable as fonts for Ghostscript. -% -% - For font aliases, the name of the font which should -% be used when this one is requested, preceded by a -% `/'. See the entry for Charter below for an example. -% Note that an alias name cannot be enclosed in parentheses. -% -% - At least one space or tab, and a terminating semicolon. - -% The following table is executed as a PostScript file. -% If you add new entries, be sure to copy the punctuation accurately; -% in particular, you must leave at least one space or tab between each -% field in the entry. Also, please read fonts.doc for important information -% about font names. - -% PDF interpreter evaluates hexadecimal escapes in PDF font names before -% looking up the font. When the resulting name cannot be represented using -% PostScript name syntax, the string can be used instead of the name. - -% Note that .pfa and .pfb fonts are compatible with Adobe Type Manager -% and other programs that don't include full PostScript interpreters, -% as well as with PostScript interpreters; .gsf fonts are compatible with -% PostScript interpreters, but not with ATM or similar programs. - -% -% -% Fonts contributed by: -% URW++ Design and Development Incorporated -% Poppenbuetteler Bogen 29A -% D-22399 Hamburg -% Germany -% tel. +49 (40) 60 60 50 -% fax +49 (40) 60 60 51 11 -% http://www.urwpp.de -% for distribution under the GNU License and Aladdin Free Public License. -% See the notice at the head of this Fontmap file for licensing terms. -% Each of these fonts is individually covered by the license: -% for licensing purposes, they are not "part of" any larger entity. -% The following notice applies to these fonts: -% -% Copyright URW Software, Copyright 1994 by URW. -% - -% Actual fonts - -/URWBookmanL-DemiBold (b018015l.pfb) ; -/URWBookmanL-DemiBoldItal (b018035l.pfb) ; -/URWBookmanL-Ligh (b018012l.pfb) ; -/URWBookmanL-LighItal (b018032l.pfb) ; - -/NimbusMonL-Regu (n022003l.pfb) ; -/NimbusMonL-ReguObli (n022023l.pfb) ; -/NimbusMonL-Bold (n022004l.pfb) ; -/NimbusMonL-BoldObli (n022024l.pfb) ; - -/URWGothicL-Book (a010013l.pfb) ; -/URWGothicL-BookObli (a010033l.pfb) ; -/URWGothicL-Demi (a010015l.pfb) ; -/URWGothicL-DemiObli (a010035l.pfb) ; - -/NimbusSanL-Regu (n019003l.pfb) ; -/NimbusSanL-ReguItal (n019023l.pfb) ; -/NimbusSanL-Bold (n019004l.pfb) ; -/NimbusSanL-BoldItal (n019024l.pfb) ; - -/NimbusSanL-ReguCond (n019043l.pfb) ; -/NimbusSanL-ReguCondItal (n019063l.pfb) ; -/NimbusSanL-BoldCond (n019044l.pfb) ; -/NimbusSanL-BoldCondItal (n019064l.pfb) ; - -/URWPalladioL-Roma (p052003l.pfb) ; -/URWPalladioL-Ital (p052023l.pfb) ; -/URWPalladioL-Bold (p052004l.pfb) ; -/URWPalladioL-BoldItal (p052024l.pfb) ; - -/CenturySchL-Roma (c059013l.pfb) ; -/CenturySchL-Ital (c059033l.pfb) ; -/CenturySchL-Bold (c059016l.pfb) ; -/CenturySchL-BoldItal (c059036l.pfb) ; - -/NimbusRomNo9L-Regu (n021003l.pfb) ; -/NimbusRomNo9L-ReguItal (n021023l.pfb) ; -/NimbusRomNo9L-Medi (n021004l.pfb) ; -/NimbusRomNo9L-MediItal (n021024l.pfb) ; - -/StandardSymL (s050000l.pfb) ; - -/URWChanceryL-MediItal (z003034l.pfb) ; - -/Dingbats (d050000l.pfb) ; - -% Aliases - -/Bookman-Demi /URWBookmanL-DemiBold ; -/Bookman-DemiItalic /URWBookmanL-DemiBoldItal ; -/Bookman-Light /URWBookmanL-Ligh ; -/Bookman-LightItalic /URWBookmanL-LighItal ; - -/Courier /NimbusMonL-Regu ; -/Courier-Oblique /NimbusMonL-ReguObli ; -/Courier-Bold /NimbusMonL-Bold ; -/Courier-BoldOblique /NimbusMonL-BoldObli ; - -/AvantGarde-Book /URWGothicL-Book ; -/AvantGarde-BookOblique /URWGothicL-BookObli ; -/AvantGarde-Demi /URWGothicL-Demi ; -/AvantGarde-DemiOblique /URWGothicL-DemiObli ; - -/Helvetica /NimbusSanL-Regu ; -/Helvetica-Oblique /NimbusSanL-ReguItal ; -/Helvetica-Bold /NimbusSanL-Bold ; -/Helvetica-BoldOblique /NimbusSanL-BoldItal ; - -/Helvetica-Narrow /NimbusSanL-ReguCond ; -/Helvetica-Narrow-Oblique /NimbusSanL-ReguCondItal ; -/Helvetica-Narrow-Bold /NimbusSanL-BoldCond ; -/Helvetica-Narrow-BoldOblique /NimbusSanL-BoldCondItal ; - -/Palatino-Roman /URWPalladioL-Roma ; -/Palatino-Italic /URWPalladioL-Ital ; -/Palatino-Bold /URWPalladioL-Bold ; -/Palatino-BoldItalic /URWPalladioL-BoldItal ; - -/NewCenturySchlbk-Roman /CenturySchL-Roma ; -/NewCenturySchlbk-Italic /CenturySchL-Ital ; -/NewCenturySchlbk-Bold /CenturySchL-Bold ; -/NewCenturySchlbk-BoldItalic /CenturySchL-BoldItal ; - -/Times-Roman /NimbusRomNo9L-Regu ; -/Times-Italic /NimbusRomNo9L-ReguItal ; -/Times-Bold /NimbusRomNo9L-Medi ; -/Times-BoldItalic /NimbusRomNo9L-MediItal ; - -/Symbol /StandardSymL ; - -/ZapfChancery-MediumItalic /URWChanceryL-MediItal ; - -/ZapfDingbats /Dingbats ; - -% -% -% Type 1 fonts contributed to the X11R5 distribution. -% - -% The following notice accompanied the Charter fonts. -% -% (c) Copyright 1989-1992, Bitstream Inc., Cambridge, MA. -% -% You are hereby granted permission under all Bitstream propriety rights -% to use, copy, modify, sublicense, sell, and redistribute the 4 Bitstream -% Charter (r) Type 1 outline fonts and the 4 Courier Type 1 outline fonts -% for any purpose and without restriction; provided, that this notice is -% left intact on all copies of such fonts and that Bitstream's trademark -% is acknowledged as shown below on all unmodified copies of the 4 Charter -% Type 1 fonts. -% -% BITSTREAM CHARTER is a registered trademark of Bitstream Inc. - -/CharterBT-Roman (bchr.pfa) ; -/CharterBT-Italic (bchri.pfa) ; -/CharterBT-Bold (bchb.pfa) ; -/CharterBT-BoldItalic (bchbi.pfa) ; - -% Aliases - -/Charter-Roman /CharterBT-Roman ; -/Charter-Italic /CharterBT-Italic ; -/Charter-Bold /CharterBT-Bold ; -/Charter-BoldItalic /CharterBT-BoldItalic ; - -% The following notice accompanied the Utopia font: -% -% Permission to use, reproduce, display and distribute the listed -% typefaces is hereby granted, provided that the Adobe Copyright notice -% appears in all whole and partial copies of the software and that the -% following trademark symbol and attribution appear in all unmodified -% copies of the software: -% -% Copyright (c) 1989 Adobe Systems Incorporated -% Utopia (R) -% Utopia is a registered trademark of Adobe Systems Incorporated -% -% The Adobe typefaces (Type 1 font program, bitmaps and Adobe Font -% Metric files) donated are: -% -% Utopia Regular -% Utopia Italic -% Utopia Bold -% Utopia Bold Italic - -/Utopia-Regular (putr.pfa) ; -/Utopia-Italic (putri.pfa) ; -/Utopia-Bold (putb.pfa) ; -/Utopia-BoldItalic (putbi.pfa) ; - -% -% -% Fonts contributed by URW GmbH for distribution under the GNU License. -% The following notice accompanied these fonts: -% -% U004006T URW Grotesk 2031 Bold PostScript Type 1 Font Program -% U003043T URW Antiqua 2051 Regular Condensed PostScript Type 1 Font Program -% -% Copyright (c) 1992 URW GmbH, Hamburg, Germany -% -% This program is free software; you can redistribute it and/or modify -% it under the terms of the GNU General Public License as published by -% the Free Software Foundation; either version 2 of the License, or -% (at your option) later version. -% -% This program is distributed in the hope that it will be useful, -% but WITHOUT ANY WARRANTY; wihtout even the implied warranty of -% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -% See the GNU General Public License for more details. -% -% You should have received a copy of the GNU General Public License -% along with this program; if not, write to the Free Software -% Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111 U.S.A. -% -% Address: -% URW GmbH -% PC Support -% Harksheider Strasse 102 -% 2000 Hamburg 65 -% Germany -% Phone: +49 40 60 60 50 (Reception) -% Phone: +49 40 60 60 52 30 (PC Support) -% Fax : +49 40 60 60 52 52 -% - -/URWAntiquaT-RegularCondensed (u003043t.gsf) ; -/URWGroteskT-Bold (u004006t.gsf) ; - -% -% -% Shareware Kana fonts. These are subject to the following notice: -% -% These copyrighted fonts were developed by Kevin Hartig. Permission is -% granted to freely distribute them in entirety along with this statement. -% This is shareware. If you decide to use these fonts please contribute -% $10 US to help support further freeware and shareware software development. -% Questions and comments may be sent to: -% -% hartig@fsl.noaa.gov -% khartig@nyx.cs.du.edu -% -% Kevin Hartig -% 1126 Collyer Street -% Longmont, CO 80501 USA -% -% copyright 1993. - -% Hiragana and Katakana fonts. The character names are inappropriate, -% and the encoding is probably not related to any known standard. - -/Calligraphic-Hiragana (fhirw.gsf) ; -/Calligraphic-Katakana (fkarw.gsf) ; - -% -% -% Public-domain fonts. These have no copyright, and are of unknown quality. - -% Cyrillic fonts. The character names are inappropriate, -% and the encoding is probably not related to any known standard. - -/Shareware-Cyrillic-Regular (fcyr.gsf) ; -/Shareware-Cyrillic-Italic (fcyri.gsf) ; - -% Aliases -/Cyrillic /Cyrillic-Regular ; -/Cyrillic-Regular /Shareware-Cyrillic-Regular ; -/Cyrillic-Italic /Shareware-Cyrillic-Italic ; - -% -% -% Fonts converted from Hershey outlines. These are constructed and -% maintained manually. These are also in the public domain. -% -% The suggested UniqueID's and filenames are constructed differently for -% these than for the ones above, because of the strange way that the Hershey -% fonts were constructed. The scheme for these looks like: -% -% 42TTXY0 -% -% TT = typeface, X = ``class'', Y = variation -% -% The typeface names and numbers are listed in fonts.mak. -% -% class: -% 0 = normal = r -% 1 = simplex = s -% 2 = complex = c -% 3 = triplex = t -% 4 = duplex = d -% -% variation: -% 0 = normal (omitted) -% 1 = oblique = o -% 2 = italic = i -% 3 = bold = b -% 4 = bold oblique = bo -% 5 = bold italic = bi -% - -% Fonts created by Thomas Wolff <wolff@inf.fu-berlin.de>, by adding -% accents, accented characters, and various other non-alphabetics -% to the original Hershey fonts. These are "freeware", not to be sold. - -/Hershey-Gothic-English (hrger.pfa) ; % 5066533 -/Hershey-Gothic-German (hrgrr.pfa) ; -/Hershey-Gothic-Italian (hritr.pfa) ; - -/Hershey-Plain-Duplex (hrpld.pfa) ; -/Hershey-Plain-Duplex-Italic (hrpldi.pfa) ; -/Hershey-Plain-Triplex (hrplt.pfa) ; -/Hershey-Plain-Triplex-Italic (hrplti.pfa) ; - -/Hershey-Script-Complex (hrscc.pfa) ; -/Hershey-Script-Simplex (hrscs.pfa) ; % 5066541 - -% Fonts created algorithmically from the above. - -/Hershey-Gothic-English-Bold (hrgerb.gsf) ; % 5066542 -/Hershey-Gothic-English-Oblique (hrgero.gsf) ; -/Hershey-Gothic-English-SemiBold (hrgerd.gsf) ; -/Hershey-Gothic-German-Bold (hrgrrb.gsf) ; -/Hershey-Gothic-German-Oblique (hrgrro.gsf) ; -/Hershey-Gothic-Italian-Bold (hritrb.gsf) ; -/Hershey-Gothic-Italian-Oblique (hritro.gsf) ; - -/Hershey-Plain-Duplex-Bold (hrpldb.gsf) ; -/Hershey-Plain-Duplex-Bold-Italic (hrpldbi.gsf) ; -/Hershey-Plain-Triplex-Bold (hrpltb.gsf) ; -/Hershey-Plain-Triplex-Bold-Italic (hrpltbi.gsf) ; - -/Hershey-Script-Complex-Bold (hrsccb.gsf) ; -/Hershey-Script-Complex-Oblique (hrscco.gsf) ; -/Hershey-Script-Simplex-Bold (hrscsb.gsf) ; -/Hershey-Script-Simplex-Oblique (hrscso.gsf) ; % 5066556 - -% Fonts consisting only of characters from the original Hershey -% distribution. These are Type 3 fonts. - -/Hershey-Greek-Complex (hrgkc.gsf) ; % 5066557 -/Hershey-Greek-Simplex (hrgks.gsf) ; - -/Hershey-Plain (hrplr.gsf) ; -/Hershey-Plain-Simplex (hrpls.gsf) ; % 5066560 - -% Fonts created algorithmically from the above. - -/Hershey-Plain-Bold (hrplrb.gsf) ; % 5066561 -/Hershey-Plain-Bold-Oblique (hrplrbo.gsf) ; -/Hershey-Plain-Oblique (hrplro.gsf) ; -/Hershey-Plain-Simplex-Bold (hrplsb.gsf) ; -/Hershey-Plain-Simplex-Bold-Oblique (hrplsbo.gsf) ; -/Hershey-Plain-Simplex-Oblique (hrplso.gsf) ; % 5066566 - -% This font, and only this font among the Hershey fonts, uses -% the SymbolEncoding. - -/Hershey-Symbol (hrsyr.gsf) ; % 5066567 - -/Arial /ArialMT ; -/Arial,Bold /Arial-BoldMT ; -/Arial,Italic /Arial-ItalicMT ; -/Arial,BoldItalic /Arial-BoldItalicMT ; - -/TimesNewRoman /TimesNewRomanPSMT ; -/TimesNewRoman,Bold /TimesNewRomanPS-BoldMT ; -/TimesNewRoman,Italic /TimesNewRomanPS-ItalicMT ; -/TimesNewRoman,BoldItalic /TimesNewRomanPS-BoldItalicMT ; - diff --git a/Master/tlpkg/tlgs/lib/Fontmap.OS2 b/Master/tlpkg/tlgs/lib/Fontmap.OS2 deleted file mode 100644 index 99a92878b22..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.OS2 +++ /dev/null @@ -1,214 +0,0 @@ -% Copyright (C) 1990, 1992, 1993, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: Fontmap.OS2 6300 2005-12-28 19:56:24Z giles $
-% fontmap.os2 aka Fontmap.OS2 - OS/2 font catalog for Ghostscript.
-
-% ----------------------------------------------------------------
-
-% This file is a catalog of fonts known to Ghostscript. Any font
-% that is to be loaded automatically when named must be in this catalog,
-% except for fonts that Ghostscript finds automatically in directories
-% named in the GS_FONTPATH environment variable.
-
-% Each font has an entry consisting of three items:
-%
-% - The name by which the font is known inside Ghostscript
-% (a Ghostscript name preceded by a `/', or a string enclosed
-% in parentheses). This is used to find the file from which
-% a font of a given name should be loaded.
-%
-% - Information depending on whether this is a real font or a
-% font alias:
-%
-% - For real fonts, the name of the Ghostscript font
-% file (a Ghostscript string, enclosed in parentheses).
-% The filename should include the extension, which (by
-% convention) is `.gsf'. `.pfa' and `.pfb' files are
-% also usable as fonts for Ghostscript.
-%
-% - For font aliases, the name of the font which should
-% be used when this one is requested, preceded by a
-% `/'. See the entry for Charter below for an example.
-%
-% - A terminating semicolon.
-
-% Because of limitations in the MS-DOS environment, Ghostscript font
-% file names must be no more than 8 characters long, must consist only
-% of LOWER CASE letters, digits, and underscores, and must start with a
-% letter. Font names, on the other hand, need only obey the syntax of
-% names in the Ghostscript language, which is much more liberal.
-
-% Most of the Ghostscript fonts were created automatically from freely
-% available bitmaps. There is a makefile (fonts.mak) that specifies
-% how this conversion was done. fonts.mak also specifies, for each such
-% converted font, its uniqueID (an integer used to identify distinct fonts
-% within the Ghostscript font machinery), and its encoding (the mapping
-% from character codes in a string to character names). For more detailed
-% information, read fonts.mak.
-
-% The following table is actually a Ghostscript data structure.
-% If you add new entries, be sure to copy the punctuation accurately;
-% in particular, you must leave at least one space or tab between each
-% field in the entry. Also, please read fonts.doc for important information
-% about font names.
-
-
-%
-%
-% Fonts contributed by:
-% URW++ Design and Development Incorporated
-% Poppenbuetteler Bogen 29A
-% D-22399 Hamburg
-% Germany
-% tel. +49 (40) 60 60 50
-% fax +49 (40) 60 60 51 11
-% http://www.urwpp.de
-% for distribution under the GNU License and Aladdin Free Public License.
-% See the notice at the head of this Fontmap file for licensing terms.
-% Each of these fonts is individually covered by the license:
-% for licensing purposes, they are not "part of" any larger entity.
-% The following notice applies to these fonts:
-%
-% Copyright URW Software, Copyright 1994 by URW.
-%
-
-% Actual fonts
-
-/URWBookmanL-DemiBold (b018015l.pfb) ;
-/URWBookmanL-DemiBoldItal (b018035l.pfb) ;
-/URWBookmanL-Ligh (b018012l.pfb) ;
-/URWBookmanL-LighItal (b018032l.pfb) ;
-
-/NimbusMonL-Regu (n022003l.pfb) ;
-/NimbusMonL-ReguObli (n022023l.pfb) ;
-/NimbusMonL-Bold (n022004l.pfb) ;
-/NimbusMonL-BoldObli (n022024l.pfb) ;
-
-/URWGothicL-Book (a010013l.pfb) ;
-/URWGothicL-BookObli (a010033l.pfb) ;
-/URWGothicL-Demi (a010015l.pfb) ;
-/URWGothicL-DemiObli (a010035l.pfb) ;
-
-/NimbusSanL-Regu (n019003l.pfb) ;
-/NimbusSanL-ReguItal (n019023l.pfb) ;
-/NimbusSanL-Bold (n019004l.pfb) ;
-/NimbusSanL-BoldItal (n019024l.pfb) ;
-
-/NimbusSanL-ReguCond (n019043l.pfb) ;
-/NimbusSanL-ReguCondItal (n019063l.pfb) ;
-/NimbusSanL-BoldCond (n019044l.pfb) ;
-/NimbusSanL-BoldCondItal (n019064l.pfb) ;
-
-/URWPalladioL-Roma (p052003l.pfb) ;
-/URWPalladioL-Ital (p052023l.pfb) ;
-/URWPalladioL-Bold (p052004l.pfb) ;
-/URWPalladioL-BoldItal (p052024l.pfb) ;
-
-/CenturySchL-Roma (c059013l.pfb) ;
-/CenturySchL-Ital (c059033l.pfb) ;
-/CenturySchL-Bold (c059016l.pfb) ;
-/CenturySchL-BoldItal (c059036l.pfb) ;
-
-/NimbusRomNo9L-Regu (n021003l.pfb) ;
-/NimbusRomNo9L-ReguItal (n021023l.pfb) ;
-/NimbusRomNo9L-Medi (n021004l.pfb) ;
-/NimbusRomNo9L-MediItal (n021024l.pfb) ;
-
-/StandardSymL (s050000l.pfb) ;
-
-/URWChanceryL-MediItal (z003034l.pfb) ;
-
-/Dingbats (d050000l.pfb) ;
-
-% Aliases
-
-/Bookman-Demi /URWBookmanL-DemiBold ;
-/Bookman-DemiItalic /URWBookmanL-DemiBoldItal ;
-/Bookman-Light /URWBookmanL-Ligh ;
-/Bookman-LightItalic /URWBookmanL-LighItal ;
-
-/Courier /NimbusMonL-Regu ;
-/Courier-Oblique /NimbusMonL-ReguObli ;
-/Courier-Bold /NimbusMonL-Bold ;
-/Courier-BoldOblique /NimbusMonL-BoldObli ;
-
-/AvantGarde-Book /URWGothicL-Book ;
-/AvantGarde-BookOblique /URWGothicL-BookObli ;
-/AvantGarde-Demi /URWGothicL-Demi ;
-/AvantGarde-DemiOblique /URWGothicL-DemiObli ;
-
-/Helvetica /NimbusSanL-Regu ;
-/Helvetica-Oblique /NimbusSanL-ReguItal ;
-/Helvetica-Bold /NimbusSanL-Bold ;
-/Helvetica-BoldOblique /NimbusSanL-BoldItal ;
-
-/Helvetica-Narrow /NimbusSanL-ReguCond ;
-/Helvetica-Narrow-Oblique /NimbusSanL-ReguCondItal ;
-/Helvetica-Narrow-Bold /NimbusSanL-BoldCond ;
-/Helvetica-Narrow-BoldOblique /NimbusSanL-BoldCondItal ;
-
-/Palatino-Roman /URWPalladioL-Roma ;
-/Palatino-Italic /URWPalladioL-Ital ;
-/Palatino-Bold /URWPalladioL-Bold ;
-/Palatino-BoldItalic /URWPalladioL-BoldItal ;
-
-/NewCenturySchlbk-Roman /CenturySchL-Roma ;
-/NewCenturySchlbk-Italic /CenturySchL-Ital ;
-/NewCenturySchlbk-Bold /CenturySchL-Bold ;
-/NewCenturySchlbk-BoldItalic /CenturySchL-BoldItal ;
-
-/Times-Roman /NimbusRomNo9L-Regu ;
-/Times-Italic /NimbusRomNo9L-ReguItal ;
-/Times-Bold /NimbusRomNo9L-Medi ;
-/Times-BoldItalic /NimbusRomNo9L-MediItal ;
-
-/Symbol /StandardSymL ;
-
-/ZapfChancery-MediumItalic /URWChanceryL-MediItal ;
-
-/ZapfDingbats /Dingbats ;
-
-
-%
-% ATM fonts that come with OS/2.
-
-/Courier (cour.pfb) ;
-/Courier-Oblique /Courier-Italic ;
-/Courier-Italic (couri.pfb) ;
-/Courier-Bold (courb.pfb) ;
-/Courier-BoldOblique /Courier-BoldItalic ;
-/Courier-BoldItalic (courbi.pfb) ;
-
-/Helvetica (helv.pfb) ;
-/Helvetica-Oblique /Helvetica-Italic ;
-/Helvetica-Italic (helvi.pfb) ;
-/Helvetica-Bold (helvb.pfb) ;
-/Helvetica-BoldOblique /Helvetica-BoldItalic ;
-/Helvetica-BoldItalic (helvbi.pfb) ;
-
-/Symbol /SymbolSet ;
-/SymbolSet (symb.pfb) ;
-
-/Times-Roman /TimesNewRoman ;
-/TimesNewRoman (tnr.pfb) ;
-/Times-Italic /TimesNewRoman-Italic ;
-/TimesNewRoman-Italic (tnri.pfb) ;
-/Times-Bold /TimesNewRoman-Bold ;
-/TimesNewRoman-Bold (tnrb.pfb) ;
-/Times-BoldItalic /TimesNewRoman-BoldItalic ;
-/TimesNewRoman-BoldItalic (tnrbi.pfb) ;
-
-
diff --git a/Master/tlpkg/tlgs/lib/Fontmap.OSF b/Master/tlpkg/tlgs/lib/Fontmap.OSF deleted file mode 100644 index 563f14a995f..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.OSF +++ /dev/null @@ -1,163 +0,0 @@ -% fontmap.osf aka Fontmap.OSF1 - Ghostscript fontmap for DEC OSF/1 systems. -% -% UNIX systems from Digital Equipment Corporation are bundled with a license -% for Display PostScript, including certain fonts. Using their font outlines -% (which on OSF/1 systems are found in /usr/lib/X11/fonts/Type1Adobe) -% improves the visual quality of documents displayed on screen. To do that, -% use this file as your Fontmap file and add /usr/lib/X11/fonts/Type1Adobe -% as the second argument to GS_LIB_DEFAULT in your makefile -% in your makefile. -% -% This file is Pete Kaiser's original Ultrix file as modified by -% Bjorn S. Nilsson (nilsson@nbi.dk) first for Ultrix 4.3 and then -% for OSF/1 version 1.3. -% - -%/AvantGarde-Book (AvantGarde-Book) ; -%/AvantGarde-BookOblique (AvantGarde-BookOblique); -%/AvantGarde-Demi (AvantGarde-Demi) ; -%/AvantGarde-DemiOblique (AvantGarde-DemiOblique); - -%/Courier-BoldItalic /Courier-BoldOblique ; -%/Courier-Italic /Courier-Oblique ; - -%/Courier (Courier) ; -%/Courier-Bold (Courier-Bold) ; -%/Courier-BoldOblique (Courier-BoldOblique) ; -%/Courier-Oblique (Courier-Oblique) ; - -%/Helvetica (Helvetica) ; -%/Helvetica-Bold (Helvetica-Bold) ; -%/Helvetica-BoldOblique (Helvetica-BoldOblique) ; -%/Helvetica-Oblique (Helvetica-Oblique) ; - -%/LubalinGraph-Book (LubalinGraph-Book) ; -%/LubalinGraph-BookOblique (LubalinGraph-BookOblique); -%/LubalinGraph-Demi (LubalinGraph-Demi) ; -%/LubalinGraph-DemiOblique (LubalinGraph-DemiOblique); - -%/NewCenturySchlbk-Bold (NewCenturySchlbk-Bold) ; -%/NewCenturySchlbk-BoldItalic (NewCenturySchlbk-BoldItalic); -%/NewCenturySchlbk-Italic (NewCenturySchlbk-Italic); -%/NewCenturySchlbk-Roman (NewCenturySchlbk-Roman); - -%/Souvenir-Demi (Souvenir-Demi) ; -%/Souvenir-DemiItalic (Souvenir-DemiItalic) ; -%/Souvenir-Light (Souvenir-Light) ; -%/Souvenir-LightItalic (Souvenir-LightItalic) ; - -%/Symbol (Symbol) ; - -%/Times-Bold (Times-Bold) ; -%/Times-BoldItalic (Times-BoldItalic) ; -%/Times-Italic (Times-Italic) ; -%/Times-Roman (Times-Roman) ; - -%/ZapfDingbats (ZapfDingbats) ; - -/AvantGarde-Book (AvantGarde-Book.pfa) ; -/AvantGarde-BookOblique (AvantGarde-BookOblique.pfa) ; -/AvantGarde-Demi (AvantGarde-Demi.pfa) ; -/AvantGarde-DemiOblique (AvantGarde-DemiOblique.pfa) ; -/Bookman-Demi (pbkd.gsf) ; -/Bookman-DemiItalic (pbkdi.gsf) ; -/Bookman-Light (pbkl.gsf) ; -/Bookman-LightItalic (pbkli.gsf) ; -/Calligraphic-Hiragana (fhirw.gsf) ; -/Calligraphic-Katakana (fkarw.gsf) ; -/CharterBT-Bold (bchb.gsf) ; -/CharterBT-BoldItalic (bchbi.gsf) ; -/CharterBT-Italic (bchri.gsf) ; -/CharterBT-Roman (bchr.gsf) ; -/Courier (Courier.pfa) ; -/Courier-Bold (Courier-Bold.pfa) ; -/Courier-BoldOblique (Courier-BoldOblique.pfa) ; -/Courier-Oblique (Courier-Oblique.pfa) ; -/Helvetica (Helvetica.pfa) ; -/Helvetica-Bold (Helvetica-Bold.pfa) ; -/Helvetica-BoldOblique (Helvetica-BoldOblique.pfa) ; -/Helvetica-Oblique (Helvetica-Oblique.pfa) ; -/Hershey-Gothic-English (hrger.gsf) ; -/Hershey-Gothic-German (hrgrr.gsf) ; -/Hershey-Gothic-Italian (hritr.gsf) ; -/Hershey-Plain-Duplex (hrpld.gsf) ; -/Hershey-Plain-Duplex-Italic (hrpldi.gsf) ; -/Hershey-Plain-Triplex (hrplt.gsf) ; -/Hershey-Plain-Triplex-Italic (hrplti.gsf) ; -/Hershey-Script-Complex (hrscc.gsf) ; -/Hershey-Script-Simplex (hrscs.gsf) ; -/Hershey-Gothic-English-Bold (hrgerb.gsf) ; -/Hershey-Gothic-English-Oblique (hrgero.gsf) ; -/Hershey-Gothic-English-Semibold (hrgerd.gsf) ; -/Hershey-Gothic-German-Bold (hrgrrb.gsf) ; -/Hershey-Gothic-German-Oblique (hrgrro.gsf) ; -/Hershey-Gothic-Italian-Bold (hritrb.gsf) ; -/Hershey-Gothic-Italian-Oblique (hritro.gsf) ; -/Hershey-Plain-Duplex-Bold (hrpldb.gsf) ; -/Hershey-Plain-Duplex-Bold-Italic (hrpldbi.gsf) ; -/Hershey-Plain-Triplex-Bold (hrpltb.gsf) ; -/Hershey-Plain-Triplex-Bold-Italic (hrpltbi.gsf) ; -/Hershey-Script-Complex-Bold (hrsccb.gsf) ; -/Hershey-Script-Complex-Oblique (hrscco.gsf) ; -/Hershey-Script-Simplex-Bold (hrscsb.gsf) ; -/Hershey-Script-Simplex-Oblique (hrscso.gsf) ; -/Hershey-Greek-Complex (hrgkc.gsf) ; -/Hershey-Greek-Simplex (hrgks.gsf) ; -/Hershey-Plain (hrplr.gsf) ; -/Hershey-Plain-Simplex (hrpls.gsf) ; -/Hershey-Plain-Bold (hrplrb.gsf) ; -/Hershey-Plain-Bold-Oblique (hrplrbo.gsf) ; -/Hershey-Plain-Oblique (hrplro.gsf) ; -/Hershey-Plain-Simplex-Bold (hrplsb.gsf) ; -/Hershey-Plain-Simplex-Bold-Oblique (hrplsbo.gsf) ; -/Hershey-Plain-Simplex-Oblique (hrplso.gsf) ; -/Hershey-Symbol (hrsy_r.gsf) ; -/LubalinGraph-Book (LubalinGraph-Book.pfa) ; -/LubalinGraph-BookOblique (LubalinGraph-BookOblique.pfa) ; -/LubalinGraph-Demi (LubalinGraph-Demi.pfa) ; -/LubalinGraph-DemiOblique (LubalinGraph-DemiOblique.pfa) ; -/NewCenturySchlbk-Bold (NewCenturySchlbk-Bold.pfa) ; -/NewCenturySchlbk-BoldItalic (NewCenturySchlbk-BoldItalic.pfa) ; -/NewCenturySchlbk-Italic (NewCenturySchlbk-Italic.pfa) ; -/NewCenturySchlbk-Roman (NewCenturySchlbk-Roman.pfa) ; -/NimbusRomanNo9L-Regular (n021003l.gsf) ; -/NimbusSansL-Regular (n019003l.gsf) ; -/Palatino-Bold (pplb.gsf) ; -/Palatino-BoldItalic (pplbi.gsf) ; -/Palatino-Italic (pplri.gsf) ; -/Palatino-Roman (pplr.gsf) ; -/Shareware-Cyrillic-Regular (fcyr.gsf) ; -/Shareware-Cyrillic-Italic (fcyri.gsf) ; -/Souvenir-Demi (Souvenir-Demi.pfa) ; -/Souvenir-DemiItalic (Souvenir-DemiItalic.pfa) ; -/Souvenir-Light (Souvenir-Light.pfa) ; -/Souvenir-LightItalic (Souvenir-LightItalic.pfa) ; -/Symbol (Symbol.pfa) ; -/Times-Bold (Times-Bold.pfa) ; -/Times-BoldItalic (Times-BoldItalic.pfa) ; -/Times-Italic (Times-Italic.pfa) ; -/Times-Roman (Times-Roman.pfa) ; -/URWAntiquaT-RegularCondensed (u003043t.gsf) ; -/URWGroteskT-Bold (u004006t.gsf) ; -/Utopia-Bold (putb.gsf) ; -/Utopia-BoldItalic (putbi.gsf) ; -/Utopia-Italic (putri.gsf) ; -/Utopia-Regular (putr.gsf) ; -/ZapfChancery (zcr.gsf) ; -/ZapfChancery-Bold (zcb.gsf) ; -/ZapfChancery-Oblique (zcro.gsf) ; -/ZapfDingbats (ZapfDingbats.pfa) ; -/Cyrillic /Cyrillic-Regular ; -/Cyrillic-Regular /Shareware-Cyrillic-Regular ; -/Cyrillic-Italic /Shareware-Cyrillic-Italic ; - -% BSN additions from original Fontmap file and some more aliases - -/Helvetica-Narrow-Bold /Helvetica-Narrow ; -/ZapfChancery-MediumItalic /ZapfChancery-Oblique ; -/Charter-Roman /CharterBT-Roman ; -/Charter-Italic /CharterBT-Italic ; -/Charter-Bold /CharterBT-Bold ; -/Charter-BoldItalic /CharterBT-BoldItalic ; -/Courier-Italic /Courier-Oblique ; -/Courier-BoldItalic /Courier-BoldOblique ; diff --git a/Master/tlpkg/tlgs/lib/Fontmap.SGI b/Master/tlpkg/tlgs/lib/Fontmap.SGI deleted file mode 100644 index 69fee1080ca..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.SGI +++ /dev/null @@ -1,405 +0,0 @@ -% Copyright (C) 1996, 1999 Aladdin Enterprises. All rights reserved. -% -% This software is provided AS-IS with no warranty, either express or -% implied. -% -% This software is distributed under license and may not be copied, -% modified or distributed except as expressly authorized under the terms -% of the license contained in the file LICENSE in this distribution. -% -% For more information about licensing, please refer to -% http://www.ghostscript.com/licensing/. For information on -% commercial licensing, go to http://www.artifex.com/licensing/ or -% contact Artifex Software, Inc., 101 Lucas Valley Road #110, -% San Rafael, CA 94903, U.S.A., +1(415)492-9861. - -% $Id: Fontmap.SGI 6300 2005-12-28 19:56:24Z giles $ -% -% Fontmap.SGI - standard font catalog for Ghostscript, modified for IRIX 5.3 -% with the DPS fonts installed (dps_eoe.sw.dpsfonts). -% by H. Gohel, gohel@acm.org. 1999-09-10 - -% ---------------------------------------------------------------- - -% This file is a catalog of fonts known to Ghostscript. Any font -% that is to be loaded automatically when named must be in this catalog, -% except for fonts that Ghostscript finds automatically in directories -% named in the GS_FONTPATH environment variable. - -% Each font has an entry consisting of three items: -% -% - The name by which the font is known inside Ghostscript -% (a Ghostscript name preceded by a `/', or a string enclosed -% in parentheses). This is used to find the file from which -% a font of a given name should be loaded. -% -% - Information depending on whether this is a real font or a -% font alias: -% -% - For real fonts, the name of the Ghostscript font -% file (a Ghostscript string, enclosed in parentheses). -% The filename should include the extension, which (by -% convention) is `.gsf'. `.pfa' and `.pfb' files are -% also usable as fonts for Ghostscript. -% -% - For font aliases, the name of the font which should -% be used when this one is requested, preceded by a -% `/'. See the entry for Charter below for an example. -% Note that an alias name cannot be enclosed in parentheses. -% -% - At least one space or tab, and a terminating semicolon. - -% Because of limitations in the MS-DOS environment, Ghostscript font -% file names must be no more than 8 characters long, must consist only -% of LOWER CASE letters, digits, and underscores, and must start with a -% letter. Font names, on the other hand, need only obey the syntax of -% names in the Ghostscript language, which is much more liberal. - -% The following table is actually a Ghostscript data structure. -% If you add new entries, be sure to copy the punctuation accurately; -% in particular, you must leave at least one space or tab between each -% field in the entry. Also, please read fonts.doc for important information -% about font names. - -% Note that .pfa and .pfb fonts are compatible with Adobe Type Manager -% and other programs that don't include full PostScript interpreters, -% as well as with PostScript interpreters; .gsf fonts are compatible with -% PostScript interpreters, but not with ATM or similar programs. - -% -% -% Fonts contributed by: -% URW++ Design and Development Incorporated -% Poppenbuetteler Bogen 29A -% D-22399 Hamburg -% Germany -% tel. +49 (40) 60 60 50 -% fax +49 (40) 60 60 51 11 -% http://www.urwpp.de -% for distribution under the GNU License and Aladdin Free Public License. -% See the notice at the head of this Fontmap file for licensing terms. -% Each of these fonts is individually covered by the license: -% for licensing purposes, they are not "part of" any larger entity. -% The following notice applies to these fonts: -% -% Copyright URW Software, Copyright 1994 by URW. -% - -% Actual fonts - -/URWBookmanL-DemiBold (b018015l.pfb) ; -/URWBookmanL-DemiBoldItal (b018035l.pfb) ; -/URWBookmanL-Ligh (b018012l.pfb) ; -/URWBookmanL-LighItal (b018032l.pfb) ; - -/NimbusMonL-Regu (n022003l.pfb) ; -/NimbusMonL-ReguObli (n022023l.pfb) ; -/NimbusMonL-Bold (n022004l.pfb) ; -/NimbusMonL-BoldObli (n022024l.pfb) ; - -/URWGothicL-Book (a010013l.pfb) ; -/URWGothicL-BookObli (a010033l.pfb) ; -/URWGothicL-Demi (a010015l.pfb) ; -/URWGothicL-DemiObli (a010035l.pfb) ; - -/NimbusSanL-Regu (n019003l.pfb) ; -/NimbusSanL-ReguItal (n019023l.pfb) ; -/NimbusSanL-Bold (n019004l.pfb) ; -/NimbusSanL-BoldItal (n019024l.pfb) ; - -/NimbusSanL-ReguCond (n019043l.pfb) ; -/NimbusSanL-ReguCondItal (n019063l.pfb) ; -/NimbusSanL-BoldCond (n019044l.pfb) ; -/NimbusSanL-BoldCondItal (n019064l.pfb) ; - -/URWPalladioL-Roma (p052003l.pfb) ; -/URWPalladioL-Ital (p052023l.pfb) ; -/URWPalladioL-Bold (p052004l.pfb) ; -/URWPalladioL-BoldItal (p052024l.pfb) ; - -/CenturySchL-Roma (c059013l.pfb) ; -/CenturySchL-Ital (c059033l.pfb) ; -/CenturySchL-Bold (c059016l.pfb) ; -/CenturySchL-BoldItal (c059036l.pfb) ; - -/NimbusRomNo9L-Regu (n021003l.pfb) ; -/NimbusRomNo9L-ReguItal (n021023l.pfb) ; -/NimbusRomNo9L-Medi (n021004l.pfb) ; -/NimbusRomNo9L-MediItal (n021024l.pfb) ; - -/StandardSymL (s050000l.pfb) ; - -/URWChanceryL-MediItal (z003034l.pfb) ; - -/Dingbats (d050000l.pfb) ; - -% Aliases -% These Adobe fonts are available with DPS on IRIX, so they commented out: - -%/Bookman-Demi /URWBookmanL-DemiBold ; -%/Bookman-DemiItalic /URWBookmanL-DemiBoldItal ; -%/Bookman-Light /URWBookmanL-Ligh ; -%/Bookman-LightItalic /URWBookmanL-LighItal ; - -%/Courier /NimbusMonL-Regu ; -%/Courier-Oblique /NimbusMonL-ReguObli ; -%/Courier-Bold /NimbusMonL-Bold ; -%/Courier-BoldOblique /NimbusMonL-BoldObli ; - -%/AvantGarde-Book /URWGothicL-Book ; -%/AvantGarde-BookOblique /URWGothicL-BookObli ; -%/AvantGarde-Demi /URWGothicL-Demi ; -%/AvantGarde-DemiOblique /URWGothicL-DemiObli ; - -%/Helvetica /NimbusSanL-Regu ; -%/Helvetica-Oblique /NimbusSanL-ReguItal ; -%/Helvetica-Bold /NimbusSanL-Bold ; -%/Helvetica-BoldOblique /NimbusSanL-BoldItal ; - -%/Helvetica-Narrow /NimbusSanL-ReguCond ; -%/Helvetica-Narrow-Oblique /NimbusSanL-ReguCondItal ; -%/Helvetica-Narrow-Bold /NimbusSanL-BoldCond ; -%/Helvetica-Narrow-BoldOblique /NimbusSanL-BoldCondItal ; - -%/Palatino-Roman /URWPalladioL-Roma ; -%/Palatino-Italic /URWPalladioL-Ital ; -%/Palatino-Bold /URWPalladioL-Bold ; -%/Palatino-BoldItalic /URWPalladioL-BoldItal ; - -%/NewCenturySchlbk-Roman /CenturySchL-Roma ; -%/NewCenturySchlbk-Italic /CenturySchL-Ital ; -%/NewCenturySchlbk-Bold /CenturySchL-Bold ; -%/NewCenturySchlbk-BoldItalic /CenturySchL-BoldItal ; - -%/Times-Roman /NimbusRomNo9L-Regu ; -%/Times-Italic /NimbusRomNo9L-ReguItal ; -%/Times-Bold /NimbusRomNo9L-Medi ; -%/Times-BoldItalic /NimbusRomNo9L-MediItal ; - -%/Symbol /StandardSymL ; - -%/ZapfChancery-MediumItalic /URWChanceryL-MediItal ; - -%/ZapfDingbats /Dingbats ; - -% -% -% Type 1 fonts contributed to the X11R5 distribution. -% - -% The following notice accompanied the Charter fonts. -% -% (c) Copyright 1989-1992, Bitstream Inc., Cambridge, MA. -% -% You are hereby granted permission under all Bitstream propriety rights -% to use, copy, modify, sublicense, sell, and redistribute the 4 Bitstream -% Charter (r) Type 1 outline fonts and the 4 Courier Type 1 outline fonts -% for any purpose and without restriction; provided, that this notice is -% left intact on all copies of such fonts and that Bitstream's trademark -% is acknowledged as shown below on all unmodified copies of the 4 Charter -% Type 1 fonts. -% -% BITSTREAM CHARTER is a registered trademark of Bitstream Inc. - -% The Bitstream Charter fonts have different names (CharterBT- -% instead of Charter-), but Ghostscript doesn't care. -/Charter-Roman (bchr.pfa) ; -/Charter-Italic (bchri.pfa) ; -/Charter-Bold (bchb.pfa) ; -/Charter-BoldItalic (bchbi.pfa) ; - -% The following notice accompanied the Utopia font: -% -% Permission to use, reproduce, display and distribute the listed -% typefaces is hereby granted, provided that the Adobe Copyright notice -% appears in all whole and partial copies of the software and that the -% following trademark symbol and attribution appear in all unmodified -% copies of the software: -% -% Copyright (c) 1989 Adobe Systems Incorporated -% Utopia (R) -% Utopia is a registered trademark of Adobe Systems Incorporated -% -% The Adobe typefaces (Type 1 font program, bitmaps and Adobe Font -% Metric files) donated are: -% -% Utopia Regular -% Utopia Italic -% Utopia Bold -% Utopia Bold Italic - -% The original Utopia files are available with IRIX and DPS so need -% for aliases, HJG. - -%/Utopia-Regular (putr.pfa) ; -%/Utopia-Italic (putri.pfa) ; -%/Utopia-Bold (putb.pfa) ; -%/Utopia-BoldItalic (putbi.pfa) ; - -% -% -% Fonts contributed by URW GmbH for distribution under the GNU License. -% The following notice accompanied these fonts: -% -% U004006T URW Grotesk 2031 Bold PostScript Type 1 Font Program -% U003043T URW Antiqua 2051 Regular Condensed PostScript Type 1 Font Program -% -% Copyright (c) 1992 URW GmbH, Hamburg, Germany -% -% This program is free software; you can redistribute it and/or modify -% it under the terms of the GNU General Public License as published by -% the Free Software Foundation; either version 2 of the License, or -% (at your option) later version. -% -% This program is distributed in the hope that it will be useful, -% but WITHOUT ANY WARRANTY; wihtout even the implied warranty of -% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -% See the GNU General Public License for more details. -% -% You should have received a copy of the GNU General Public License -% along with this program; if not, write to the Free Software -% Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -% -% Address: -% URW GmbH -% PC Support -% Harksheider Strasse 102 -% 2000 Hamburg 65 -% Germany -% Phone: +49 40 60 60 50 (Reception) -% Phone: +49 40 60 60 52 30 (PC Support) -% Fax : +49 40 60 60 52 52 -% - -/URWAntiquaT-RegularCondensed (u003043t.gsf) ; -/URWGroteskT-Bold (u004006t.gsf) ; - -% -% -% Shareware Kana fonts. These are subject to the following notice: -% -% These copyrighted fonts were developed by Kevin Hartig. Permission is -% granted to freely distribute them in entirety along with this statement. -% This is shareware. If you decide to use these fonts please contribute -% $10 US to help support further freeware and shareware software development. -% Questions and comments may be sent to: -% -% hartig@fsl.noaa.gov -% khartig@nyx.cs.du.edu -% -% Kevin Hartig -% 1126 Collyer Street -% Longmont, CO 80501 USA -% -% copyright 1993. - -% Hiragana and Katakana fonts. The character names are inappropriate, -% and the encoding is probably not related to any known standard. - -/Calligraphic-Hiragana (fhirw.gsf) ; -/Calligraphic-Katakana (fkarw.gsf) ; - -% -% -% Public-domain fonts. These have no copyright, and are of unknown quality. - -% Cyrillic fonts. The character names are inappropriate, -% and the encoding is probably not related to any known standard. - -/Shareware-Cyrillic-Regular (fcyr.gsf) ; -/Shareware-Cyrillic-Italic (fcyri.gsf) ; - -% Aliases -/Cyrillic /Cyrillic-Regular ; -/Cyrillic-Regular /Shareware-Cyrillic-Regular ; -/Cyrillic-Italic /Shareware-Cyrillic-Italic ; - -% -% -% Fonts converted from Hershey outlines. These are constructed and -% maintained manually. These are also in the public domain. -% -% The suggested UniqueID's and filenames are constructed differently for -% these than for the ones above, because of the strange way that the Hershey -% fonts were constructed. The scheme for these looks like: -% -% 42TTXY0 -% -% TT = typeface, X = ``class'', Y = variation -% -% The typeface names and numbers are listed in fonts.mak. -% -% class: -% 0 = normal = r -% 1 = simplex = s -% 2 = complex = c -% 3 = triplex = t -% 4 = duplex = d -% -% variation: -% 0 = normal (omitted) -% 1 = oblique = o -% 2 = italic = i -% 3 = bold = b -% 4 = bold oblique = bo -% 5 = bold italic = bi -% - -% Fonts created by Thomas Wolff <wolff@inf.fu-berlin.de>, by adding -% accents, accented characters, and various other non-alphabetics -% to the original Hershey fonts. These are "freeware", not to be sold. - -/Hershey-Gothic-English (hrger.pfa) ; % 5066533 -/Hershey-Gothic-German (hrgrr.pfa) ; -/Hershey-Gothic-Italian (hritr.pfa) ; - -/Hershey-Plain-Duplex (hrpld.pfa) ; -/Hershey-Plain-Duplex-Italic (hrpldi.pfa) ; -/Hershey-Plain-Triplex (hrplt.pfa) ; -/Hershey-Plain-Triplex-Italic (hrplti.pfa) ; - -/Hershey-Script-Complex (hrscc.pfa) ; -/Hershey-Script-Simplex (hrscs.pfa) ; % 5066541 - -% Fonts created algorithmically from the above. - -/Hershey-Gothic-English-Bold (hrgerb.gsf) ; % 5066542 -/Hershey-Gothic-English-Oblique (hrgero.gsf) ; -/Hershey-Gothic-English-SemiBold (hrgerd.gsf) ; -/Hershey-Gothic-German-Bold (hrgrrb.gsf) ; -/Hershey-Gothic-German-Oblique (hrgrro.gsf) ; -/Hershey-Gothic-Italian-Bold (hritrb.gsf) ; -/Hershey-Gothic-Italian-Oblique (hritro.gsf) ; - -/Hershey-Plain-Duplex-Bold (hrpldb.gsf) ; -/Hershey-Plain-Duplex-Bold-Italic (hrpldbi.gsf) ; -/Hershey-Plain-Triplex-Bold (hrpltb.gsf) ; -/Hershey-Plain-Triplex-Bold-Italic (hrpltbi.gsf) ; - -/Hershey-Script-Complex-Bold (hrsccb.gsf) ; -/Hershey-Script-Complex-Oblique (hrscco.gsf) ; -/Hershey-Script-Simplex-Bold (hrscsb.gsf) ; -/Hershey-Script-Simplex-Oblique (hrscso.gsf) ; % 5066556 - -% Fonts consisting only of characters from the original Hershey -% distribution. These are Type 3 fonts. - -/Hershey-Greek-Complex (hrgkc.gsf) ; % 5066557 -/Hershey-Greek-Simplex (hrgks.gsf) ; - -/Hershey-Plain (hrplr.gsf) ; -/Hershey-Plain-Simplex (hrpls.gsf) ; % 5066560 - -% Fonts created algorithmically from the above. - -/Hershey-Plain-Bold (hrplrb.gsf) ; % 5066561 -/Hershey-Plain-Bold-Oblique (hrplrbo.gsf) ; -/Hershey-Plain-Oblique (hrplro.gsf) ; -/Hershey-Plain-Simplex-Bold (hrplsb.gsf) ; -/Hershey-Plain-Simplex-Bold-Oblique (hrplsbo.gsf) ; -/Hershey-Plain-Simplex-Oblique (hrplso.gsf) ; % 5066566 - -% This font, and only this font among the Hershey fonts, uses -% the SymbolEncoding. - -/Hershey-Symbol (hrsyr.gsf) ; % 5066567 diff --git a/Master/tlpkg/tlgs/lib/Fontmap.Sol b/Master/tlpkg/tlgs/lib/Fontmap.Sol deleted file mode 100644 index 337e942c775..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.Sol +++ /dev/null @@ -1,486 +0,0 @@ -% Copyright (C) 1996, 1999 Aladdin Enterprises. All rights reserved. -% -% This software is provided AS-IS with no warranty, either express or -% implied. -% -% This software is distributed under license and may not be copied, -% modified or distributed except as expressly authorized under the terms -% of the license contained in the file LICENSE in this distribution. -% -% For more information about licensing, please refer to -% http://www.ghostscript.com/licensing/. For information on -% commercial licensing, go to http://www.artifex.com/licensing/ or -% contact Artifex Software, Inc., 101 Lucas Valley Road #110, -% San Rafael, CA 94903, U.S.A., +1(415)492-9861. - -% $Id: Fontmap.Sol 6300 2005-12-28 19:56:24Z giles $ -% Fontmap.Solaris - Ghostscript Fontmap for Solaris 2.3 and above -% =============================================================== -% -% The Solaris 2.3 (and above) operating system from Sun Microsystems comes with -% Display Postscript (DPS), including certain Type1 and Type3 PostScript fonts. -% Using these fonts instead of the default Ghostscript fonts greatly improves -% the visual quality of Ghostscript rendered documents, especially at larger -% font sizes. You should definately use these fonts if you have Solaris 2.3 or -% above. -% -% To use the Solaris 2 DPS fonts, simply copy this file (Fontmap.Solaris) to -% -% /usr/local/lib/Ghostscript/VERSION/Fontmap -% (where VERSION is the version number of Ghostscript, eg: 3.33) -% -% and set the environment variable GS_LIB as follows: -% -% GS_LIB=/usr/openwin/lib/X11/fonts/Type1:/usr/openwin/lib/X11/fonts/Type3 -% export GS_LIB -% -% You can use /usr/openwin/lib/fonts/Type1/outline instead if you like, it -% makes no difference (the files in /usr/openwin/lib/fonts/Type1 are symlinks -% into /usr/openwin/lib/fonts/Type1/outline). -% -% Instead of setting GS_LIB, you could add the above directories to -% GS_LIB_DEFAULT in your makefile before building Ghostscript. -% -% -% IMPORTANT NOTE -% ============== -% -% Note that simply setting GS_FONTPATH may not work, because for some reason -% some versions of gs can't seem to find any fonts in -% /usr/openwin/lib/X11/fonts/Type1/outline. -% It says: "15 files, 15 scanned, 0 new fonts". -% -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - -% ---------------------------------------------------------------- - -% This file is a catalog of fonts known to Ghostscript. Any font -% that is to be loaded automatically when named must be in this catalog, -% except for fonts that Ghostscript finds automatically in directories -% named in the GS_FONTPATH environment variable. - -% Each font has an entry consisting of three items: -% -% - The name by which the font is known inside Ghostscript -% (a Ghostscript name preceded by a `/', or a string enclosed -% in parentheses). This is used to find the file from which -% a font of a given name should be loaded. -% -% - Information depending on whether this is a real font or a -% font alias: -% -% - For real fonts, the name of the Ghostscript font -% file (a Ghostscript string, enclosed in parentheses). -% The filename should include the extension, which (by -% convention) is `.gsf'. `.pfa' and `.pfb' files are -% also usable as fonts for Ghostscript. -% -% - For font aliases, the name of the font which should -% be used when this one is requested, preceded by a -% `/'. See the entry for Charter below for an example. -% Note that an alias name cannot be enclosed in parentheses. -% -% - At least one space or tab, and a terminating semicolon. - -% Because of limitations in the MS-DOS environment, Ghostscript font -% file names must be no more than 8 characters long, must consist only -% of LOWER CASE letters, digits, and underscores, and must start with a -% letter. Font names, on the other hand, need only obey the syntax of -% names in the Ghostscript language, which is much more liberal. - -% The following table is actually a Ghostscript data structure. -% If you add new entries, be sure to copy the punctuation accurately; -% in particular, you must leave at least one space or tab between each -% field in the entry. Also, please read fonts.doc for important information -% about font names. - -% Note that .pfa and .pfb fonts are compatible with Adobe Type Manager -% and other programs that don't include full PostScript interpreters, -% as well as with PostScript interpreters; .gsf fonts are compatible with -% PostScript interpreters, but not with ATM or similar programs. - -% -% -% Fonts contributed by: -% URW++ Design and Development Incorporated -% Poppenbuetteler Bogen 29A -% D-22399 Hamburg -% Germany -% tel. +49 (40) 60 60 50 -% fax +49 (40) 60 60 51 11 -% http://www.urwpp.de -% for distribution under the GNU License and Aladdin Free Public License. -% See the notice at the head of this Fontmap file for licensing terms. -% Each of these fonts is individually covered by the license: -% for licensing purposes, they are not "part of" any larger entity. -% The following notice applies to these fonts: -% -% Copyright URW Software, Copyright 1994 by URW. -% - -% Actual fonts - -/URWBookmanL-DemiBold (b018015l.pfb) ; -/URWBookmanL-DemiBoldItal (b018035l.pfb) ; -/URWBookmanL-Ligh (b018012l.pfb) ; -/URWBookmanL-LighItal (b018032l.pfb) ; - -/NimbusMonL-Regu (n022003l.pfb) ; -/NimbusMonL-ReguObli (n022023l.pfb) ; -/NimbusMonL-Bold (n022004l.pfb) ; -/NimbusMonL-BoldObli (n022024l.pfb) ; - -/URWGothicL-Book (a010013l.pfb) ; -/URWGothicL-BookObli (a010033l.pfb) ; -/URWGothicL-Demi (a010015l.pfb) ; -/URWGothicL-DemiObli (a010035l.pfb) ; - -/NimbusSanL-Regu (n019003l.pfb) ; -/NimbusSanL-ReguItal (n019023l.pfb) ; -/NimbusSanL-Bold (n019004l.pfb) ; -/NimbusSanL-BoldItal (n019024l.pfb) ; - -/NimbusSanL-ReguCond (n019043l.pfb) ; -/NimbusSanL-ReguCondItal (n019063l.pfb) ; -/NimbusSanL-BoldCond (n019044l.pfb) ; -/NimbusSanL-BoldCondItal (n019064l.pfb) ; - -/URWPalladioL-Roma (p052003l.pfb) ; -/URWPalladioL-Ital (p052023l.pfb) ; -/URWPalladioL-Bold (p052004l.pfb) ; -/URWPalladioL-BoldItal (p052024l.pfb) ; - -/CenturySchL-Roma (c059013l.pfb) ; -/CenturySchL-Ital (c059033l.pfb) ; -/CenturySchL-Bold (c059016l.pfb) ; -/CenturySchL-BoldItal (c059036l.pfb) ; - -/NimbusRomNo9L-Regu (n021003l.pfb) ; -/NimbusRomNo9L-ReguItal (n021023l.pfb) ; -/NimbusRomNo9L-Medi (n021004l.pfb) ; -/NimbusRomNo9L-MediItal (n021024l.pfb) ; - -/StandardSymL (s050000l.pfb) ; - -/URWChanceryL-MediItal (z003034l.pfb) ; - -/Dingbats (d050000l.pfb) ; - -% Aliases - -/Bookman-Demi /URWBookmanL-DemiBold ; -/Bookman-DemiItalic /URWBookmanL-DemiBoldItal ; -/Bookman-Light /URWBookmanL-Ligh ; -/Bookman-LightItalic /URWBookmanL-LighItal ; - -/Courier /NimbusMonL-Regu ; -/Courier-Oblique /NimbusMonL-ReguObli ; -/Courier-Bold /NimbusMonL-Bold ; -/Courier-BoldOblique /NimbusMonL-BoldObli ; - -/AvantGarde-Book /URWGothicL-Book ; -/AvantGarde-BookOblique /URWGothicL-BookObli ; -/AvantGarde-Demi /URWGothicL-Demi ; -/AvantGarde-DemiOblique /URWGothicL-DemiObli ; - -% Solaris 2 DPS has Helvetica as a Type1 font. -%/Helvetica /NimbusSanL-Regu ; -%/Helvetica-Oblique /NimbusSanL-ReguItal ; -%/Helvetica-Bold /NimbusSanL-Bold ; -%/Helvetica-BoldOblique /NimbusSanL-BoldItal ; - -/Helvetica-Narrow /NimbusSanL-ReguCond ; -/Helvetica-Narrow-Oblique /NimbusSanL-ReguCondItal ; -/Helvetica-Narrow-Bold /NimbusSanL-BoldCond ; -/Helvetica-Narrow-BoldOblique /NimbusSanL-BoldCondItal ; - -/Palatino-Roman /URWPalladioL-Roma ; -/Palatino-Italic /URWPalladioL-Ital ; -/Palatino-Bold /URWPalladioL-Bold ; -/Palatino-BoldItalic /URWPalladioL-BoldItal ; - -/NewCenturySchlbk-Roman /CenturySchL-Roma ; -/NewCenturySchlbk-Italic /CenturySchL-Ital ; -/NewCenturySchlbk-Bold /CenturySchL-Bold ; -/NewCenturySchlbk-BoldItalic /CenturySchL-BoldItal ; - -% Solaris 2 DPS has Times as a Type1 font. -%/Times-Roman /NimbusRomNo9L-Regu ; -%/Times-Italic /NimbusRomNo9L-ReguItal ; -%/Times-Bold /NimbusRomNo9L-Medi ; -%/Times-BoldItalic /NimbusRomNo9L-MediItal ; - -% Solaris 2 DPS has Symbol as a Type1 font. -%/Symbol /StandardSymL ; - -/ZapfChancery-MediumItalic /URWChanceryL-MediItal ; - -/ZapfDingbats /Dingbats ; - -% -% -% Type 1 fonts contributed to the X11R5 distribution. -% - -% The following notice accompanied the Charter fonts. -% -% (c) Copyright 1989-1992, Bitstream Inc., Cambridge, MA. -% -% You are hereby granted permission under all Bitstream propriety rights -% to use, copy, modify, sublicense, sell, and redistribute the 4 Bitstream -% Charter (r) Type 1 outline fonts and the 4 Courier Type 1 outline fonts -% for any purpose and without restriction; provided, that this notice is -% left intact on all copies of such fonts and that Bitstream's trademark -% is acknowledged as shown below on all unmodified copies of the 4 Charter -% Type 1 fonts. -% -% BITSTREAM CHARTER is a registered trademark of Bitstream Inc. - -/CharterBT-Roman (bchr.pfa) ; -/CharterBT-Italic (bchri.pfa) ; -/CharterBT-Bold (bchb.pfa) ; -/CharterBT-BoldItalic (bchbi.pfa) ; - -% Aliases - -/Charter-Roman /CharterBT-Roman ; -/Charter-Italic /CharterBT-Italic ; -/Charter-Bold /CharterBT-Bold ; -/Charter-BoldItalic /CharterBT-BoldItalic ; - -% The following notice accompanied the Utopia font: -% -% Permission to use, reproduce, display and distribute the listed -% typefaces is hereby granted, provided that the Adobe Copyright notice -% appears in all whole and partial copies of the software and that the -% following trademark symbol and attribution appear in all unmodified -% copies of the software: -% -% Copyright (c) 1989 Adobe Systems Incorporated -% Utopia (R) -% Utopia is a registered trademark of Adobe Systems Incorporated -% -% The Adobe typefaces (Type 1 font program, bitmaps and Adobe Font -% Metric files) donated are: -% -% Utopia Regular -% Utopia Italic -% Utopia Bold -% Utopia Bold Italic - -/Utopia-Regular (putr.pfa) ; -/Utopia-Italic (putri.pfa) ; -/Utopia-Bold (putb.pfa) ; -/Utopia-BoldItalic (putbi.pfa) ; - -% -% -% Fonts contributed by URW GmbH for distribution under the GNU License. -% The following notice accompanied these fonts: -% -% U004006T URW Grotesk 2031 Bold PostScript Type 1 Font Program -% U003043T URW Antiqua 2051 Regular Condensed PostScript Type 1 Font Program -% -% Copyright (c) 1992 URW GmbH, Hamburg, Germany -% -% This program is free software; you can redistribute it and/or modify -% it under the terms of the GNU General Public License as published by -% the Free Software Foundation; either version 2 of the License, or -% (at your option) later version. -% -% This program is distributed in the hope that it will be useful, -% but WITHOUT ANY WARRANTY; wihtout even the implied warranty of -% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -% See the GNU General Public License for more details. -% -% You should have received a copy of the GNU General Public License -% along with this program; if not, write to the Free Software -% Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111 U.S.A. -% -% Address: -% URW GmbH -% PC Support -% Harksheider Strasse 102 -% 2000 Hamburg 65 -% Germany -% Phone: +49 40 60 60 50 (Reception) -% Phone: +49 40 60 60 52 30 (PC Support) -% Fax : +49 40 60 60 52 52 -% - -/URWAntiquaT-RegularCondensed (u003043t.gsf) ; -/URWGroteskT-Bold (u004006t.gsf) ; - -% -% -% Shareware Kana fonts. These are subject to the following notice: -% -% These copyrighted fonts were developed by Kevin Hartig. Permission is -% granted to freely distribute them in entirety along with this statement. -% This is shareware. If you decide to use these fonts please contribute -% $10 US to help support further freeware and shareware software development. -% Questions and comments may be sent to: -% -% hartig@fsl.noaa.gov -% khartig@nyx.cs.du.edu -% -% Kevin Hartig -% 1126 Collyer Street -% Longmont, CO 80501 USA -% -% copyright 1993. - -% Hiragana and Katakana fonts. The character names are inappropriate, -% and the encoding is probably not related to any known standard. - -/Calligraphic-Hiragana (fhirw.gsf) ; -/Calligraphic-Katakana (fkarw.gsf) ; - -% -% -% Public-domain fonts. These have no copyright, and are of unknown quality. - -% Cyrillic fonts. The character names are inappropriate, -% and the encoding is probably not related to any known standard. - -/Shareware-Cyrillic-Regular (fcyr.gsf) ; -/Shareware-Cyrillic-Italic (fcyri.gsf) ; - -% Aliases -/Cyrillic /Cyrillic-Regular ; -/Cyrillic-Regular /Shareware-Cyrillic-Regular ; -/Cyrillic-Italic /Shareware-Cyrillic-Italic ; - -% -% -% Fonts converted from Hershey outlines. These are constructed and -% maintained manually. These are also in the public domain. -% -% The suggested UniqueID's and filenames are constructed differently for -% these than for the ones above, because of the strange way that the Hershey -% fonts were constructed. The scheme for these looks like: -% -% 42TTXY0 -% -% TT = typeface, X = ``class'', Y = variation -% -% The typeface names and numbers are listed in fonts.mak. -% -% class: -% 0 = normal = r -% 1 = simplex = s -% 2 = complex = c -% 3 = triplex = t -% 4 = duplex = d -% -% variation: -% 0 = normal (omitted) -% 1 = oblique = o -% 2 = italic = i -% 3 = bold = b -% 4 = bold oblique = bo -% 5 = bold italic = bi -% - -% Fonts created by Thomas Wolff <wolff@inf.fu-berlin.de>, by adding -% accents, accented characters, and various other non-alphabetics -% to the original Hershey fonts. These are "freeware", not to be sold. - -/Hershey-Gothic-English (hrger.pfa) ; % 5066533 -/Hershey-Gothic-German (hrgrr.pfa) ; -/Hershey-Gothic-Italian (hritr.pfa) ; - -/Hershey-Plain-Duplex (hrpld.pfa) ; -/Hershey-Plain-Duplex-Italic (hrpldi.pfa) ; -/Hershey-Plain-Triplex (hrplt.pfa) ; -/Hershey-Plain-Triplex-Italic (hrplti.pfa) ; - -/Hershey-Script-Complex (hrscc.pfa) ; -/Hershey-Script-Simplex (hrscs.pfa) ; % 5066541 - -% Fonts created algorithmically from the above. - -/Hershey-Gothic-English-Bold (hrgerb.gsf) ; % 5066542 -/Hershey-Gothic-English-Oblique (hrgero.gsf) ; -/Hershey-Gothic-English-SemiBold (hrgerd.gsf) ; -/Hershey-Gothic-German-Bold (hrgrrb.gsf) ; -/Hershey-Gothic-German-Oblique (hrgrro.gsf) ; -/Hershey-Gothic-Italian-Bold (hritrb.gsf) ; -/Hershey-Gothic-Italian-Oblique (hritro.gsf) ; - -/Hershey-Plain-Duplex-Bold (hrpldb.gsf) ; -/Hershey-Plain-Duplex-Bold-Italic (hrpldbi.gsf) ; -/Hershey-Plain-Triplex-Bold (hrpltb.gsf) ; -/Hershey-Plain-Triplex-Bold-Italic (hrpltbi.gsf) ; - -/Hershey-Script-Complex-Bold (hrsccb.gsf) ; -/Hershey-Script-Complex-Oblique (hrscco.gsf) ; -/Hershey-Script-Simplex-Bold (hrscsb.gsf) ; -/Hershey-Script-Simplex-Oblique (hrscso.gsf) ; % 5066556 - -% Fonts consisting only of characters from the original Hershey -% distribution. These are Type 3 fonts. - -/Hershey-Greek-Complex (hrgkc.gsf) ; % 5066557 -/Hershey-Greek-Simplex (hrgks.gsf) ; - -/Hershey-Plain (hrplr.gsf) ; -/Hershey-Plain-Simplex (hrpls.gsf) ; % 5066560 - -% Fonts created algorithmically from the above. - -/Hershey-Plain-Bold (hrplrb.gsf) ; % 5066561 -/Hershey-Plain-Bold-Oblique (hrplrbo.gsf) ; -/Hershey-Plain-Oblique (hrplro.gsf) ; -/Hershey-Plain-Simplex-Bold (hrplsb.gsf) ; -/Hershey-Plain-Simplex-Bold-Oblique (hrplsbo.gsf) ; -/Hershey-Plain-Simplex-Oblique (hrplso.gsf) ; % 5066566 - -% This font, and only this font among the Hershey fonts, uses -% the SymbolEncoding. - -/Hershey-Symbol (hrsyr.gsf) ; % 5066567 -% -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% -% Solaris 2 Display PostScript Type1 and Type3 fonts... -% - -/Helvetica (Helvetica.pfa) ; -/Helvetica-Bold (Helvetica-Bold.pfa) ; -/Helvetica-BoldOblique (Helvetica-BoldOblique.pfa) ; -/Helvetica-Oblique (Helvetica-Oblique.pfa) ; - -/Symbol (Symbol.pfa) ; -/SymbolSet /Symbol ; - -/Times-Bold (Times-Bold.pfa) ; -/Times-BoldItalic (Times-BoldItalic.pfa) ; -/Times-Italic (Times-Italic.pfa) ; -/Times-Roman (Times-Roman.pfa) ; -/TimesNewRoman /Times-Roman ; -/TimesNewRoman-Bold /Times-Bold ; -/TimesNewRoman-BoldItalic /Times-BoldItalic ; -/TimesNewRoman-Italic /Times-Italic ; - -/Dijkstra (Dijkstra.ps) ; - -/Hershey-Cyrillic (HrshCyr.ps) ; - -/Hershey-Gothic (HrshGoth.ps) ; - -/Hershey-Greek (HrshGrk.ps) ; -/Hershey-Greek-Narrow (HrshGrkN.ps) ; -/Hershey-Greekp (HrshGrkp.ps) ; - -/Hershey-Italic (HrshI.ps) ; -/Hershey-Italic-Narrow (HrshIN.ps) ; -/Hershey-Italic-Wide (HrshIW.ps) ; -/Hershey-Roman (HrshRom.ps) ; -/Hershey-Roman-Narrow (HrshRomN.ps) ; -/Hershey-Roman-Wide (HrshRomW.ps) ; -/Hershey-Romand (HrshRomd.ps) ; -/Hershey-Romanp (HrshRomp.ps) ; - -/Hershey-Script (HrshScr.ps) ; -/Hershey-Script-Narrow (HrshScrN.ps) ; diff --git a/Master/tlpkg/tlgs/lib/Fontmap.TeXLive b/Master/tlpkg/tlgs/lib/Fontmap.TeXLive deleted file mode 100644 index 3dc7fe38cef..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.TeXLive +++ /dev/null @@ -1,108 +0,0 @@ -%% Fontmap.TeXLive -%% $Id$ - -%% This file is part of TeXLive. -%% You may freely use, modify and/or distribute this file. - -%% Bitstream Charter - -/CharterBT-Bold (bchb8a.pfb) ; -/CharterBT-BoldItalic (bchbi8a.pfb) ; -/CharterBT-Roman (bchr8a.pfb) ; -/CharterBT-Italic (bchri8a.pfb) ; - -%% Adobe Utopia - -/Utopia-Bold (putb8a.pfb) ; -/Utopia-BoldItalic (putbi8a.pfb) ; -/Utopia-Regular (putr8a.pfb) ; -/Utopia-Italic (putri8a.pfb) ; - -%% URW LW35 Fonts - -/URWGothicL-Demi (uagd8a.pfb) ; -/URWGothicL-DemiObli (uagdo8a.pfb) ; -/URWGothicL-Book (uagk8a.pfb) ; -/URWGothicL-BookObli (uagko8a.pfb) ; -/URWBookmanL-DemiBold (ubkd8a.pfb) ; -/URWBookmanL-DemiBoldItal (ubkdi8a.pfb) ; -/URWBookmanL-Ligh (ubkl8a.pfb) ; -/URWBookmanL-LighItal (ubkli8a.pfb) ; -/NimbusMonL-Bold (ucrb8a.pfb) ; -/NimbusMonL-BoldObli (ucrbo8a.pfb) ; -/NimbusMonL-Regu (ucrr8a.pfb) ; -/NimbusMonL-ReguObli (ucrro8a.pfb) ; -/NimbusSanL-Bold (uhvb8a.pfb) ; -/NimbusSanL-BoldCond (uhvb8ac.pfb) ; -/NimbusSanL-BoldItal (uhvbo8a.pfb) ; -/NimbusSanL-BoldCondItal (uhvbo8ac.pfb) ; -%%%/NimbusSanL-Regu (uhvr8a-105.pfb) ; -/NimbusSanL-Regu (uhvr8a.pfb) ; -/NimbusSanL-ReguCond (uhvr8ac.pfb) ; -%%%/NimbusSanL-ReguItal (uhvro8a-105.pfb) ; -/NimbusSanL-ReguItal (uhvro8a.pfb) ; -/NimbusSanL-ReguCondItal (uhvro8ac.pfb) ; -/CenturySchL-Bold (uncb8a.pfb) ; -/CenturySchL-BoldItal (uncbi8a.pfb) ; -/CenturySchL-Roma (uncr8a.pfb) ; -/CenturySchL-Ital (uncri8a.pfb) ; -/URWPalladioL-Bold (uplb8a.pfb) ; -/URWPalladioL-BoldItal (uplbi8a.pfb) ; -/URWPalladioL-Roma (uplr8a.pfb) ; -/URWPalladioL-Ital (uplri8a.pfb) ; -/StandardSymL (usyr.pfb) ; -/NimbusRomNo9L-Medi (utmb8a.pfb) ; -/NimbusRomNo9L-MediItal (utmbi8a.pfb) ; -/NimbusRomNo9L-Regu (utmr8a.pfb) ; -/NimbusRomNo9L-ReguItal (utmri8a.pfb) ; -/URWChanceryL-MediItal (uzcmi8a.pfb) ; -/Dingbats (uzdr.pfb) ; - - -% Aliases - -/Bookman-Demi /URWBookmanL-DemiBold ; -/Bookman-DemiItalic /URWBookmanL-DemiBoldItal ; -/Bookman-Light /URWBookmanL-Ligh ; -/Bookman-LightItalic /URWBookmanL-LighItal ; - -/Courier /NimbusMonL-Regu ; -/Courier-Oblique /NimbusMonL-ReguObli ; -/Courier-Bold /NimbusMonL-Bold ; -/Courier-BoldOblique /NimbusMonL-BoldObli ; - -/AvantGarde-Book /URWGothicL-Book ; -/AvantGarde-BookOblique /URWGothicL-BookObli ; -/AvantGarde-Demi /URWGothicL-Demi ; -/AvantGarde-DemiOblique /URWGothicL-DemiObli ; - -/Helvetica /NimbusSanL-Regu ; -/Helvetica-Oblique /NimbusSanL-ReguItal ; -/Helvetica-Bold /NimbusSanL-Bold ; -/Helvetica-BoldOblique /NimbusSanL-BoldItal ; - -/Helvetica-Narrow /NimbusSanL-ReguCond ; -/Helvetica-Narrow-Oblique /NimbusSanL-ReguCondItal ; -/Helvetica-Narrow-Bold /NimbusSanL-BoldCond ; -/Helvetica-Narrow-BoldOblique /NimbusSanL-BoldCondItal ; - -/Palatino-Roman /URWPalladioL-Roma ; -/Palatino-Italic /URWPalladioL-Ital ; -/Palatino-Bold /URWPalladioL-Bold ; -/Palatino-BoldItalic /URWPalladioL-BoldItal ; - -/NewCenturySchlbk-Roman /CenturySchL-Roma ; -/NewCenturySchlbk-Italic /CenturySchL-Ital ; -/NewCenturySchlbk-Bold /CenturySchL-Bold ; -/NewCenturySchlbk-BoldItalic /CenturySchL-BoldItal ; - -/Times-Roman /NimbusRomNo9L-Regu ; -/Times-Italic /NimbusRomNo9L-ReguItal ; -/Times-Bold /NimbusRomNo9L-Medi ; -/Times-BoldItalic /NimbusRomNo9L-MediItal ; - -/Symbol /StandardSymL ; - -/ZapfChancery-MediumItalic /URWChanceryL-MediItal ; - -/ZapfDingbats /Dingbats ; diff --git a/Master/tlpkg/tlgs/lib/Fontmap.Ult b/Master/tlpkg/tlgs/lib/Fontmap.Ult deleted file mode 100644 index ffe425349c6..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.Ult +++ /dev/null @@ -1,146 +0,0 @@ -% Copyright (C) 1990, 1995, 1999 Aladdin Enterprises. All rights reserved. -% -% This software is provided AS-IS with no warranty, either express or -% implied. -% -% This software is distributed under license and may not be copied, -% modified or distributed except as expressly authorized under the terms -% of the license contained in the file LICENSE in this distribution. -% -% For more information about licensing, please refer to -% http://www.ghostscript.com/licensing/. For information on -% commercial licensing, go to http://www.artifex.com/licensing/ or -% contact Artifex Software, Inc., 101 Lucas Valley Road #110, -% San Rafael, CA 94903, U.S.A., +1(415)492-9861. - -% $Id: Fontmap.Ult 6300 2005-12-28 19:56:24Z giles $ -% Fontmap.Ult is derived from the standard Fontmap file distributed with -% ghostscript; for credits and sources see that file. The modifications here -% are valid for ULTRIX 4.3, and consist of defining some fonts and font -% aliases as the licensed fontfiles included in ULTRIX for use on ULTRIX -% workstations, which give better quality than the free fontfiles available -% for ghostscript. Under ULTRIX 4.3 the licensed fontfiles are found in -% -% /usr/lib/DPS/outline/decwin -% -% so that directory must either be built into ghostscript by redefining -% GS_LIB_DEFAULT when ghostscript is compiled, or else by defining an -% environmental variable GS_LIB_DEFAULT, which contains it as an element of -% the path, when running ghostscript. For instance, under the KornShell -% -% GS_LIB_DEFAULT=/usr/gs:/usr/lib/DPS/outline/decwin:/usr/gs/fonts -% export GS_LIB_DEFAULT -% -% Peter Kaiser (kaiser@acm.org) 27 January 1995 -% Updated by L. Peter Deutsch (ghost@aladdin.com) 5 January 1999 -% to include correct aliasing for the Bitstream Charter fonts - -/AvantGarde-Book (AvantGarde-Book) ; -/AvantGarde-BookOblique (AvantGarde-BookOblique) ; -/AvantGarde-Demi (AvantGarde-Demi) ; -/AvantGarde-DemiOblique (AvantGarde-DemiOblique) ; -/Courier (Courier) ; -/Courier-Bold (Courier-Bold) ; -/Courier-BoldOblique (Courier-BoldOblique) ; -/Courier-Oblique (Courier-Oblique) ; -/Helvetica (Helvetica) ; -/Helvetica-Bold (Helvetica-Bold) ; -/Helvetica-BoldOblique (Helvetica-BoldOblique) ; -/Helvetica-Oblique (Helvetica-Oblique) ; -/LubalinGraph-Book (LubalinGraph-Book) ; -/LubalinGraph-BookOblique (LubalinGraph-BookOblique) ; -/LubalinGraph-Demi (LubalinGraph-Demi) ; -/LubalinGraph-DemiOblique (LubalinGraph-DemiOblique) ; -/NewCenturySchlbk-Bold (NewCenturySchlbk-Bold) ; -/NewCenturySchlbk-BoldItalic (NewCenturySchlbk-BoldItalic) ; -/NewCenturySchlbk-Italic (NewCenturySchlbk-Italic) ; -/NewCenturySchlbk-Roman (NewCenturySchlbk-Roman) ; -/Souvenir-Demi (Souvenir-Demi) ; -/Souvenir-DemiItalic (Souvenir-DemiItalic) ; -/Souvenir-Light (Souvenir-Light) ; -/Souvenir-LightItalic (Souvenir-LightItalic) ; -/Symbol (Symbol) ; -/Times-Bold (Times-Bold) ; -/Times-BoldItalic (Times-BoldItalic) ; -/Times-Italic (Times-Italic) ; -/Times-Roman (Times-Roman) ; - -% Fonts distributed as part of ghostscript - -/Bookman-Demi (pbkd.gsf) ; -/Bookman-DemiItalic (pbkdi.gsf) ; -/Bookman-Light (pbkl.gsf) ; -/Bookman-LightItalic (pbkli.gsf) ; -/Calligraphic-Hiragana (fhirw.gsf) ; -/Calligraphic-Katakana (fkarw.gsf) ; -/CharterBT-Bold (bchb.pfa) ; -/CharterBT-BoldItalic (bchbi.pfa) ; -/CharterBT-Italic (bchri.pfa) ; -/CharterBT-Roman (bchr.pfa) ; -/Hershey-Gothic-English (hrger.pfa) ; -/Hershey-Gothic-English-Bold (hrgerb.gsf) ; -/Hershey-Gothic-English-Oblique (hrgero.gsf) ; -/Hershey-Gothic-English-SemiBold (hrgerd.gsf) ; -/Hershey-Gothic-German (hrgrr.pfa) ; -/Hershey-Gothic-German-Bold (hrgrrb.gsf) ; -/Hershey-Gothic-German-Oblique (hrgrro.gsf) ; -/Hershey-Gothic-Italian (hritr.pfa) ; -/Hershey-Gothic-Italian-Bold (hritrb.gsf) ; -/Hershey-Gothic-Italian-Oblique (hritro.gsf) ; -/Hershey-Greek-Complex (hrgkc.gsf) ; -/Hershey-Greek-Simplex (hrgks.gsf) ; -/Hershey-Plain (hrplr.gsf) ; -/Hershey-Plain-Bold (hrplrb.gsf) ; -/Hershey-Plain-Bold-Oblique (hrplrbo.gsf) ; -/Hershey-Plain-Duplex (hrpld.pfa) ; -/Hershey-Plain-Duplex-Bold (hrpldb.gsf) ; -/Hershey-Plain-Duplex-Bold-Italic (hrpldbi.gsf) ; -/Hershey-Plain-Duplex-Italic (hrpldi.pfa) ; -/Hershey-Plain-Oblique (hrplro.gsf) ; -/Hershey-Plain-Simplex (hrpls.gsf) ; -/Hershey-Plain-Simplex-Bold (hrplsb.gsf) ; -/Hershey-Plain-Simplex-Bold-Oblique (hrplsbo.gsf) ; -/Hershey-Plain-Simplex-Oblique (hrplso.gsf) ; -/Hershey-Plain-Triplex (hrplt.pfa) ; -/Hershey-Plain-Triplex-Bold (hrpltb.gsf) ; -/Hershey-Plain-Triplex-Bold-Italic (hrpltbi.gsf) ; -/Hershey-Plain-Triplex-Italic (hrplti.pfa) ; -/Hershey-Script-Complex (hrscc.pfa) ; -/Hershey-Script-Complex-Bold (hrsccb.gsf) ; -/Hershey-Script-Complex-Oblique (hrscco.gsf) ; -/Hershey-Script-Simplex (hrscs.pfa) ; -/Hershey-Script-Simplex-Bold (hrscsb.gsf) ; -/Hershey-Script-Simplex-Oblique (hrscso.gsf) ; -/Hershey-Symbol (hrsyr.gsf) ; -/NimbusRomanNo9L-Regular (n021003l.gsf) ; -/NimbusSansL-Regular (n019003l.gsf) ; -/Palatino-Bold (pplb.gsf) ; -/Palatino-BoldItalic (pplbi.gsf) ; -/Palatino-Italic (pplri.gsf) ; -/Palatino-Roman (pplr.gsf) ; -/Shareware-Cyrillic-Italic (fcyri.gsf) ; -/Shareware-Cyrillic-Regular (fcyr.gsf) ; -/URWAntiquaT-RegularCondensed (u003043t.gsf) ; -/URWGroteskT-Bold (u004006t.gsf) ; -/Utopia-Bold (putb.pfa) ; -/Utopia-BoldItalic (putbi.pfa) ; -/Utopia-Italic (putri.pfa) ; -/Utopia-Regular (putr.pfa) ; -/ZapfChancery (zcr.gsf) ; -/ZapfChancery-Bold (zcb.gsf) ; -/ZapfChancery-Oblique (zcro.gsf) ; -/ZapfDingbats (pzdr.gsf) ; - -% Font aliases - -/Charter-Roman /CharterBT-Roman ; -/Charter-Italic /CharterBT-Italic ; -/Charter-Bold /CharterBT-Bold ; -/Charter-BoldItalic /CharterBT-BoldItalic ; -/Courier-BoldItalic /Courier-BoldOblique ; -/Courier-Italic /Courier-Oblique ; -/Cyrillic /Shareware-Cyrillic-Regular ; -/Cyrillic-Italic /Shareware-Cyrillic-Italic ; -/Cyrillic-Regular /Shareware-Cyrillic-Regular ; -/Helvetica-Narrow-Bold /Helvetica-Narrow ; -/ZapfChancery-MediumItalic /ZapfChancery-Oblique ; diff --git a/Master/tlpkg/tlgs/lib/Fontmap.VMS b/Master/tlpkg/tlgs/lib/Fontmap.VMS deleted file mode 100644 index e58ce48c61d..00000000000 --- a/Master/tlpkg/tlgs/lib/Fontmap.VMS +++ /dev/null @@ -1,424 +0,0 @@ -% fontmap.vms - Ghostscript fontmap for VAX/VMS systems with DECwindows/Motif.
-%
-% Mathog, 14-SEP-2000. Modified slightly from that provided by 6.01.
-% Changed to use Courier font from Decwindows instead of Ghostscript
-% The hershey fonts are listed, but they are not constructed during a regular
-% build of the package.
-%
-% **************************
-%Uses all the XDPS Outline fonts (Type 1 fonts) provided with Motif.
-%
-%XDPS on VAX/VMS does not have Bookman, Palatino and ZapfChancery fonts, so
-%we still have to use the Ghostscript fonts for those. Helvetica-Narrow is also
-%missing. But then you get the LubalinGraph and Souvenir fonts which are just
-%beautiful!
-
-/AvantGarde-Book
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]AVANTGARDE-BOOK.XDPS$OUTLINE) ;
-/AvantGarde-BookOblique
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]AVANTGARDE-BOOKOBLIQUE.XDPS$OUTLINE) ;
-/AvantGarde-Demi
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]AVANTGARDE-DEMI.XDPS$OUTLINE) ;
-/AvantGarde-DemiOblique
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]AVANTGARDE-DEMIOBLIQUE.XDPS$OUTLINE) ;
-/Courier-Bold
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]COURIER-BOLD.XDPS$OUTLINE) ;
-/Courier-BoldOblique
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]COURIER-BOLDOBLIQUE.XDPS$OUTLINE) ;
-/Courier-Oblique
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]COURIER-OBLIQUE.XDPS$OUTLINE) ;
-/Courier
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]COURIER.XDPS$OUTLINE) ;
-/Helvetica-Bold
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]HELVETICA-BOLD.XDPS$OUTLINE) ;
-/Helvetica-BoldOblique
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]HELVETICA-BOLDOBLIQUE.XDPS$OUTLINE) ;
-/Helvetica-Oblique
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]HELVETICA-OBLIQUE.XDPS$OUTLINE) ;
-/Helvetica
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]HELVETICA.XDPS$OUTLINE) ;
-/LubalinGraph-Book
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]LUBALINGRAPH-BOOK.XDPS$OUTLINE) ;
-/LubalinGraph-BookOblique
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]LUBALINGRAPH-BOOKOBLIQUE.XDPS$OUTLINE) ;
-/LubalinGraph-Demi
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]LUBALINGRAPH-DEMI.XDPS$OUTLINE) ;
-/LubalinGraph-DemiOblique
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]LUBALINGRAPH-DEMIOBLIQUE.XDPS$OUTLINE) ;
-/NewCenturySchlbk-Roman
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]NEWCENTURYSCHLBK-ROMAN.XDPS$OUTLINE) ;
-/NewCenturySchlbk-Italic
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]NEWCENTURYSCHLBK-ITALIC.XDPS$OUTLINE) ;
-/NewCenturySchlbk-Bold
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]NEWCENTURYSCHLBK-BOLD.XDPS$OUTLINE) ;
-/NewCenturySchlbk-BoldItalic
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]NEWCENTURYSCHLBK-BOLDITALIC.XDPS$OUTLINE) ;
-/Souvenir-Light
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]SOUVENIR-LIGHT.XDPS$OUTLINE) ;
-/Souvenir-LightItalic
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]SOUVENIR-LIGHTITALIC.XDPS$OUTLINE) ;
-/Souvenir-Demi
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]SOUVENIR-DEMI.XDPS$OUTLINE) ;
-/Souvenir-DemiItalic
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]SOUVENIR-DEMIITALIC.XDPS$OUTLINE) ;
-%If you want the Apple symbol (SIC!) then remove the comment (%)
-%in front of character 240 in the following file (he he he)
-/Symbol
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]SYMBOL.XDPS$OUTLINE) ;
-/Times-Roman
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]TIMES-ROMAN.XDPS$OUTLINE) ;
-/Times-Italic
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]TIMES-ITALIC.XDPS$OUTLINE) ;
-/Times-Bold
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]TIMES-BOLD.XDPS$OUTLINE) ;
-/Times-BoldItalic
- (SYS$COMMON:[SYSFONT.XDPS.OUTLINE]TIMES-BOLDITALIC.XDPS$OUTLINE) ;
-
-%
-%
-% Fonts contributed by:
-% URW++ Design and Development Incorporated
-% Poppenbuetteler Bogen 29A
-% D-22399 Hamburg
-% Germany
-% tel. +49 (40) 60 60 50
-% fax +49 (40) 60 60 51 11
-% http://www.urwpp.de
-% for distribution under the GNU License and Aladdin Free Public License.
-% See the notice at the head of this Fontmap file for licensing terms.
-% Each of these fonts is individually covered by the license:
-% for licensing purposes, they are not "part of" any larger entity.
-% The following notice applies to these fonts:
-%
-% Copyright URW Software, Copyright 1994 by URW.
-%
-
-% Actual fonts
-
-/URWBookmanL-DemiBold (b018015l.pfb) ;
-/URWBookmanL-DemiBoldItal (b018035l.pfb) ;
-/URWBookmanL-Ligh (b018012l.pfb) ;
-/URWBookmanL-LighItal (b018032l.pfb) ;
-
-/NimbusMonL-Regu (n022003l.pfb) ;
-/NimbusMonL-ReguObli (n022023l.pfb) ;
-/NimbusMonL-Bold (n022004l.pfb) ;
-/NimbusMonL-BoldObli (n022024l.pfb) ;
-
-/URWGothicL-Book (a010013l.pfb) ;
-/URWGothicL-BookObli (a010033l.pfb) ;
-/URWGothicL-Demi (a010015l.pfb) ;
-/URWGothicL-DemiObli (a010035l.pfb) ;
-
-/NimbusSanL-Regu (n019003l.pfb) ;
-/NimbusSanL-ReguItal (n019023l.pfb) ;
-/NimbusSanL-Bold (n019004l.pfb) ;
-/NimbusSanL-BoldItal (n019024l.pfb) ;
-
-/NimbusSanL-ReguCond (n019043l.pfb) ;
-/NimbusSanL-ReguCondItal (n019063l.pfb) ;
-/NimbusSanL-BoldCond (n019044l.pfb) ;
-/NimbusSanL-BoldCondItal (n019064l.pfb) ;
-
-/URWPalladioL-Roma (p052003l.pfb) ;
-/URWPalladioL-Ital (p052023l.pfb) ;
-/URWPalladioL-Bold (p052004l.pfb) ;
-/URWPalladioL-BoldItal (p052024l.pfb) ;
-
-/CenturySchL-Roma (c059013l.pfb) ;
-/CenturySchL-Ital (c059033l.pfb) ;
-/CenturySchL-Bold (c059016l.pfb) ;
-/CenturySchL-BoldItal (c059036l.pfb) ;
-
-/NimbusRomNo9L-Regu (n021003l.pfb) ;
-/NimbusRomNo9L-ReguItal (n021023l.pfb) ;
-/NimbusRomNo9L-Medi (n021004l.pfb) ;
-/NimbusRomNo9L-MediItal (n021024l.pfb) ;
-
-/StandardSymL (s050000l.pfb) ;
-
-/URWChanceryL-MediItal (z003034l.pfb) ;
-
-/Dingbats (d050000l.pfb) ;
-
-
-% Aliases
-
-/Bookman-Demi /URWBookmanL-DemiBold ;
-/Bookman-DemiItalic /URWBookmanL-DemiBoldItal ;
-/Bookman-Light /URWBookmanL-Ligh ;
-/Bookman-LightItalic /URWBookmanL-LighItal ;
-
-%/Courier /NimbusMonL-Regu ;
-%/Courier-Oblique /NimbusMonL-ReguObli ;
-%/Courier-Bold /NimbusMonL-Bold ;
-%/Courier-BoldOblique /NimbusMonL-BoldObli ;
-
-%/AvantGarde-Book /URWGothicL-Book ;
-%/AvantGarde-BookOblique /URWGothicL-BookObli ;
-%/AvantGarde-Demi /URWGothicL-Demi ;
-%/AvantGarde-DemiOblique /URWGothicL-DemiObli ;
-
-%/Helvetica /NimbusSanL-Regu ;
-%/Helvetica-Oblique /NimbusSanL-ReguItal ;
-%/Helvetica-Bold /NimbusSanL-Bold ;
-%/Helvetica-BoldOblique /NimbusSanL-BoldItal ;
-
-/Helvetica-Narrow /NimbusSanL-ReguCond ;
-/Helvetica-Narrow-Oblique /NimbusSanL-ReguCondItal ;
-/Helvetica-Narrow-Bold /NimbusSanL-BoldCond ;
-/Helvetica-Narrow-BoldOblique /NimbusSanL-BoldCondItal ;
-
-/Palatino-Roman /URWPalladioL-Roma ;
-/Palatino-Italic /URWPalladioL-Ital ;
-/Palatino-Bold /URWPalladioL-Bold ;
-/Palatino-BoldItalic /URWPalladioL-BoldItal ;
-
-%/NewCenturySchlbk-Roman /CenturySchL-Roma ;
-%/NewCenturySchlbk-Italic /CenturySchL-Ital ;
-%/NewCenturySchlbk-Bold /CenturySchL-Bold ;
-%/NewCenturySchlbk-BoldItalic /CenturySchL-BoldItal ;
-
-%/Times-Roman /NimbusRomNo9L-Regu ;
-%/Times-Italic /NimbusRomNo9L-ReguItal ;
-%/Times-Bold /NimbusRomNo9L-Medi ;
-%/Times-BoldItalic /NimbusRomNo9L-MediItal ;
-
-%/Symbol /StandardSymL ;
-
-/ZapfChancery-MediumItalic /URWChanceryL-MediItal ;
-
-/ZapfDingbats /Dingbats ;
-
-
-%
-%
-% Type 1 fonts contributed to the X11R5 distribution.
-%
-
-% The following notice accompanied the Charter fonts.
-%
-% (c) Copyright 1989-1992, Bitstream Inc., Cambridge, MA.
-%
-% You are hereby granted permission under all Bitstream propriety rights
-% to use, copy, modify, sublicense, sell, and redistribute the 4 Bitstream
-% Charter (r) Type 1 outline fonts and the 4 Courier Type 1 outline fonts
-% for any purpose and without restriction; provided, that this notice is
-% left intact on all copies of such fonts and that Bitstream's trademark
-% is acknowledged as shown below on all unmodified copies of the 4 Charter
-% Type 1 fonts.
-%
-% BITSTREAM CHARTER is a registered trademark of Bitstream Inc.
-/CharterBT-Roman (bchr.pfa) ;
-/CharterBT-Italic (bchri.pfa) ;
-/CharterBT-Bold (bchb.pfa) ;
-/CharterBT-BoldItalic (bchbi.pfa) ;
-%Charter to CharterBT aliasing
-/Charter-Roman /CharterBT-Roman ;
-/Charter-Italic /CharterBT-Italic ;
-/Charter-Bold /CharterBT-Bold ;
-/Charter-BoldItalic /CharterBT-BoldItalic ;
-
-% IBM Courier - Copyright (c) IBM Corporation 1990, 1991
-%/Courier (ncrr.pfa) ;
-%/Courier-Italic (ncrri.pfa) ;
-%/Courier-Bold (ncrb.pfa) ;
-%/Courier-BoldItalic (ncrbi.pfa) ;
-%Oblique to Italic aliasing
-%/Courier-Oblique /Courier-Italic ;
-%/Courier-BoldOblique /Courier-BoldItalic ;
-/Courier-Italic /Courier-Oblique ;
-/Courier-BoldItalic /Courier-BoldOblique ;
-
-% The following notice accompanied the Utopia font:
-%
-% Permission to use, reproduce, display and distribute the listed
-% typefaces is hereby granted, provided that the Adobe Copyright notice
-% appears in all whole and partial copies of the software and that the
-% following trademark symbol and attribution appear in all unmodified
-% copies of the software:
-%
-% Copyright (c) 1989 Adobe Systems Incorporated
-% Utopia (R)
-% Utopia is a registered trademark of Adobe Systems Incorporated
-%
-% The Adobe typefaces (Type 1 font program, bitmaps and Adobe Font
-% Metric files) donated are:
-%
-% Utopia Regular
-% Utopia Italic
-% Utopia Bold
-% Utopia Bold Italic
-
-/Utopia-Regular (putr.gsf) ;
-/Utopia-Italic (putri.gsf) ;
-/Utopia-Bold (putb.gsf) ;
-/Utopia-BoldItalic (putbi.gsf) ;
-
-%
-%
-% Fonts contributed by URW GmbH for distribution under the GNU License.
-% The following notice accompanied these fonts:
-%
-% U004006T URW Grotesk 2031 Bold PostScript Type 1 Font Program
-% U003043T URW Antiqua 2051 Regular Condensed PostScript Type 1 Font Program
-%
-% Copyright (c) 1992 URW GmbH, Hamburg, Germany
-%
-% This program is free software; you can redistribute it and/or modify
-% it under the terms of the GNU General Public License as published by
-% the Free Software Foundation; either version 2 of the License, or
-% (at your option) later version.
-%
-% This program is distributed in the hope that it will be useful,
-% but WITHOUT ANY WARRANTY; wihtout even the implied warranty of
-% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-% See the GNU General Public License for more details.
-%
-% You should have received a copy of the GNU General Public License
-% along with this program; if not, write to the Free Software
-% Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111 U.S.A.
-%
-% Address:
-% URW GmbH
-% PC Support
-% Harksheider Strasse 102
-% 2000 Hamburg 65
-% Germany
-% Phone: +49 40 60 60 50 (Reception)
-% Phone: +49 40 60 60 52 30 (PC Support)
-% Fax : +49 40 60 60 52 52
-%
-
-/URWAntiquaT-RegularCondensed (u003043t.gsf) ;
-/URWGroteskT-Bold (u004006t.gsf) ;
-
-%
-%
-% Shareware Kana fonts. These are subject to the following notice:
-%
-% These copyrighted fonts were developed by Kevin Hartig. Permission is
-% granted to freely distribute them in entirety along with this statement.
-% This is shareware. If you decide to use these fonts please contribute
-% $10 US to help support further freeware and shareware software development.
-% Questions and comments may be sent to:
-%
-% hartig@fsl.noaa.gov
-% khartig@nyx.cs.du.edu
-%
-% Kevin Hartig
-% 1126 Collyer Street
-% Longmont, CO 80501 USA
-%
-% copyright 1993.
-
-% Hiragana and Katakana fonts. The character names are inappropriate,
-% and the encoding is probably not related to any known standard.
-
-/Calligraphic-Hiragana (fhirw.gsf) ;
-/Calligraphic-Katakana (fkarw.gsf) ;
-
-%
-%
-% Public-domain fonts. These have no copyright, and are of unknown quality.
-
-% Cyrillic fonts. The character names are inappropriate,
-% and the encoding is probably not related to any known standard.
-
-/Shareware-Cyrillic-Regular (fcyr.gsf) ;
-/Shareware-Cyrillic-Italic (fcyri.gsf) ;
-
-% Aliases
-/Cyrillic /Cyrillic-Regular ;
-/Cyrillic-Regular /Shareware-Cyrillic-Regular ;
-/Cyrillic-Italic /Shareware-Cyrillic-Italic ;
-
-%
-%
-% Fonts converted from Hershey outlines. These are constructed and
-% maintained manually. These are also in the public domain.
-%
-% The suggested UniqueID's and filenames are constructed differently for
-% these than for the ones above, because of the strange way that the Hershey
-% fonts were constructed. The scheme for these looks like:
-%
-% 42TTXY0
-%
-% TT = typeface, X = ``class'', Y = variation
-%
-% The typeface names and numbers are listed in fonts.mak.
-%
-% class:
-% 0 = normal = r
-% 1 = simplex = s
-% 2 = complex = c
-% 3 = triplex = t
-% 4 = duplex = d
-%
-% variation:
-% 0 = normal (omitted)
-% 1 = oblique = o
-% 2 = italic = i
-% 3 = bold = b
-% 4 = bold oblique = bo
-% 5 = bold italic = bi
-%
-
-% Fonts created by Thomas Wolff <wolff@inf.fu-berlin.de>, by adding
-% accents, accented characters, and various other non-alphabetics
-% to the original Hershey fonts. These are "freeware", not to be sold.
-
-/Hershey-Gothic-English (hrger.pfa) ; % 5066533
-/Hershey-Gothic-German (hrgrr.pfa) ;
-/Hershey-Gothic-Italian (hritr.pfa) ;
-
-/Hershey-Plain-Duplex (hrpld.pfa) ;
-/Hershey-Plain-Duplex-Italic (hrpldi.pfa) ;
-/Hershey-Plain-Triplex (hrplt.pfa) ;
-/Hershey-Plain-Triplex-Italic (hrplti.pfa) ;
-
-/Hershey-Script-Complex (hrscc.pfa) ;
-/Hershey-Script-Simplex (hrscs.pfa) ; % 5066541
-
-% Fonts created algorithmically from the above.
-
-/Hershey-Gothic-English-Bold (hrgerb.gsf) ; % 5066542
-/Hershey-Gothic-English-Oblique (hrgero.gsf) ;
-/Hershey-Gothic-English-SemiBold (hrgerd.gsf) ;
-/Hershey-Gothic-German-Bold (hrgrrb.gsf) ;
-/Hershey-Gothic-German-Oblique (hrgrro.gsf) ;
-/Hershey-Gothic-Italian-Bold (hritrb.gsf) ;
-/Hershey-Gothic-Italian-Oblique (hritro.gsf) ;
-
-/Hershey-Plain-Duplex-Bold (hrpldb.gsf) ;
-/Hershey-Plain-Duplex-Bold-Italic (hrpldbi.gsf) ;
-/Hershey-Plain-Triplex-Bold (hrpltb.gsf) ;
-/Hershey-Plain-Triplex-Bold-Italic (hrpltbi.gsf) ;
-
-/Hershey-Script-Complex-Bold (hrsccb.gsf) ;
-/Hershey-Script-Complex-Oblique (hrscco.gsf) ;
-/Hershey-Script-Simplex-Bold (hrscsb.gsf) ;
-/Hershey-Script-Simplex-Oblique (hrscso.gsf) ; % 5066556
-
-% Fonts consisting only of characters from the original Hershey
-% distribution. These are Type 3 fonts.
-
-/Hershey-Greek-Complex (hrgkc.gsf) ; % 5066557
-/Hershey-Greek-Simplex (hrgks.gsf) ;
-
-/Hershey-Plain (hrplr.gsf) ;
-/Hershey-Plain-Simplex (hrpls.gsf) ; % 5066560
-
-% Fonts created algorithmically from the above.
-
-/Hershey-Plain-Bold (hrplrb.gsf) ; % 5066561
-/Hershey-Plain-Bold-Oblique (hrplrbo.gsf) ;
-/Hershey-Plain-Oblique (hrplro.gsf) ;
-/Hershey-Plain-Simplex-Bold (hrplsb.gsf) ;
-/Hershey-Plain-Simplex-Bold-Oblique (hrplsbo.gsf) ;
-/Hershey-Plain-Simplex-Oblique (hrplso.gsf) ; % 5066566
-
-% This font, and only this font among the Hershey fonts, uses
-% the SymbolEncoding.
-
-/Hershey-Symbol (hrsyr.gsf) ; % 5066567
diff --git a/Master/tlpkg/tlgs/lib/Info-macos.plist b/Master/tlpkg/tlgs/lib/Info-macos.plist deleted file mode 100644 index 9ece6edc4fa..00000000000 --- a/Master/tlpkg/tlgs/lib/Info-macos.plist +++ /dev/null @@ -1,14 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!DOCTYPE plist SYSTEM "file://localhost/System/Library/DTDs/PropertyList.dtd"> -<plist version="0.9"> -<dict> - <key>CFBundleIdentifier</key> - <string>com.ghostscript.Ghostscript</string> - <key>CFBundleName</key> - <string>Ghostscript</string> - <key>CFBundleShortVersionString</key> - <string>703</string> - <key>NSExecutable</key> - <string>Ghostscript</string> -</dict> -</plist> diff --git a/Master/tlpkg/tlgs/lib/PDFA_def.ps b/Master/tlpkg/tlgs/lib/PDFA_def.ps deleted file mode 100644 index a0ba5f0e4d8..00000000000 --- a/Master/tlpkg/tlgs/lib/PDFA_def.ps +++ /dev/null @@ -1,43 +0,0 @@ -%!
-% $Id: PDFA_def.ps 8284 2007-10-10 17:40:38Z giles $
-% This is a sample prefix file for creating a PDF/A document.
-% Feel free to modify entries marked with "Customize".
-
-% This assumes an ICC profile to reside in the file (ISO Coated sb.icc),
-% unless the user modifies the corresponding line below.
-
-
-systemdict /ProcessColorModel known {
- systemdict /ProcessColorModel get dup /DeviceGray ne exch /DeviceCMYK ne and
-} {
- true
-} ifelse
-{ (ERROR: ProcessColorModel must be /DeviceGray or DeviceCMYK.)=
- /ProcessColorModel cvx /rangecheck signalerror
-} if
-
-
-% Define entries to the document Info dictionary :
-
-/ICCProfile (ISO Coated sb.icc) % Customize.
-def
-
-[ /Title (Title) % Customize.
- /DOCINFO pdfmark
-
-% Define an ICC profile :
-
-[/_objdef {icc_PDFA} /type /stream /OBJ pdfmark
-[{icc_PDFA} <</N systemdict /ProcessColorModel get /DeviceGray eq {1} {4} ifelse >> /PUT pdfmark
-[{icc_PDFA} ICCProfile (r) file /PUT pdfmark
-
-% Define the output intent dictionary :
-
-[/_objdef {OutputIntent_PDFA} /type /dict /OBJ pdfmark
-[{OutputIntent_PDFA} <<
- /Type /OutputIntent % Must be so (the standard requires).
- /S /GTS_PDFA1 % Must be so (the standard requires).
- /DestOutputProfile {icc_PDFA} % Must be so (see above).
- /OutputConditionIdentifier (CGATS TR001) % Customize
->> /PUT pdfmark
-[{Catalog} <</OutputIntents [ {OutputIntent_PDFA} ]>> /PUT pdfmark
diff --git a/Master/tlpkg/tlgs/lib/PDFX_def.ps b/Master/tlpkg/tlgs/lib/PDFX_def.ps deleted file mode 100644 index 615b66c9732..00000000000 --- a/Master/tlpkg/tlgs/lib/PDFX_def.ps +++ /dev/null @@ -1,51 +0,0 @@ -%!
-% $Id: PDFX_def.ps 8284 2007-10-10 17:40:38Z giles $
-% This is a sample prefix file for creating a PDF/X-3 document.
-% Feel free to modify entries marked with "Customize".
-
-% This assumes an ICC profile to reside in the file (ISO Coated sb.icc),
-% unless the user modifies the corresponding line below.
-
-
-systemdict /ProcessColorModel known {
- systemdict /ProcessColorModel get dup /DeviceGray ne exch /DeviceCMYK ne and
-} {
- true
-} ifelse
-{ (ERROR: ProcessColorModel must be /DeviceGray or DeviceCMYK.)=
- /ProcessColorModel cvx /rangecheck signalerror
-} if
-
-
-% Define entries to the document Info dictionary :
-
-/ICCProfile (ISO Coated sb.icc) def % Customize or remove.
-
-[ /GTS_PDFXVersion (PDF/X-3:2002) % Must be so (the standard requires).
- /Title (Title) % Customize.
- /Trapped /False % Must be so (Ghostscript doesn't provide other).
- /DOCINFO pdfmark
-
-% Define an ICC profile :
-
-currentdict /ICCProfile known {
- [/_objdef {icc_PDFX} /type /stream /OBJ pdfmark
- [{icc_PDFX} <</N systemdict /ProcessColorModel get /DeviceGray eq {1} {4} ifelse >> /PUT pdfmark
- [{icc_PDFX} ICCProfile (r) file /PUT pdfmark
-} if
-
-% Define the output intent dictionary :
-
-[/_objdef {OutputIntent_PDFX} /type /dict /OBJ pdfmark
-[{OutputIntent_PDFX} <<
- /Type /OutputIntent % Must be so (the standard requires).
- /S /GTS_PDFX % Must be so (the standard requires).
- /OutputCondition (Commercial and specialty printing) % Customize
- /Info (none) % Customize
- /OutputConditionIdentifier (CGATS TR001) % Customize
- /RegistryName (http://www.color.org) % Must be so (the standard requires).
- currentdict /ICCProfile known {
- /DestOutputProfile {icc_PDFX} % Must be so (see above).
- } if
->> /PUT pdfmark
-[{Catalog} <</OutputIntents [ {OutputIntent_PDFX} ]>> /PUT pdfmark
diff --git a/Master/tlpkg/tlgs/lib/acctest.ps b/Master/tlpkg/tlgs/lib/acctest.ps deleted file mode 100644 index de4c10af316..00000000000 --- a/Master/tlpkg/tlgs/lib/acctest.ps +++ /dev/null @@ -1,100 +0,0 @@ -%!
-% Check that operators do their access tests correctly.
-% $Id: acctest.ps 6300 2005-12-28 19:56:24Z giles $
-
-% proc dotest => .
-/dotest
- {
- dup
- mark
- exch
- stopped not % False if error, true if no error.
- { (Allowed access: ) print cleartomark == }
- if
- clear
- }
-def
-
-0 0 moveto % So the show commands don't bomb because of nocurrentpoint.
-
-{ [1 2] executeonly aload } dotest
-{ (string) executeonly (seek) anchorsearch } dotest
-{ (string) (seek) executeonly anchorsearch } dotest
-{ 100 101 (string) noaccess ashow} dotest
-{ 100 1 array readonly astore } dotest
-{ 100 101 102 103 104 (string) noaccess awidthshow } dotest
-{ 1 dict noacess begin } dotest
-{ 1 array executeonly 1 array copy } dotest
-{ 1 array 1 array readonly copy } dotest
-{ 1 dict noaccess 1 dict copy } dotest
-{ 1 dict 1 dict readonly copy } dotest
-{ 1 string executeonly 1 string copy } dotest
-{ 1 string 1 string readonly copy } dotest
-{ (100) executeonly cvi } dotest
-{ (string) executeonly cvn } dotest
-{ (100.001) executeonly cvr } dotest
-{ 1 10 1 string readonly cvrs } dotest
-{ true 5 string readonly cvs } dotest
-{ 1 dict readonly begin /foo true def } dotest
-{ 10 array readonly dictstack } dotest
-{ 1 string executeonly 1 string eq } dotest
-{ 1 string 1 string executeonly eq } dotest
-{ 10 array readonly execstack } dotest
-{ 1 string noaccess executeonly } dotest
-{ 1 array noaccess executeonly } dotest
-{ 1 array executeonly { pop } forall } dotest
-{ 1 dict noaccess { pop pop } forall } dotest
-{ 1 string executeonly { pop } forall } dotest
-{ (string1) executeonly (string2) ge } dotest
-{ (string1) (string2) executeonly ge } dotest
-{ 1 array executeonly 0 get } dotest
-{ 1 dict noaccess /key get } dotest
-{ 1 string executeonly 0 get } dotest
-{ 1 array executeonly 0 1 getinterval } dotest
-{ 1 string executeonly 0 1 getinterval } dotest
-{ (string1) executeonly (string2) gt } dotest
-{ (string1) (string2) executeonly gt } dotest
-{ 1 dict noaccess /key known } dotest
-{ {} (string) executeonly kshow } dotest
-{ (string1) executeonly (string2) le } dotest
-{ (string1) (string2) executeonly le } dotest
-{ 1 array executeonly length } dotest
-{ 1 dict noaccess length } dotest
-{ 1 string executeonly length } dotest
-%%{ /foo 1 dict def foo begin /bar foo def bar noaccess pop /key load } dotest
-{ (string1) executeonly (string2) lt } dotest
-{ (string1) (string2) executeonly lt } dotest
-{ 1 dict noaccess maxlength } dotest
-{ 1 string executeonly 1 string ne } dotest
-{ 1 string 1 string executeonly ne } dotest
-%{ newpath 0 0 moveto (a) false charpath
-% {} {} {} {} pathforall closepath } dotest
-{ 1 array executeonly 0 put } dotest
-{ 1 dict noaccess /key put } dotest
-{ 1 string executeonly 0 put } dotest
-{ 1 array executeonly 0 1 putinterval } dotest
-{ 1 string executeonly 0 1 putinterval } dotest
-{ (access.ps) (r) file executeonly read } dotest
-{ (access.ps) (r) file executeonly 10 string readhexstring } dotest
-{ (access.ps) (r) file 10 string readonly readhexstring } dotest
-{ (access.ps) (r) file executeonly 100 string readline } dotest
-{ (access.ps) (r) file 100 string readonly readline } dotest
-{ (access.ps) (r) file executeonly 10 string readstring } dotest
-{ (access.ps) (r) file 10 string readonly readstring } dotest
-% run does not check for no read access?
-{ (string) executeonly (seek) search } dotest
-{ (string) (seek) executeonly search } dotest
-{ (string) executeonly show }
-%% some test for store.
-{ (string) executeonly stringwidth } dotest
-{ (access.ps) (r) file executeonly token } dotest
-{ (10) executeonly token } dotest
-{ /foo 1 dict def foo begin /bar foo def bar noaccess pop /key where } dotest
-{ 100 101 102 (string) noaccess widthshow } dotest
-{ (/tmp/_.ps) noaccess (w) file closefile } dotest
-{ (/tmp/_.ps) (w) noaccess file closefile } dotest
-{ (/tmp/_.ps) (w) file executeonly 100 write } dotest
-{ (/tmp/_.ps) (w) file executeonly 10 string writehexstring } dotest
-{ (/tmp/_.ps) (w) file 10 string executeonly writehexstring } dotest
-{ (/tmp/_.ps) (w) file executeonly 10 string writestring } dotest
-{ (/tmp/_.ps) (w) file 10 string executeonly writestring } dotest
diff --git a/Master/tlpkg/tlgs/lib/addxchar.ps b/Master/tlpkg/tlgs/lib/addxchar.ps deleted file mode 100644 index ddfc7e334a5..00000000000 --- a/Master/tlpkg/tlgs/lib/addxchar.ps +++ /dev/null @@ -1,357 +0,0 @@ -% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: addxchar.ps 6300 2005-12-28 19:56:24Z giles $
-% Add the Central European and other Adobe extended Latin characters to a
-% Type 1 font.
-% Requires -dWRITESYSTEMDICT to disable access protection.
-
-(type1ops.ps) runlibfile
-
-% ---------------- Utilities ---------------- %
-
-/addce_dict 50 dict def
-addce_dict begin
-
-% Define the added copyright notice.
-/addednotice (. Portions Copyright (C) 1999 Aladdin Enterprises.) def
-
-% Open a font for modification by removing the FID and changing the
-% FontName. Removing UniqueID and XUID is not necessary, since we
-% will only be adding characters.
-/openfont { % <name> <font> openfont <name> <font'>
- dup length dict copy
- dup /FID undef
- dup /FontName 3 index put
-} def
-
-% Do the equivalent of false charpath for a glyph.
-% This should really be an operator!
-/glyphpath { % <glyph> glyphpath -
- currentfont /Encoding get 0 3 -1 roll put
- <00> false charpath
-} def
-
-% Do the equivalent of charpath + pathbbox for a glyph.
-/glyphbbox { % <glyph> glyphbbox <llx> <lly> <urx> <ury>
- % We cache this value, because it's expensive to compute.
- BBoxes 1 index .knownget {
- exch pop
- } {
- gsave newpath 0 0 moveto dup glyphpath [pathbbox] grestore
- BBoxes 3 -1 roll 2 index put
- } ifelse aload pop
-} def
-
-% Get the side bearing and width for a glyph.
-/glyphsbw { % <glyph> glyphsbw <lsbx> <wx>
- % We cache this value, because it's expensive to compute.
- SBW 1 index .knownget {
- exch pop
- } {
- dup glyphcs { dup /hsbw eq { pop exit } if } forall
- 2 array astore
- SBW 3 -1 roll 2 index put
- } ifelse aload pop
-} def
-
-% Get the CharString for a glyph, as an array.
-/glyphcs { % <glyph> glyphcs <array>
- CharStrings exch get
- 4330 exch dup length string .type1decrypt exch pop
- dup length lenIV sub lenIV exch getinterval
- 0 () /SubFileDecode filter [ exch charstack_read ]
-} def
-
-% Find an occurrence of a value in an array.
-/asearch { % <array> <value> asearch <index> true
- % <array> <value> asearch false
- false 0 4 2 roll exch {
- % Stack: false index value element
- 2 copy eq { pop pop exch not exch dup exit } if
- exch 1 add exch
- } forall pop pop
-} def
-
-% Convert an array back to a CharString.
-/csdef { % <glyph> <array> csdef -
- charproc_string
- 4330 exch dup .type1encrypt exch pop readonly
- CharStrings 3 1 roll put
-} def
-
-% Split an accented character name.
-/splitaccented { % <Baccent> splitaccented <Baccent> <B> <accent>
- dup =string cvs
- dup 0 1 getinterval cvn
- exch dup length 1 sub 1 exch getinterval cvn
-} def
-
-% Begin the definition of a 'seac' character.
-% Defines accent, base, abox, bbox.
-% The initial dx lines up the origins of the base and the accent.
-/beginseac { % <bchar> <achar> beginseac
- % -mark- <lsbx> <wx> /hsbw <asb> <dx>
- /accent exch def /base exch def
- /abox [accent glyphbbox] def
- /bbox [base glyphbbox] def
- [ base glyphsbw /hsbw accent glyphsbw pop
- dup 4 index sub
-} def
-
-% Center the accent over the base of a 'seac' character.
-/centeraccent { % <dx> centeraccent <adx>
- bbox 2 get bbox 0 get add 2 div
- abox 2 get abox 0 get add 2 div
- sub add
-} def
-
-% Finish the definition of a 'seac' character.
-/finishseac { % <charname> -mark- ... <adx> <ady> finishseac -
- exch cvi exch cvi
- charindex base get charindex accent get /seac ] csdef
-} def
-
-% ---------------- Main program ---------------- %
-
-% Define accented characters that can be made with seac,
-% with the accent centered over the character.
-/seacchars [
- /Abreve /Amacron
- /Cacute /Ccaron /Dcaron
- /Ecaron /Edotaccent /Emacron
- /Gbreve
- /Idotaccent /Imacron
- /Lacute
- /Nacute /Ncaron
- /Ohungarumlaut /Omacron
- /Racute /Rcaron
- /Sacute /Scedilla
- /Tcaron
- /Uhungarumlaut /Umacron /Uogonek /Uring
- /Zacute /Zdotaccent
- /abreve /amacron
- /cacute /ccaron
- /ecaron /edotaccent /emacron
- /gbreve
- /lacute
- /nacute /ncaron
- /ohungarumlaut /omacron
- /racute /rcaron
- /sacute /scedilla
- /uhungarumlaut /umacron /uring
- /zacute /zdotaccent
-] def
-
-% Define seac characters where the accent lines up with the right
-% edge of the character.
-/seacrightchars [
- /Aogonek /Eogonek /Iogonek /aogonek /eogonek /iogonek /uogonek
-] def
-
-% Define seac characters where the caron becomes an appended quoteright.
-/seaccaronchars [
- /dcaron /lcaron /tcaron
-] def
-
-% Define seac characters using commaaccent.
-/seaccommachars [
- /Gcommaaccent /Kcommaaccent /Lcommaaccent /Ncommaaccent /Rcommaaccent
- /Scommaaccent /Tcommaaccent
- /gcommaaccent /kcommaaccent /lcommaaccent /ncommaaccent /rcommaaccent
- /scommaaccent /tcommaaccent
-] def
-
-% Define the characters copied from the Symbol font.
-/symbolchars [
- /Delta /greaterequal /lessequal /lozenge /notequal /partialdiff
- /summation
-] def
-
-% Define the procedures for editing the commaaccent character.
-% Delete all the hints, since it's too hard to adjust them.
-/caedit mark
- /rmoveto { exch commatop sub cvi exch }
- /hstem { pop pop pop }
- /vstem 1 index
- /callothersubr {
- dup 3 eq { 4 { pop } repeat /skip true def } if
- }
- /pop { skip { pop /skip false def } if }
-.dicttomark def
-
-/addce { % <name> <font> addce <font'>
- 20 dict begin
- /origfont 1 index def
- openfont
- dup /CharStrings 2 copy get dup length dict copy put
- dup /Encoding 2 copy get dup length array copy put
- dup /FontInfo 2 copy get dup length dict copy put
- definefont /font exch def
- currentdict font end begin begin
- font 1000 scalefont setfont
- /symbolfont /Symbol findfont def
- /BBoxes CharStrings length dict def
- /SBW CharStrings length dict def
-
- /italfactor FontInfo /ItalicAngle .knownget {
- neg dup sin exch cos div
- } {
- 0
- } ifelse def
-
- % Invert the Encoding (needed for seac).
-
- /charindex 256 dict def
- 0 1 255 {
- charindex exch Encoding 1 index get exch put
- } for
-
- % Add the commaaccent character, by moving the comma downward.
-
- /comma glyphbbox /commatop exch def pop pop pop
- /comma glyphcs
- /skip false def
- [ exch { caedit 1 index .knownget { exec } if } forall ]
- /commaaccent exch csdef
-
- % Add the accented characters that can be made with seac.
-
- seacchars {
- splitaccented beginseac
- centeraccent
- % If the accent would collide with the base character,
- % raise it a little.
- abox 1 get bbox 3 get sub dup 0 le {
- % ... but not if the accent is in the low position.
- abox 1 get 0 gt {
- neg 60 add
- % Adjust the X position if italic.
- dup italfactor mul 3 -1 roll add exch
- } {
- pop 0
- } ifelse
- } {
- pop 0
- } ifelse
- finishseac
- } forall
-
- seacrightchars {
- splitaccented beginseac
- bbox 2 get abox 2 get sub add % line up right edges
- 0 finishseac
- } forall
-
- /dcroat /d /hyphen beginseac
- bbox 2 get abox 2 get sub add % line up right edges
- 0 finishseac
-
- /imacron /dotlessi /macron beginseac
- centeraccent
- 0 finishseac
-
- /Lcaron /L /quoteright beginseac
- bbox 2 get abox 2 get sub add % line up right edges
- 0 finishseac
-
- seaccaronchars {
- dup =string cvs 0 1 getinterval cvn /quoteright beginseac
- % Move the quote to the right of the character.
- bbox 2 get abox 0 get sub 50 add add
- % Adjust the character width as well.
- 4 -1 roll abox 2 get abox 0 get sub 50 add add cvi 4 1 roll
- 0 finishseac
- } forall
-
- seaccommachars {
- dup =string cvs 0 1 getinterval cvn /comma beginseac
- centeraccent
- commatop neg
- % Lower the accent if the character extends below
- % the baseline
- bbox 1 get 0 .min add
- finishseac
- } forall
-
- % Add the characters from the Symbol font.
- % We should scale them to match the FontBBox, but we don't.
-
- symbolchars {
- symbolfont /CharStrings get 1 index get
- CharStrings 3 1 roll put
- } forall
-
- % Add the one remaining character.
-
- CharStrings /Dcroat CharStrings /Eth get put
-
- % Recompute the FontBBox, since some of the accented characters
- % may have enlarged it.
-
- /llx 1000 def /lly 1000 def /urx 0 def /ury 0 def
- CharStrings {
- pop glyphbbox
- ury .max /ury exch def urx .max /urx exch def
- lly .min /lly exch def llx .min /llx exch def
- } forall
- /FontBBox llx cvi lly cvi urx ceiling cvi ury ceiling cvi 4 packedarray def
-
- % Restore the Encoding and wrap up.
-
- [/Copyright /Notice] {
- FontInfo 1 index .knownget {
- addednotice concatstrings FontInfo 3 1 roll put
- } {
- pop
- } ifelse
- } forall
- FontName font openfont
- dup /Encoding origfont /Encoding get put
- definefont
-
- end end
-} def
-
-currentdict end readonly pop % addce_dict
-
-/addce { addce_dict begin addce end } def
-
-% ---------------- Integration ---------------- %
-
-% We would like to patch the font loader so that it adds the extended
-% Latin characters automatically. We haven't done this yet.
-
-% ---------------- Test program ---------------- %
-
-/TEST where { pop TEST } { false } ifelse {
- /FONT where { pop } { /FONT /Palatino-Italic def } ifelse
- (unprot.ps) runlibfile
- unprot
- (wrfont.ps) runlibfile
- wrfont_dict begin
- /eexec_encrypt true def
- /binary_CharStrings true def
- end
- save
- FONT findfont
- /Latin-CE exch addce setfont
- (t.ce.pfb) (w) file dup writefont closefile
- restore
- (prfont.ps) runlibfile
- (t.ce.pfb) (r) file .loadfont
- /Latin-CE DoFont
- quit
-} if
diff --git a/Master/tlpkg/tlgs/lib/afmdiff.awk b/Master/tlpkg/tlgs/lib/afmdiff.awk deleted file mode 100755 index e9c237b4bc6..00000000000 --- a/Master/tlpkg/tlgs/lib/afmdiff.awk +++ /dev/null @@ -1,151 +0,0 @@ -#!/usr/bin/awk -f -###===================================================================== -### Read two Adobe Font Metric files, and compute tables of the -### differences in character repertoire, declared widths (WX), and -### bounding boxes. -### -### Usage: -### awk -f afmdiff.awk file1.afm file2.afm -### -### Author: -### Nelson H. F. Beebe -### Center for Scientific Computing -### University of Utah -### Department of Mathematics, 322 INSCC -### 155 S 1400 E RM 233 -### Salt Lake City, UT 84112-0090 -### USA -### Email: beebe@math.utah.edu, beebe@acm.org, beebe@computer.org, -### beebe@ieee.org (Internet) -### WWW URL: http://www.math.utah.edu/~beebe -### Telephone: +1 801 581 5254 -### FAX: +1 801 585 1640, +1 801 581 4148 -### -######################################################################## -######################################################################## -######################################################################## -### ### -### awkdiff.awk: compare two Adobe Font Metric files ### -### ### -### Copyright (C) 2000 Nelson H. F. Beebe ### -### ### -### This program is covered by the GNU General Public License (GPL), ### -### version 2 or later, available as the file COPYING in the program ### -### source distribution, and on the Internet at ### -### ### -### ftp://ftp.gnu.org/gnu/GPL ### -### ### -### http://www.gnu.org/copyleft/gpl.html ### -### ### -### This program is free software; you can redistribute it and/or ### -### modify it under the terms of the GNU General Public License as ### -### published by the Free Software Foundation; either version 2 of ### -### the License, or (at your option) any later version. ### -### ### -### This program is distributed in the hope that it will be useful, ### -### but WITHOUT ANY WARRANTY; without even the implied warranty of ### -### MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ### -### GNU General Public License for more details. ### -### ### -### You should have received a copy of the GNU General Public ### -### License along with this program; if not, write to the Free ### -### Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, ### -### MA 02111-1307 USA ### -### ### -### This program may also be distributed as part of AFPL ### -### Ghostscript, under the terms of the Aladdin Free Public License ### -### (the "License"). ### -### ### -### Every copy of AFPL Ghostscript must include a copy of the ### -### License, normally in a plain ASCII text file named PUBLIC. The ### -### License grants you the right to copy, modify and redistribute ### -### AFPL Ghostscript, but only under certain conditions ### -### described in the License. Among other things, the License ### -### requires that the copyright notice and this notice be preserved ### -### on all copies. ### -### ### -######################################################################## -######################################################################## -######################################################################## -# -# [29-Apr-2000] -#======================================================================= - -/^FontName/ { FontName[++NFontName] = $2 } - - -/^C / { - if (NFontName == 1) - CharName1[$8]++ - if (NFontName == 2) - CharName2[$8]++ - } - - -/^C / { - name = $8 - if (name in WX) - { - if (WX[name] != $5) - WXDIFF[name] = WX[name] - $5 - } - else - WX[name] = $5 - } - - -/^C / { - name = $8 - bx = $13 - $11 - if (name in BX) - { - if (BX[name] != bx) - BXDIFF[name] = BX[name] - bx - } - else - BX[name] = bx - } - - -/^C / { - name = $8 - by = $14 - $12 - if (name in BY) - { - if (BY[name] != by) - BYDIFF[name] = BY[name] - by - } - else - BY[name] = by - } - - -END { - Sortpipe = "sort -f | pr -3 -w80 -l1 -t" - print "Comparison of AFM metrics in files:", ARGV[1], ARGV[2] - print "Font names:", FontName[1], FontName[2] - show_name_diffs(FontName[2],CharName2, FontName[1],CharName1) - show_name_diffs(FontName[1],CharName1, FontName[2],CharName2) - show_num_diffs("WX width differences", WXDIFF) - show_num_diffs("Bounding box width differences", BXDIFF) - show_num_diffs("Bounding box height differences",BYDIFF) - } - -function show_name_diffs(font1,array1,font2,array2, name) -{ - print "\nChars from", font2, "missing from", font1 ":" - for (name in array2) - { - if (!(name in array1)) - printf("%s\n", name) | Sortpipe - } - close(Sortpipe) -} - -function show_num_diffs(title,array, name) -{ - printf("\n%s:\n", title) - for (name in array) - printf("%-15s\t%4d\n", name, array[name]) | Sortpipe - close(Sortpipe) -} diff --git a/Master/tlpkg/tlgs/lib/align.ps b/Master/tlpkg/tlgs/lib/align.ps deleted file mode 100644 index 58d9e600495..00000000000 --- a/Master/tlpkg/tlgs/lib/align.ps +++ /dev/null @@ -1,73 +0,0 @@ -% Copyright (C) 1989, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: align.ps 6300 2005-12-28 19:56:24Z giles $
-% Print a page that indicates the proper settings of Margins and HWMargins
-% for a given device. Requires a Level 2 system.
-
-% Reset the offset and margins.
-
-<<
- /PageOffset [0 0]
- /Margins [0 0]
- /.HWMargins [0 0 0 0]
->>
-setpagedevice
-<<
- /ImagingBBox null
->>
-setpagedevice
-
-% Determine the actual page size.
-
-clippath pathbbox newpath
-/y1 exch def /x1 exch def pop pop
-
-% Draw lines that should be exactly 1" in from each edge,
-% and should extend precisely to the edge of the paper.
-
-1 setlinewidth
-0 setgray
-72 0 moveto 0 y1 rlineto stroke
-0 72 moveto x1 0 rlineto stroke
-
-% Print the text in the middle of the page.
-
-/S 80 string def
-108 480 moveto
-/Helvetica 12 selectfont
- { currentfile S readline pop dup (%END) eq { pop exit } if
- gsave show grestore 0 -15 rmoveto
- } loop
-Let the distance in inches from the left edge of the page to
-the vertical line be H, and from the bottom edge to the
-horizontal line be V; let the lengths of the gaps at the top
-and bottom of the vertical line be T and B respectively, and
-the gaps at the left and right of the horizontal line be L
-and R. For correct alignment of pages, put the following line
-in a file named (for example) margins.ps, and then mention
-margins.ps on the gs command line when printing any of your
-own files:
-
- << /.HWMargins [ml mb mr mt] /Margins [x y] >> setpagedevice
-
-where
- ml = L * 72, mb = B * 72, mr = R * 72, mt = T * 72,
-%END
-/res currentpagedevice /.MarginsHWResolution get def
-( x = (1 - H) * ) show res 0 get =string cvs show
-(, y = (V - 1) * ) show res 1 get =string cvs show
-
-showpage
diff --git a/Master/tlpkg/tlgs/lib/bdftops.ps b/Master/tlpkg/tlgs/lib/bdftops.ps deleted file mode 100644 index 3b620d0eb59..00000000000 --- a/Master/tlpkg/tlgs/lib/bdftops.ps +++ /dev/null @@ -1,795 +0,0 @@ -% Copyright (C) 1990, 1995, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: bdftops.ps 6300 2005-12-28 19:56:24Z giles $
-% bdftops.ps
-% Convert a BDF file (possibly with (an) associated AFM file(s))
-% to a PostScript Type 1 font (without eexec encryption).
-% The resulting font will work with any PostScript language interpreter,
-% but not with ATM or other font rasterizers lacking a complete interpreter.
-
-/envBDF 120 dict def
-envBDF begin
-
-% "Import" the image-to-path package.
-% This also brings in the Type 1 opcodes (type1ops.ps).
- (impath.ps) runlibfile
-
-% "Import" the font-writing package.
- (wrfont.ps) runlibfile
- wrfont_dict begin
- /binary_CharStrings false def
- /binary_tokens false def
- /encrypt_CharStrings true def
- /standard_only true def
- end
- /lenIV 0 def
-
-% Invert the StandardEncoding vector.
- 256 dict dup begin
- 0 1 255 { dup StandardEncoding exch get exch def } for
- end /StandardDecoding exch def
-
-% Define the properties copied to FontInfo.
- mark
- (COPYRIGHT) /Notice
- (FAMILY_NAME) /FamilyName
- (FULL_NAME) /FullName
- (WEIGHT_NAME) /Weight
- .dicttomark /properties exch def
-
-% Define the character sequences for synthesizing missing composite
-% characters in the standard encoding.
- mark
- /AE [/A /E]
- /OE [/O /E]
- /ae [/a /e]
- /ellipsis [/period /period /period]
- /emdash [/hyphen /hyphen /hyphen]
- /endash [/hyphen /hyphen]
- /fi [/f /i]
- /fl [/f /l]
- /germandbls [/s /s]
- /guillemotleft [/less /less]
- /guillemotright [/greater /greater]
- /oe [/o /e]
- /quotedblbase [/comma /comma]
- .dicttomark /composites exch def
-
-% Define the procedure for synthesizing composites.
-% This must not be bound.
- /compose
- { exch pop
- FontMatrix Private /composematrix get invertmatrix concat
- 0 0 moveto
- dup gsave false charpath pathbbox currentpoint grestore
- 6 2 roll setcachedevice show
- } def
-% Define the CharString procedure that calls compose, with the string
-% on the stack. This too must remain unbound.
- /compose_proc
- { Private /compose get exec
- } def
-
-% Define aliases for missing characters similarly.
- mark
- /acute /quoteright
- /bullet /asterisk
- /cedilla /comma
- /circumflex /asciicircum
- /dieresis /quotedbl
- /dotlessi /i
- /exclamdown /exclam
- /florin /f
- /fraction /slash
- /grave /quoteleft
- /guilsinglleft /less
- /guilsinglright /greater
- /hungarumlaut /quotedbl
- /periodcentered /asterisk
- /questiondown /question
- /quotedblleft /quotedbl
- /quotedblright /quotedbl
- /quotesinglbase /comma
- /quotesingle /quoteright
- /tilde /asciitilde
- .dicttomark /aliases exch def
-
-% Define overstruck characters that can be synthesized with seac.
- mark
- [ /Aacute /Acircumflex /Adieresis /Agrave /Aring /Atilde
- /Ccedilla
- /Eacute /Ecircumflex /Edieresis /Egrave
- /Iacute /Icircumflex /Idieresis /Igrave
- /Lslash
- /Ntilde
- /Oacute /Ocircumflex /Odieresis /Ograve /Otilde
- /Scaron
- /Uacute /Ucircumflex /Udieresis /Ugrave
- /Yacute /Ydieresis
- /Zcaron
- /aacute /acircumflex /adieresis /agrave /aring /atilde
- /ccedilla
- /eacute /ecircumflex /edieresis /egrave
- /iacute /icircumflex /idieresis /igrave
- /lslash
- /ntilde
- /oacute /ocircumflex /odieresis /ograve /otilde
- /scaron
- /uacute /ucircumflex /udieresis /ugrave
- /yacute /ydieresis
- /zcaron
- ]
- { dup =string cvs
- [ exch dup 0 1 getinterval cvn
- exch dup length 1 sub 1 exch getinterval cvn
- ]
- } forall
- /cent [/c /slash]
- /daggerdbl [/bar /equal]
- /divide [/colon /hyphen]
- /sterling [/L /hyphen]
- /yen [/Y /equal]
- .dicttomark /accentedchars exch def
-
-% ------ Output utilities ------ %
-
- /ws {psfile exch writestring} bind def
- /wl {ws (\n) ws} bind def
- /wt {=string cvs ws ( ) ws} bind def
-
-% ------ BDF file parsing utilities ------ %
-
-% Define a buffer for reading the BDF file.
- /buffer 400 string def
-
-% Read a line from the BDF file into the buffer.
-% Ignore empty (zero-length) lines.
-% Define /keyword as the first word on the line.
-% Define /args as the remainder of the line.
-% If the keyword is equal to commentword, skip the line.
-% (If commentword is equal to a space, never skip.)
- /nextline
- { { bdfile buffer readline not
- { (Premature EOF\n) print stop } if
- dup length 0 ne { exit } if pop
- }
- loop
- ( ) search
- { /keyword exch def pop }
- { /keyword exch def () }
- ifelse
- /args exch def
- keyword commentword eq { nextline } if
- } bind def
-
-% Get a word argument from args. We do *not* copy the string.
- /warg % warg -> string
- { args ( ) search
- { exch pop exch }
- { () }
- ifelse /args exch def
- } bind def
-
-% Get an integer argument from args.
- /iarg % iarg -> int
- { warg cvi
- } bind def
-
-% Get a numeric argument from args.
- /narg % narg -> int|real
- { warg cvr
- dup dup cvi eq { cvi } if
- } bind def
-
-% Convert the remainder of args into a string.
- /remarg % remarg -> string
- { args copystring
- } bind def
-
-% Get a string argument that occupies the remainder of args.
- /sarg % sarg -> string
- { args (") anchorsearch
- { pop /args exch def } { pop } ifelse
- args args length 1 sub get (") 0 get eq
- { args 0 args length 1 sub getinterval /args exch def } if
- args copystring
- } bind def
-
-% Check that the keyword is the expected one.
- /checkline % (EXPECTED-KEYWORD) checkline ->
- { dup keyword ne
- { (Expected ) print =
- (Line=) print keyword print ( ) print args print (\n) print stop
- } if
- pop
- } bind def
-
-% Read a line and check its keyword.
- /getline % (EXPECTED-KEYWORD) getline ->
- { nextline checkline
- } bind def
-
-% Find the first/last non-zero bit of a non-zero byte.
- /fnzb
- { 0 { exch dup 128 ge { pop exit } { dup add exch 1 add } ifelse }
- loop
- } bind def
- /lnzb
- { 7 { exch dup 1 and 0 ne { pop exit } { -1 bitshift exch 1 sub } ifelse }
- loop
- } bind def
-
-% ------ Type 1 encoding utilities ------ %
-
-% Parse the side bearing and width information that begins a CharString.
-% Arguments: charstring. Result: sbx sby wx wy substring.
- /parsesbw
- { mark exch lenIV
- { % stack: mark ... string dropcount
- dup 2 index length exch sub getinterval
- dup 0 get dup 32 lt { pop exit } if
- dup 246 le
- { 139 sub exch 1 }
- { dup 250 le
- { 247 sub 8 bitshift 108 add 1 index 1 get add exch 2 }
- { dup 254 le
- { 251 sub 8 bitshift 108 add 1 index 1 get add neg exch 2 }
- { pop dup 1 get 128 xor 128 sub
- 8 bitshift 1 index 2 get add
- 8 bitshift 1 index 3 get add
- 8 bitshift 1 index 4 get add exch 5
- } ifelse
- } ifelse
- } ifelse
- } loop
- counttomark 3 eq { 0 3 1 roll 0 exch } if
- 6 -1 roll pop
- } bind def
-
-% Find the side bearing and width information that begins a CharString.
-% Arguments: charstring. Result: charstring sizethroughsbw.
- /findsbw
- { dup parsesbw 4 { exch pop } repeat skipsbw
- } bind def
- /skipsbw % charstring sbwprefix -> sizethroughsbw
- { length 1 index length exch sub
- 2 copy get 12 eq { 2 } { 1 } ifelse add
- } bind def
-
-% Encode a number, and append it to a string.
-% Arguments: str num. Result: newstr.
- /concatnum
- { dup dup -107 ge exch 107 le and
- { 139 add 1 string dup 0 3 index put }
- { dup dup -1131 ge exch 1131 le and
- { dup 0 ge { 16#f694 } { neg 16#fa94 } ifelse add
- 2 string dup 0 3 index -8 bitshift put
- dup 1 3 index 255 and put
- }
- { 5 string dup 0 255 put exch
- 2 copy 1 exch -24 bitshift 255 and put
- 2 copy 2 exch -16 bitshift 255 and put
- 2 copy 3 exch -8 bitshift 255 and put
- 2 copy 4 exch 255 and put
- exch
- }
- ifelse
- }
- ifelse exch pop concatstrings
- } bind def
-
-% ------ Point arithmetic utilities ------ %
-
- /ptadd { exch 4 -1 roll add 3 1 roll add } bind def
- /ptexch { 4 2 roll } bind def
- /ptneg { neg exch neg exch } bind def
- /ptpop { pop pop } bind def
- /ptsub { ptneg ptadd } bind def
-
-% ------ The main program ------ %
-
- /readBDF % <infilename> <outfilename> <fontname>
- % <encodingname> <uniqueID> <xuid> readBDF -> <font>
- { /xuid exch def % may be null
- /uniqueID exch def % may be -1
- /encodingname exch def
- /encoding encodingname cvx exec def
- /fontname exch def
- /psname exch def
- /bdfname exch def
- gsave % so we can set the CTM to the font matrix
-
-% Open the input files. We don't open the output file until
-% we've done a minimal validity check on the input.
- bdfname (r) file /bdfile exch def
- /commentword ( ) def
-
-% Check for the STARTFONT.
- (STARTFONT) getline
- args (2.1) ne { (Not version 2.1\n) print stop } if
-
-% Initialize the font.
- /Font 20 dict def
- Font begin
- /FontName fontname def
- /PaintType 0 def
- /FontType 1 def
- uniqueID 0 gt { /UniqueID uniqueID def } if
- xuid null ne { /XUID xuid def } if
- /Encoding encoding def
- /FontInfo 20 dict def
- /Private 20 dict def
- currentdict end currentdict end
- exch begin begin % insert font above environment
-
-% Initialize the Private dictionary in the font.
- Private begin
- /-! {string currentfile exch readhexstring pop} readonly def
- /-| {string currentfile exch readstring pop} readonly def
- /|- {readonly def} readonly def
- /| {readonly put} readonly def
- /BlueValues [] def
- /lenIV lenIV def
- /MinFeature {16 16} def
- /password 5839 def
- /UniqueID uniqueID def
- end % Private
-
-% Invert the Encoding, for synthesizing composite characters.
- /decoding encoding length dict def
- 0 1 encoding length 1 sub
- { dup encoding exch get exch decoding 3 1 roll put }
- for
-
-% Now open the output file.
- psname (w) file /psfile exch def
-
-% Put out a header compatible with the Adobe "standard".
- (%!FontType1-1.0: ) ws fontname wt (000.000) wl
- (% This is a font description converted from ) ws
- bdfname wl
- (% by bdftops running on ) ws
- statusdict /product get ws ( revision ) ws
- revision =string cvs ws (.) wl
-
-% Copy the initial comments, up to FONT.
- true
- { nextline
- keyword (COMMENT) ne {exit} if
- { (% Here are the initial comments from the BDF file:\n%) wl
- } if false
- (%) ws remarg wl
- } loop pop
- () wl
- /commentword (COMMENT) def % do skip comments from now on
-
-% Read and process the FONT, SIZE, and FONTBOUNDINGBOX.
- % If we cared about FONT, we'd use it here. If the BDF files
- % from MIT had PostScript names rather than X names, we would
- % care; but what's there is unusable, so we discard FONT.
- % The FONTBOUNDINGBOX may not be reliable, so we discard it too.
- (FONT) checkline
- (SIZE) getline
- /pointsize iarg def /xres iarg def /yres iarg def
- (FONTBOUNDINGBOX) getline
- nextline
-
-% Initialize the font bounding box bookeeping.
- /fbbxo 1000 def
- /fbbyo 1000 def
- /fbbxe -1000 def
- /fbbye -1000 def
-
-% Read and process the properties. We only care about a few of them.
- keyword (STARTPROPERTIES) eq
- { iarg
- { nextline
- properties keyword known
- { FontInfo properties keyword get sarg readonly put
- } if
- } repeat
- (ENDPROPERTIES) getline
- nextline
- } if
-
-% Compute and set the FontMatrix.
- Font /FontMatrix
- [ 0.001 0 0 0.001 xres mul yres div 0 0 ] readonly
- dup setmatrix put
-
-% Read and process the header for the bitmaps.
- (CHARS) checkline
- /ccount iarg def
-
-% Initialize the CharStrings dictionary.
- /charstrings ccount
- composites length add
- aliases length add
- accentedchars length add
- 1 add dict def % 1 add for .notdef
- /isfixedwidth true def
- /fixedwidth null def
- /subrcount 0 def
- /subrs [] def
-
-% Read the bitmap data. This reads the remainder of the file.
-% We do this before processing the bitmaps so that we can compute
-% the correct FontBBox first.
- /chardata ccount dict def
- ccount -1 1
- { (STARTCHAR) getline
- /charname remarg def
- (ENCODING) getline
- /eindex iarg def
- eindex dup 0 ge exch 255 le and
- { charname /charname StandardEncoding eindex get def
- charname /.notdef eq eindex 0 gt and
- { /charname (A) eindex =string cvs concatstrings cvn def
- }
- if
- (/) print charname =string cvs print (,) print print
- }
- { (/) print charname print
- }
- ifelse
- 10 mod 1 eq { (\n) print flush } if
- (SWIDTH) getline
- /swx iarg pointsize mul 1000 div xres mul 72 div def
- /swy iarg pointsize mul 1000 div xres mul 72 div def
- (DWIDTH) getline % Ignore, use SWIDTH instead
- (BBX) getline
- /bbw iarg def /bbh iarg def /bbox iarg def /bboy iarg def
- nextline
- keyword (ATTRIBUTES) eq
- { nextline
- } if
- (BITMAP) checkline
-
-% Update the font bounding box.
- /fbbxo fbbxo bbox .min def
- /fbbyo fbbyo bboy .min def
- /fbbxe fbbxe bbox bbw add .max def
- /fbbye fbbye bboy bbh add .max def
-
-% Read the bits for this character.
- /raster bbw 7 add 8 idiv def
- /cbits raster bbh mul string def
- cbits length 0 gt
- { 0 raster cbits length raster sub
- { cbits exch raster getinterval
- bdfile buffer readline not
- { (EOF in bitmap\n) print stop } if
- % stack has <cbits.interval> <buffer.interval>
- 0 () /SubFileDecode filter
- exch 2 copy readhexstring pop pop pop closefile
- } for
- } if
-
- (ENDCHAR) getline
-
-% Save the character data.
- chardata charname [swx swy bbw bbh bbox bboy cbits] put
- } for
-
- (ENDFONT) getline
-
-% Allocate the buffers for the bitmap and the outline,
-% according to the font bounding box.
- /fbbw fbbxe fbbxo sub def
- /fbbh fbbye fbbyo sub def
- /fraster fbbw 7 add 8 idiv def
- /bits fraster fbbh mul 200 .max 65535 .min string def
- /outline bits length 16 mul 65535 .min string def
-
-% Process the characters.
- chardata
- { exch /charname exch def aload pop
- /cbits exch def
- /bboy exch def /bbox exch def
- /bbh exch def /bbw exch def
- /swy exch def /swx exch def
-
-% The bitmap handed to type1imagepath must have the correct height,
-% because type1imagepath uses this to compute the scale factor,
-% so we have to clear the unused parts of it.
- /raster bbw 7 add 8 idiv def
- bits dup 0 1 raster fbbh mul 1 sub
- { 0 put dup } for
- pop pop
- bits raster fbbh bbh sub mul cbits putinterval
-
-% Compute the font entry, converting the bitmap to an outline.
- bits 0 raster fbbh mul getinterval % the bitmap image
- bbw fbbh % bitmap width & height
- swx swy % width x & y
- bbox neg bboy neg % origin x & y
- % Account for lenIV when converting the outline.
- outline lenIV outline length lenIV sub getinterval
- type1imagepath
- length lenIV add
- outline exch 0 exch getinterval
-
-% Check for a fixed width font.
- isfixedwidth
- { fixedwidth null eq
- { /fixedwidth swx def }
- { fixedwidth swx ne { /isfixedwidth false def } if }
- ifelse
- } if
-
-% Finish up the character.
- copystring
- charname exch charstrings 3 1 roll put
- } forall
-
-% Add CharStrings entries for aliases.
- aliases
- { charstrings 2 index known not charstrings 2 index known and
- { charstrings exch get charstrings 3 1 roll put
- }
- { pop pop
- }
- ifelse
- }
- forall
-
-% If this is not a fixed-width font, synthesize missing characters
-% out of available ones.
- isfixedwidth not
- { false composites
- { 1 index charstrings exch known not
- 1 index { decoding exch known and } forall
- { ( /) print 1 index bits cvs print
- /combine exch def
- 0 1 combine length 1 sub
- { dup combine exch get decoding exch get
- bits 3 1 roll put
- } for
- bits 0 combine length getinterval copystring
- [ exch /compose_proc load aload pop ] cvx
- charstrings 3 1 roll put
- pop true
- }
- { pop pop }
- ifelse
- }
- forall flush
- { Private /composematrix matrix put
- Private /compose /compose load put
- }
- if
- }
- if
-
-% Synthesize accented characters with seac if needed and possible.
- accentedchars
- { aload pop /accent exch def /base exch def
- buffer cvs /accented exch def
- charstrings accented known not
- charstrings base known and
- charstrings accent known and
- StandardDecoding base known and
- StandardDecoding accent known and
- encoding StandardDecoding base get get base eq and
- encoding StandardDecoding accent get get accent eq and
- { ( /) print accented print
- charstrings base get findsbw 0 exch getinterval
- /acstring exch def % start with sbw of base
- charstrings accent get parsesbw
- 4 { pop } repeat % just leave sbx
- acstring exch concatnum
- 0 concatnum 0 concatnum % adx ady
- decoding base get concatnum % bchar
- decoding accent get concatnum % achar
- s_seac concatstrings
- charstrings exch accented copystring exch put
- } if
- } forall
-
-% Make a CharStrings entry for .notdef.
- outline lenIV <8b8b0d0e> putinterval % 0 0 hsbw endchar
- charstrings /.notdef outline 0 lenIV 4 add getinterval copystring put
-
-% Encrypt the CharStrings and Subrs (in place).
- charstrings
- { % Be careful not to encrypt aliased characters twice,
- % since they share their CharString.
- aliases 2 index known
- { charstrings aliases 3 index get .knownget
- { 1 index ne }
- { true }
- ifelse
- }
- { true
- }
- ifelse
- 1 index type /stringtype eq and
- { 4330 exch dup .type1encrypt exch pop
- readonly charstrings 3 1 roll put
- }
- { pop pop
- }
- ifelse
- }
- forall
- 0 1 subrcount 1 sub
- { dup subrs exch get
- 4330 exch dup .type1encrypt exch pop
- subrs 3 1 roll put
- }
- for
-
-% Make most of the remaining entries in the font dictionaries.
-
-% The Type 1 font machinery really only works with a 1000 unit
-% character coordinate system. Set this up here, by computing the factor
-% to make the X entry in the FontMatrix come out at exactly 0.001.
- /fontscale 1000 fbbh div yres mul xres div def
- Font /FontBBox
- [ fbbxo fontscale mul
- fbbyo fontscale mul
- fbbxe fontscale mul
- fbbye fontscale mul
- ] cvx readonly put
- Font /CharStrings charstrings readonly put
- FontInfo /FullName known not
- { % Some programs insist on FullName being present.
- FontInfo /FullName FontName dup length string cvs put
- }
- if
- FontInfo /isFixedPitch isfixedwidth put
- subrcount 0 gt
- { Private /Subrs subrs 0 subrcount getinterval readonly put
- } if
-
-% Determine the italic angle and underline position
-% by actually installing the font.
- save
- /_temp_ Font definefont setfont
- [1000 0 0 1000 0 0] setmatrix % mitigate rounding problems
-% The italic angle is the multiple of -5 degrees
-% that minimizes the width of the 'I'.
- 0 9999 0 5 85
- { dup rotate
- newpath 0 0 moveto (I) false charpath
- dup neg rotate
- pathbbox pop exch pop exch sub
- dup 3 index lt { 4 -2 roll } if
- pop pop
- }
- for pop
-% The underline position is halfway between the bottom of the 'A'
-% and the bottom of the FontBBox.
- newpath 0 0 moveto (A) false charpath
- FontMatrix concat
- pathbbox pop pop exch pop
-% Put the values in FontInfo.
- 3 -1 roll
- restore
- Font /FontBBox get 1 get add 2 div cvi
- dup FontInfo /UnderlinePosition 3 -1 roll put
- 2 div abs FontInfo /UnderlineThickness 3 -1 roll put
- FontInfo /ItalicAngle 3 -1 roll put
-
-% Clean up and finish.
- grestore
- bdfile closefile
- Font currentdict end end begin % remove font from dict stack
- (\n) print flush
-
- } bind def
-
-% ------ Reader for AFM files ------ %
-
-% Dictionary for looking up character keywords
- /cmdict 6 dict dup begin
- /C { /c iarg def } def
- /N { /n warg copystring def } def
- /WX { /w narg def } def
- /W0X /WX load def
- /W /WX load def
- /W0 /WX load def
- end def
-
- /readAFM % fontdict afmfilename readAFM -> fontdict
- { (r) file /bdfile exch def
- /Font exch def
- /commentword (Comment) def
-
-% Check for the StartFontMetrics.
- (StartFontMetrics) getline
- args cvr 2.0 lt { (Not version 2.0 or greater\n) print stop } if
-
-% Look for StartCharMetrics, then parse the character metrics.
-% The only information we care about is the X width.
- /metrics 0 dict def
- { nextline
- keyword (EndFontMetrics) eq { exit } if
- keyword (StartCharMetrics) eq
- { iarg dup dict /metrics exch def
- { /c -1 def /n null def /w null def
- nextline buffer
- { token not { exit } if
- dup cmdict exch known
- { exch /args exch def cmdict exch get exec args }
- { pop }
- ifelse
- } loop
- c 0 ge n null ne or w null ne and
- { n null eq { /n Font /Encoding get c get def } if
- metrics n w put
- }
- if
- }
- repeat
- (EndCharMetrics) getline
- } if
- } loop
-
-% Insert the metrics in the font.
- metrics length 0 ne
- { Font /Metrics metrics readonly put
- } if
- Font
- } bind def
-
-end % envBDF
-
-% Enter the main program in the current dictionary.
-/bdfafmtops % infilename afmfilename* outfilename fontname
- % encodingname uniqueID xuid
- { envBDF begin
- 7 -2 roll exch 7 2 roll % afm* in out fontname encodingname uniqueID xuid
- readBDF % afm* font
- exch { readAFM } forall
- save exch
- dup /FontName get exch definefont
- setfont
- psfile writefont
- restore
- psfile closefile
- end
- } bind def
-
-% If the program was invoked from the command line, run it now.
-[ shellarguments
- { counttomark 4 ge
- { dup 0 get
- dup 48 ge exch 57 le and % last arg starts with a digit?
- { /StandardEncoding } % no encodingname
- { cvn } % have encodingname
- ifelse
- exch (.) search % next-to-last arg has . in it?
- { mark 4 1 roll % have xuid
- { cvi exch pop exch (.) search not { exit } if }
- loop cvi ]
- 3 -1 roll cvi exch
- }
- { cvi null % no xuid
- }
- ifelse
- counttomark 5 roll
- counttomark 6 sub array astore
- 7 -2 roll cvn 7 -3 roll % make sure fontname is a name
- bdfafmtops
- }
- { cleartomark
- (Usage:\n bdftops xx.bdf [yy1.afm ...] zz.gsf fontname uniqueID [xuid] [encodingname]\n) print flush
- mark
- }
- ifelse
- }
-if pop
diff --git a/Master/tlpkg/tlgs/lib/bj8.rpd b/Master/tlpkg/tlgs/lib/bj8.rpd deleted file mode 100644 index fce6c2d4b7d..00000000000 --- a/Master/tlpkg/tlgs/lib/bj8.rpd +++ /dev/null @@ -1,17 +0,0 @@ - -StartEntry: U_CanonBJC8200 -GSDriver: uniprint -Description: {Canon BJC-8200 (UP)} -About: { \ - Canon BJC-8200 uniprint driver settings.\ - } -Resolution: {NA} {NA} {} - BitsPerPixel: {bj8pp12f} {1200x1200DpI, photo paper pro, color, rendered} - BitsPerPixel: {bj8hg12f} {1200x1200DpI, high gloss photo film, color, rendered} - BitsPerPixel: {bj8gc12f} {1200x1200DpI, glossy photo cards, color, rendered} - BitsPerPixel: {bj8oh06n} {600x600DpI, transparencies, color, rendered} - BitsPerPixel: {bj8ts06n} {600x600DpI, t-shirt transfer, color, rendered} - BitsPerPixel: {bj8pa06n} {600x600DpI, plain paper, color, rendered} - -EndEntry -# diff --git a/Master/tlpkg/tlgs/lib/caption.ps b/Master/tlpkg/tlgs/lib/caption.ps deleted file mode 100644 index a41d99c5481..00000000000 --- a/Master/tlpkg/tlgs/lib/caption.ps +++ /dev/null @@ -1,56 +0,0 @@ -%!
-% Copyright (C) 1995 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: caption.ps 6300 2005-12-28 19:56:24Z giles $
-% Add a "caption" to the bottom of each page.
-/captionsize 20 def
-/caption
- { /Helvetica //captionsize selectfont
- (Printed by Aladdin's XXYYZZ) show
- /Symbol //captionsize selectfont
- (\324) show % trademarkserif
- /Helvetica //captionsize selectfont
- ( product) show
- } bind def
-
-10 dict begin
-gsave
- initgraphics
- clippath pathbbox
- pop exch 36 add /by exch def
- % We can't use stringwidth, so we have to show and measure.
- gsave
- 0 0 0 0 rectclip
- 0 0 moveto caption currentpoint pop /bw exch def
- grestore
- add bw sub 2 div /bx exch def
- % We don't have the font bbox available, so we guess.
- /bh captionsize 1.05 mul def
-grestore
-/showcaption
- { gsave
- initgraphics
- //bx 9 sub //by 9 sub //bw 18 add //bh 18 add
- 1 setgray 4 copy rectfill 0 setgray 1.5 setlinewidth rectstroke
- //bx //by moveto //caption exec
- grestore
- } bind def
-<< /EndPage [
- /showcaption load /exec load
- currentpagedevice /EndPage get /exec load
- ] cvx
->> setpagedevice
-end
diff --git a/Master/tlpkg/tlgs/lib/cid2code.ps b/Master/tlpkg/tlgs/lib/cid2code.ps deleted file mode 100644 index 475cf189baf..00000000000 --- a/Master/tlpkg/tlgs/lib/cid2code.ps +++ /dev/null @@ -1,160 +0,0 @@ -% Copyright (C) 1998, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: cid2code.ps 6300 2005-12-28 19:56:24Z giles $
-% Construct an inverse map from CIDs to codes.
-
-% Create an inverse map from CIDs to code values.
-% We only use this for 16-bit Unicode, so it has some limitations.
-% After invoking .cmap2code, loading a CMap file prints out the map
-% instead of doing what it usually does. For example:
-%
-% gs -dNODISPLAY -dBATCH lib/cid2code.ps -c .cmap2code\
-% -f Resource/CMap/UniJIS-UCS2-H > mapfile
-
-/.cmap2codedict 10 dict begin
-
-/begincmap {
- mark
-} def
-/endcmap {
- % Stack: mark code_lo1 code_hi1 cid1 ...
- 20 dict begin
- /depth counttomark 3 sub def
- % Do a first pass to determine the maximum CID.
- 0 0 3 depth {
- 1 add /d exch def
- d index d 2 add index 1 get add d 3 add index 1 get sub .max
- } for
- 1 add /ncid exch def
- /map ncid 2 mul string def
- % Now fill in the map.
- 0 3 depth {
- /d exch def
- d index 2 mul /cid2 exch def
- d 1 add index /hi exch def
- d 2 add index 2 string copy /lo exch def
- lo 1 get 1 hi 1 get {
- map cid2 lo 0 get put
- map cid2 1 add 3 -1 roll put
- /cid2 cid2 2 add def
- } for
- } for
- % Print the map.
- (%stdout) (w) file
- dup (<) print
- dup /ASCIIHexEncode filter
- dup map writestring
- closefile
- () = flush
- closefile
- end
-} def
-%/begincodespacerange
-/endcodespacerange {cleartomark} def
-%/usecmap
-
-%/beginbfchar
-/endbfchar {cleartomark} def
-%/beginbfrange
-/endbfrange {cleartomark} def
-
-%/begincidchar
-/endcidchar {
- counttomark 2 idiv { dup counttomark 1 add 3 roll } repeat pop
-} def
-%/begincidrange
-/endcidrange {
- counttomark 1 add -1 roll pop
-} def
-
-%/beginnotdefchar
-/endnotdefchar {cleartomark} def
-%/beginnotdefrange
-/endnotdefrange {cleartomark} def
-
-currentdict end readonly def
-
-/.cmap2code { % - .cmap2code -
- /CIDInit /ProcSet findresource dup length dict copy
- .cmap2codedict { 3 copy put pop pop } forall
- /CIDInit exch /ProcSet defineresource pop
-} def
-
-% Extract and print reverse mapping information from a cid2code.txt file.
-/.printhex2 { % <int16> .printhex2 -
- (<) print
- 16#10000 add 16 =string cvrs 1 4 getinterval print
- (>) print
-} def
-/.cid2code { % <cmaptemplate> <file> <column> .cid2code -
- 30 dict begin
- /column exch def
- (r) file /f exch def
- (%!) =
- (/CIDInit /ProcSet findresource begin 12 dict begin begincmap) =
- % Print the information from the template.
- {
- exch ==only ( ) print
- dup type /dicttype eq {
- dup length =only ( dict dup begin) = {
- ( ) print exch ===only ( ) print ===only ( def) =
- } forall (end def) =
- } {
- ===only
- } ifelse ( def) =
- } forall
- % Read the data from the cid2code.txt file.
- {
- f =string readline pop (CID\t) anchorsearch { pop pop exit } if pop
- } loop
- /map [ {
- f =string readline not { pop exit } if
- column { (\t) search pop pop pop } repeat
- (\t) search { exch pop exch pop } if
- (,) search { exch pop exch pop } if
- dup length 4 ne { pop (*) } if
- dup (*) eq { pop (0000) } if
- (16#) exch concatstrings cvi
- } loop ] def
- % Print the code space range(s).
- /maxcid map length 1 sub def
- mark maxcid
- dup 255 and 255 eq {
- 0 exch
- } {
- dup 16#ff00 and exch 0 2 index 1 sub
- } ifelse
- counttomark 2 idiv dup =only ( begincodespacerange) = {
- exch .printhex2 .printhex2 () =
- } repeat (endcodespacerange) =
- % Print the map data.
- 0 1 100 maxcid {
- /lo exch def
- /hi lo 99 add maxcid .min def
- 0 lo 1 hi { map exch get 0 ne { 1 add } if } for
- dup 0 eq {
- pop
- } {
- =only ( begincidchar) = lo 1 hi {
- map 1 index get dup 0 eq { pop pop } { exch .printhex2 = } ifelse
- } for (endcidchar) =
- } ifelse
- } for
- % Wrap up.
- (endcmap CMapName currentdict /CMap defineresource pop end end) =
- f closefile
- end
-} bind def
diff --git a/Master/tlpkg/tlgs/lib/cidfmap b/Master/tlpkg/tlgs/lib/cidfmap deleted file mode 100644 index 36c11d462b6..00000000000 --- a/Master/tlpkg/tlgs/lib/cidfmap +++ /dev/null @@ -1,28 +0,0 @@ -%!
-% $Id: cidfmap 6300 2005-12-28 19:56:24Z giles $
-% This is a sample map file for CIDFont category.
-
-%
-% The map is a set of records, which must use one of the two formats :
-%
-% 1. A substutution of a CIF font with another CID font :
-%
-% /substituted /original ;
-%
-% Where 'substituted' is a name being used in a document,
-% 'original' is a name of an available resource.
-%
-% 2. A substutution of a CIF font with a True Type font :
-%
-% /substituted << /FileType /TrueType /Path (path) /SunfontID 1 /CSI [(ordering) supplement] >> ;
-%
-% Where 'substituted' is a name being used in a document,
-% 'path' is a path to a True Type font file,
-% 'ordering' is a value of Ordering required for CIDSystemInfo dictionary,
-% 'supplement' is a value of Supplement required for CIDSystemInfo dictionary.
-%
-% Examples :
-%
-% /ShinGo-Bold /HeiseiKakuGo-W5 ;
-% /Ryumin-Medium << /FileType /TrueType /Path (H:/AuxFiles/Fonts/BATANG.TTC) /SubfontID 3 /CSI [(Japan1) 2] >> ;
-%
diff --git a/Master/tlpkg/tlgs/lib/decrypt.ps b/Master/tlpkg/tlgs/lib/decrypt.ps deleted file mode 100644 index b172f6d83b4..00000000000 --- a/Master/tlpkg/tlgs/lib/decrypt.ps +++ /dev/null @@ -1,15 +0,0 @@ -%!
-% Decrypt an eexec-encoded file.
-% $Id: decrypt.ps 6300 2005-12-28 19:56:24Z giles $
-
-(t.in) (r) file /in exch def
-(t.out) (w) file /out exch def
-256 string /buf exch def
-55665 % eexec encryption seed
- { in buf readhexstring /more exch def
- dup .type1decrypt out exch writestring
- more not { exit } if
- } loop
-in closefile
-out closefile
-quit
diff --git a/Master/tlpkg/tlgs/lib/docie.ps b/Master/tlpkg/tlgs/lib/docie.ps deleted file mode 100644 index 31b4df74ec0..00000000000 --- a/Master/tlpkg/tlgs/lib/docie.ps +++ /dev/null @@ -1,220 +0,0 @@ -% Copyright (C) 1995 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: docie.ps 8411 2007-11-28 18:39:59Z ray $
-% docie.ps
-% Emulate CIE algorithms in PostScript.
-
-% ---------------- Auxiliary procedures ---------------- %
-
-/r1default [0 1] def
-/r3default [0 1 0 1 0 1] def
-
-/apply3 % <u> <v> <w> [<pu> <pv> <pw>] apply3 <u'> <v'> <w'>
- { { 4 -1 roll exch exec } forall
- } bind def
-
-/restrict % <u> <min> <max> restrict <u'>
- { 3 1 roll .max .min
- } bind def
-
-/restrict3 % <u> <v> <w> [<minu> ... <maxw>] restrict3 <u'> <v'> <w'>
- { aload pop
- 7 -1 roll 3 1 roll restrict 7 1 roll
- 5 -1 roll 3 1 roll restrict 5 1 roll
- restrict 3 1 roll
- } bind def
-
-/rescale % <u> <min> <max> rescale <u'>
- { 1 index sub 3 1 roll sub exch div 0 .max 1 .min
- } bind def
-
-/rescale3 % <u> <v> <w> [<minu> ... <maxw>] rescale3 <u'> <v'> <w'>
- { aload pop
- 7 -1 roll 3 1 roll rescale 7 1 roll
- 5 -1 roll 3 1 roll rescale 5 1 roll
- rescale 3 1 roll
- } bind def
-
-/mmult3 % <u> <v> <w> [<uu> <uv> ... <wv> <ww>] mmult3
- % <u'> <v'> <w'>
- { 4 -1 roll dup dup 6 -1 roll dup dup 8 -1 roll dup dup
- 10 -1 roll { 10 -1 roll mul } forall
- % Stack: u1 v1 w1 u2 v2 w2 u3 v3 w3
- 4 -1 roll add 6 -1 roll add
- % Stack: u1 v1 u2 v2 u3 v3 w'
- 7 1 roll 3 -1 roll add 4 -1 roll add
- % Stack: w' u1 u2 u3 v'
- 5 1 roll add add 3 1 roll
- } bind def
-
-/minvert3 % [<uu> <uv> ... <wv> <ww>] minvert3
- % [<uu'> <uv'> ... <wv'> <ww'>]
- { 16 dict begin
- aload pop { I H G F E D C B A } { exch def } forall
- /coa E I mul F H mul sub def
- /cob F G mul D I mul sub def
- /coc D H mul E G mul sub def
- /det A coa mul B cob mul add C coc mul add def
- [ coa det div
- C H mul B I mul sub det div
- B F mul C E mul sub det div
- cob det div
- A I mul C G mul sub det div
- C D mul A F mul sub det div
- coc det div
- B G mul A H mul sub det div
- A E mul B D mul sub det div
- ]
- end
- } bind def
-
-/print1
- { print dup ==
- } bind def
-
-/print3
- { print 3 array astore dup == aload pop
- } bind def
-
-% ---------------- Mapping to XYZ ---------------- %
-
-/csmap % <csdict> <l> <m> <n> csmap <csdict> <x> <y> <z>
- { 3 index /RangeLMN .knownget not { r3default } if restrict3
-DOCIEDEBUG { (After RangeLMN Decode: ) print3 } if
- 3 index /DecodeLMN .knownget { apply3 } if
-DOCIEDEBUG { (After DecodeLMN Decode: ) print3 } if
- 3 index /MatrixLMN .knownget { mmult3 } if
-DOCIEDEBUG { (After MatrixLMN Decode: ) print3 } if
- } bind def
-
-/csciea % <csdict> <a> csciea <csdict> <x> <y> <z>
- { 1 index /RangeA .knownget not { r1default aload pop } if restrict
-DOCIEDEBUG { (After RangeA Decode: ) print1 } if
- 1 index /DecodeA .knownget { exec } if
-DOCIEDEBUG { (After DecodeA Decode: ) print1 } if
- 1 index /MatrixA .knownget
- { { 1 index mul exch } forall pop }
- { dup dup }
- ifelse
-DOCIEDEBUG { (After MatrixA Decode: ) print3 } if
- csmap
- } bind def
-
-/cscieabc % <csdict> <a> <b> <c> cscieabc <csdict> <x> <y> <z>
- { 3 index /RangeABC .knownget not { r3default } if restrict3
-DOCIEDEBUG { (After RangeABC Decode: ) print3 } if
- 3 index /DecodeABC .knownget { apply3 } if
-DOCIEDEBUG { (After DecodeABC Decode: ) print3 } if
- 3 index /MatrixABC .knownget { mmult3 } if
-DOCIEDEBUG { (After MatrixABC Decode: ) print3 } if
- csmap
- } bind def
-
-% ---------------- Rendering from XYZ ---------------- %
-
-/lookup3 % <rtable> <a[0..1]> <b[0..1]> <c[0..1]> lookup3
- % <rtable> <bytes>
- { 3 -1 roll 3 index 0 get 1 sub mul
- 3 -1 roll 3 index 1 get 1 sub mul
- 3 -1 roll 3 index 2 get 1 sub mul
- % Stack: rtable ia ib ic
-DOCIEDEBUG { (RenderTable indices: ) print3 mark 5 1 roll } if
- 3 -1 roll round cvi 3 index 3 get exch get
- % Stack: rtable ib ic string
- 3 -1 roll round cvi 3 index 2 get mul
- % Stack: rtable ic string ib*nc
- 3 -1 roll round cvi add 2 index 4 get mul
- % Stack: rtable string index
- 2 index 4 get getinterval
- % Stack: rtable bytes
-DOCIEDEBUG { (RenderTable values: ) print (<) print (%stdout) (w) file 1 index writehexstring (>) = } if
- } bind def
-
-/bpdefault [0 0 0] def
-
-/crmap % <csdict> <crdict> <x> <y> <z> crmap <v1> ...
- {
-DOCIEDEBUG { (CIE XYZ = ) print3 } if
- 3 index /MatrixPQR .knownget { mmult3 } if
-DOCIEDEBUG { (After MatrixPQR: ) print3 } if
- 4 index /WhitePoint get
- 5 index /BlackPoint .knownget not { bpdefault } if
- 5 index /WhitePoint get
- 6 index /BlackPoint .knownget not { bpdefault } if
- 4
- { 4 -1 roll aload pop
- % Stack: csdict crdict x y z pt pt pt px py pz
- 3 copy 12 index /MatrixPQR .knownget { mmult3 } if 6 array astore
- }
- repeat
- % Stack: csdict crdict x y z wps+ bps+ wpd+ bpd+
- 9 -1 roll pop % get rid of csdict
- 7 4 roll
- 7 index /TransformPQR get
- { % Stack: crdict wps+ bps+ wpd+ bpd+ u v w proc
- 8 copy exch pop exch pop
- exec exch pop 4 -1 roll pop
- }
- forall
- 7 3 roll pop pop pop pop % get rid of White/BlackPoints
-DOCIEDEBUG { (After TransformPQR: ) print3 } if
- 3 index /MatrixPQR .knownget { minvert3 mmult3 } if
-DOCIEDEBUG { (After MatrixPQR': ) print3 } if
- 3 index /MatrixLMN .knownget { mmult3 } if
-DOCIEDEBUG { (After MatrixLMN Encode: ) print3 } if
- 3 index /EncodeLMN .knownget { apply3 } if
-DOCIEDEBUG { (After EncodeLMN Encode: ) print3 } if
- 3 index /RangeLMN .knownget not { r3default } if restrict3
-DOCIEDEBUG { (After RangeLMN Encode: ) print3 } if
- 3 index /MatrixABC .knownget { mmult3 } if
-DOCIEDEBUG { (After MatrixABC Encode: ) print3 } if
- 3 index /EncodeABC .knownget { apply3 } if
-DOCIEDEBUG { (After EncodeABC Encode: ) print3 } if
- 3 index /RangeABC .knownget not { r3default } if
- 5 -1 roll /RenderTable .knownget
- { % Stack: u v w ranges rtable
- 5 1 roll rescale3
-DOCIEDEBUG { (Rescaled ABC: ) print3 } if
- % Stack: rtable a b c
- lookup3
- % Stack: rtable bytes
- 0 1 3 index 4 get 1 sub
- { % Stack: values rtable bytes c
- 2 copy get 255 div
- % Stack: values rtable bytes c v
- 3 index 3 -1 roll 5 add get exec 3 1 roll
- }
- for pop pop
-DOCIEDEBUG { (After RenderTableT: ) print ] dup == aload pop } if
- }
- { restrict3
-DOCIEDEBUG { (After RangeABC Encode: ) print3 } if
- }
- ifelse
- } bind def
-
-% ---------------- Top level control ---------------- %
-
-/mapdict mark
- /CIEBasedA { 1 get exch csciea currentcolorrendering 4 1 roll crmap } bind
- /DeviceGray { pop /DefaultGray /ColorSpace findresource 1 get exch csciea currentcolorrendering 4 1 roll crmap } bind
- /CIEBasedABC { 1 get 4 1 roll cscieabc currentcolorrendering 4 1 roll crmap } bind
- /DeviceRGB { pop /DefaultRGB /ColorSpace findresource 1 get 4 1 roll cscieabc currentcolorrendering 4 1 roll crmap } bind
-.dicttomark def
-/mapcie % <a> mapcie <v1> ...
- % <a> <b> <c> mapcie <v1> ...
- { currentcolorspace dup 0 get //mapdict exch get exec
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/dumphint.ps b/Master/tlpkg/tlgs/lib/dumphint.ps deleted file mode 100644 index c5e1e2f81f4..00000000000 --- a/Master/tlpkg/tlgs/lib/dumphint.ps +++ /dev/null @@ -1,756 +0,0 @@ -% Copyright (C) 2000, 2001 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: dumphint.ps 8284 2007-10-10 17:40:38Z giles $
-% Linearized PDF hint formatting utility.
-
-%
-% Linearized PDF hints generated by Acrobat suite seem to deviate from
-% the published specification.
-%
-% /P (page offset hint table) key in hint stream is not generated by
-% Adobe products. The key is no longer required in PDF 1.5.
-%
-% Per-page items 4 and 5 of the page offset hint table start from 1st
-% page rather than 2nd page as the spec claims.
-%
-% All array entries start from the new byte boundary.
-%
-
-/table_width 79 def
-/col1_width 66 def
-
-% Skip bits to the next byte boundary
-/bytealign { % <stream> bytealign -
- begin /N 0 def /B 0 def end
-} bind def
-
-% Set bit stream position and align it to byte boundary
-/set_align { % <<>> pos set_align -
- exch begin
- S exch setfileposition
- /N 0 def /B 0 def
- end
-} bind def
-
-% Read requested number of bits from the bit stream.
-/bitread { % <bstream> <width> bitwrite <value>
- exch begin
- 0 % bit val
- {
- 1 index N .min % bit val m
- dup 3 1 roll % bit m val m
- bitshift % bit m val<<m
- B 2 index N sub % bit m val<<m B m-N
- bitshift add % bit m val<<m+B>>(N-m)
- 3 -1 roll % m val' bit
- 2 index sub % m val' bit'
- 3 -1 roll % val' bit' m
- N exch sub dup % val' bit' N' N'
- 1 exch bitshift % val' bit' N' 1<<N'
- 1 sub B and % val' bit' N' B&(1<<N')
- /B exch def % val' bit' N'
- /N exch def % val' bit'
- dup 0 le {
- pop exit % val'
- } if
- /N N 8 add def
- /B B 8 bitshift S read not { 0 ( *** EOF! *** ) = } if add def
- exch
- } loop % bit' val'
- end
-} bind def
-
-% Print a string several times
-/multiprint { % cnt (s) multiprint -
- exch { dup print } repeat pop
-} bind def
-
-% Split the line into 2 substrings.
-/split_line { % (s) split_line () ()
- dup length col1_width gt {
- col1_width 1 sub
- dup -1 0 {
- dup % (s) w i i
- 3 index % (s) w i i ()
- exch get % (s) w i c
- 32 eq {
- exch pop exit
- } if
- pop
- } for
- 1 add % (s) w'
- 1 index exch % (s) (s) w'
- 0 exch % (s) (s) 0 w'
- getinterval % (s) (v)
- } {
- dup % (s) (s)
- } ifelse
- (\n) search {
- 4 1 roll % (pre) (s) (post) (match)
- pop pop % (pre) (s)
- 1 index length % (pre) (s) len
- 1 add % (pre) (s) len+1
- } {
- exch % (pre) (s)
- 1 index length % (pre) (s) len
- } ifelse
- 1 index length % (pre) (s) len Len
- 1 index sub % (pre) (s) len Len-len
- getinterval % (pre) (post)
-} bind def
-
-% Print a 2 column table. The string is printed in 1st column
-% left-aligned. The number is printed in 2nd column right-aligned.
-/two_column { % n () two_column -
- split_line % n (a) ()
- 3 1 roll % () n (a)
- dup length % () n (a) len
- exch print % () n len
- exch =string cvs % () len (n)
- dup length % () len (n) len2
- 3 -1 roll add % () (n) len+len2
- //table_width % () (n) len+len2 78
- exch sub % () (n) 78-len+len2
- ( ) multiprint % () (n)
- = % ()
- { dup length 0 eq { exit } if
- split_line exch =
- } loop
- pop
- () =
-} bind def
-
-% Print the header of a hint table
-/table_header { % () table_header -
- dup length dup
- table_width exch sub 2 idiv % () len sp
- dup ( ) multiprint % () len sp
- 3 -1 roll = % len sp
- ( ) multiprint % len
- (=) multiprint
- ()= ()=
-} bind def
-
-% Pretty-print an array on top level
-/dump_array { % [ ] dump_array -
- ([) = ( ) print
- 1 exch {
- =string cvs % pos ()
- dup length dup % pos () len len
- 3 index add 1 add % pos () len len+pos+1
- table_width gt {
- () =
- ( ) print % pos () len
- 2 add % pos () pos'
- 3 1 roll print pop % pos'
- } {
- ( ) print % pos () len
- exch print % pos len
- add 1 add % pos'
- } ifelse
- } forall
- pop
- () = (]) =
-} bind def
-
-% Pretty-print an array on 2nd level
-/dump_array2 { % [ ] dump_array2 -
- ( [) print
- 3 exch {
- =string cvs % pos ()
- dup length dup % pos () len len
- 3 index add 1 add % pos () len len+pos+1
- table_width 2 sub gt {
- () =
- ( ) print % pos () len
- 4 add % pos () pos'
- 3 1 roll print pop % pos'
- } {
- ( ) print % pos () len
- exch print % pos len
- add 1 add % pos'
- } ifelse
- } forall
- pop
- ( ]) =
-} bind def
-
-% Print an array header
-/array_header {
- () = =
-} bind def
-
-% Analyze the page offset hint table.
-/dump_page_offset_table { % - dump_page_offset_table -
- hint_stream
-
- dup 32 bitread
- dup /hint_minnop exch def
- (1. The least number of objects in a page.) two_column
-
- dup 32 bitread
- dup /hint_1st_obj exch def
- (2. Location of the first page's page object.) two_column
-
- dup 16 bitread
- dup /hint_maxnopbits exch def
- (3. Bits for difference between max and min number of page objects.) two_column
-
- dup 32 bitread
- dup /hint_minpl exch def
- (4. Least length of a page.) two_column
-
- dup 16 bitread
- dup /hint_maxplbits exch def
- (5. Bits for difference between max and min length of a page.) two_column
-
- dup 32 bitread
- dup /hint_minsco exch def
- (6. Least start of Contents offset. )
- 1 index 0 ne { (\n*** Acrobat expects 0 ***) concatstrings } if
- two_column
-
- dup 16 bitread
- dup /hint_maxscobits exch def
- (7. Bits for difference between max and min offset to the start of the content stream.) two_column
-
- dup 32 bitread
- dup /hint_mincl exch def
- (8. Least contents length.) two_column
-
- dup 16 bitread
- dup /hint_maxclbits exch def
- (9. Bits needed to represent the greatest Contents length.) two_column
-
- dup 16 bitread
- dup /hint_maxsorbits exch def
- (10. Bits needed to represent the greatest number of Shared Object references.) two_column
-
- dup 16 bitread
- dup /hint_sobits exch def
- (11. Bits needed to identify a Shared Object.) two_column
-
- dup 16 bitread
- dup /hint_numfbits exch def
- (12. Bits needed to represent numerator of fraction.) two_column
-
- dup 16 bitread
- dup /hint_denf exch def
- (13. Denominator of fraction.) two_column
-
- pop
-
- LinearizationParams /N get
-
- % 1. Number of objects in the page.
- hint_stream bytealign
- /hint_page_obj [
- 2 index {
- hint_stream hint_maxnopbits bitread
- hint_minnop add
- } repeat
- ] readonly def
-
- (1. Number of objects on the page) array_header
- hint_page_obj dump_array
-
- % 2, Page length in bytes.
- hint_stream bytealign
- /hint_page_len [
- 2 index {
- hint_stream hint_maxplbits bitread
- hint_minpl add
- } repeat
- ] readonly def
-
- (2. Page length in bytes.) array_header
- hint_page_len dump_array
-
- % 3, Number of shared objects referenced from the page
- hint_stream bytealign
- /hint_page_sobj [
- 2 index {
- hint_stream hint_maxsorbits bitread
- } repeat
- ] readonly def
-
- (3. Number of shared objects referenced from the page.) array_header
- hint_page_sobj dump_array
-
- % 4. Index into the shared objects hint table
- hint_stream bytealign
- /hint_page_sobj_id [
- 0 1 4 index 1 sub {
- hint_page_sobj exch get [
- exch {
- hint_stream hint_sobits bitread
- } repeat
- ] readonly
- } for
- ] readonly def
-
- (4. Index into the shared objects hint table.) array_header
- ([) =
- hint_page_sobj_id { dump_array2 } forall
- (])=
-
- % 5. Fractional position for each shared object reference
- hint_stream bytealign
- /hint_page_sobj_pos [
- 0 1 4 index 1 sub {
- hint_page_sobj exch get [
- exch {
- hint_stream hint_numfbits bitread
- hint_denf div
- } repeat
- ] readonly
- } for
- ] readonly def
-
- (5. Fractional position for each shared object reference. ) array_header
- ([)=
- hint_page_sobj_pos { dump_array2 } forall
- (])=
-
- % 6. Offset of the page's content stream from the beginning of the page.
- hint_stream bytealign
- /hint_page_content_offset [
- 2 index {
- hint_stream hint_maxscobits bitread
- hint_minsco add
- } repeat
- ] readonly def
-
- (6. Offset of the page's content stream from the beginning of the page.) array_header
- hint_page_content_offset dump_array
-
- % 7. Length of the page's content stream in bytes.
- hint_stream bytealign
- /hint_page_content_len [
- 2 index {
- hint_stream hint_maxclbits bitread
- hint_mincl add
- } repeat
- ] readonly def
-
- (7. Length of the page's content stream in bytes.) array_header
- hint_page_content_len dump_array
-
- pop
-} bind def
-
-% Analyze tha shared object hint table
-/dump_shared_object_table {
- hint_stream
-
- dup 32 bitread
- dup /shint_1st_obj_id exch def
- (1. Object number of the first object in the shared objects section) two_column
-
- dup 32 bitread
- dup /shint_1st_obj_pos exch def
- (2. Location of the first object in the shared objects section.) two_column
-
- dup 32 bitread
- dup /shint_1st_shared exch def
- (3. The number of shared object entries for the first page.) two_column
-
- dup 32 bitread
- dup /shint_all_shared exch def
- (4. Number of shared object entries for the shared objects section including 1st page.) two_column
-
- dup 16 bitread
- dup /shint_group_bits exch def
- (5. Number of bits needed to represent the greatest number of objects in a shared object group.) two_column
-
- dup 32 bitread
- dup /shint_group_least_sz exch def
- (6. Least length of a shared object group in bytes.) two_column
-
- dup 16 bitread
- dup /shint_group_diff_bits exch def
- (7. Bits for the difference between the greatest and least length of a shared object group size.) two_column
- pop
-
- (1. length of the object group in bytes.) array_header
- hint_stream bytealign
- /shint_group_sz [
- shint_all_shared {
- hint_stream shint_group_diff_bits bitread
- shint_group_least_sz add
- } repeat
- ] readonly def
-
- shint_group_sz dump_array
-
- (2. MD5 signature flag) array_header
- hint_stream bytealign
- /shint_md5_flags
- [ shint_all_shared
- { hint_stream 1 bitread
- } repeat
- ] readonly def
-
- shint_md5_flags dump_array
-
- (3. MD5 signature string) array_header
- false shint_md5_flags { 0 ne or } forall {
- shint_md5_flags {
- 0 eq {
- (<>)=
- } {
- hint_stream /S get 128 string
- readstring pop
- dup length 128 eq {
- ==
- } { pop (Error reading nd5 string.) ==
- } ifelse
- } ifelse
- } forall
- } {
- () = (none) =
- } ifelse
-
- (4. The number of objects in the group.) array_header
- hint_stream bytealign
- /shint_group_cnt [
- shint_all_shared {
- hint_stream shint_group_bits bitread
- } repeat
- ] readonly def
-
- shint_group_cnt dump_array
-
- } bind def
-
-% Analyze the thumbnail hint table.
-/dump_thumbnail_table {
- hint_stream
-
- dup 32 bitread
- dup /thint_1st_obj_id exch def
- (1. Object number of the first thumbnail image.) two_column
-
- dup 32 bitread
- dup /thint_1st_obj_pos exch def
- (2. Location of the first thumbnail image.) two_column
-
- dup 32 bitread
- dup /thint_page_cnt exch def
- (3. Number of pages that have thumbnail images.) two_column
-
- dup 16 bitread
- dup /thint_no_thumbnail_bits exch def
- (4. Bits for the max number of consecutive pages without a thumbnail image.) two_column
-
- dup 32 bitread
- dup /thint_min_sz exch def
- (5. The least length of a thumbnail image in bytes.) two_column
-
- dup 15 bitread
- dup /thint_obj_sz_bits exch def
- (6. Bits for the difference between max and min length of a thumbnail image.) two_column
-
- dup 32 bitread
- dup /thint_min_obj_cnt exch def
- (7. The least number of objects in a thumbnail image.) two_column
-
- dup 16 bitread
- dup /thint_obj_cnt_bits exch def
- (8. Bits for the difference between max and min number of objects in a thumbnail image.) two_column
-
- dup 32 bitread
- dup /thint_1st_shared_obj exch def
- (9. First object in the thumbnail shared objects section.) two_column
-
- dup 32 bitread
- dup /thint_1st_shared_pos exch def
- (10. Location of the first object in the thumbnail shared objects section.) two_column
-
- dup 32 bitread
- dup /thint_shared_cnt exch def
- (11. Number of thumbnail shared objects.) two_column
-
- dup 32 bitread
- dup /thint_shared_section_sz exch def
- (12. Length of the thumbnail shared objects section in bytes.) two_column
-
- pop
- LinearizationParams /N get
-
- (1. The number of preceding pages lacking a thumbnail image.) array_header
- hint_stream bytealign
- /thint_no_thumbnail_pages [
- 2 index {
- hint_stream thint_no_thumbnail_bits bitread
- } repeat
- ] readonly def
-
- thint_no_thumbnail_pages dump_array
-
- (2. Number of objects in this page's thumbnail image.) array_header
- hint_stream bytealign
- /thint_page_obj_cnt [
- 2 index {
- hint_stream thint_obj_cnt_bits bitread
- thint_min_obj_cnt add
- } repeat
- ] readonly def
-
- thint_page_obj_cnt dump_array
-
- (3. Length of this page's thumbnail image in bytes.) array_header
- hint_stream bytealign
- /thint_page_obj_sz [
- 2 index {
- hint_stream thint_obj_sz_bits bitread
- thint_min_sz add
- } repeat
- ] readonly def
-
- thint_page_obj_sz dump_array
- pop
-} bind def
-
-% Analyze the generic hint table.
-% The hint field names are re-used.
-/dump_generic_table {
- hint_stream
-
- dup 32 bitread
- dup /ghint_1st_obj exch def
- (1. Object number of the first object in the group.) two_column
-
- dup 32 bitread
- dup /ghint_1st_obj_pos exch def
- (2. Location of the first object in the group.) two_column
-
- dup 32 bitread
- dup /ghint_obj_cnt exch def
- (3. Number of objects in the group.) two_column
-
- dup 32 bitread
- dup /ghint_group_sz exch def
- (4. Length of the object group in bytes.) two_column
-
- pop
-} bind def
-
-% Analyze the interactive hint table.
-% The hint field names are re-used.
-/dump_interactive_table {
- hint_stream
-
- dup 32 bitread
- dup /ihint_1st_obj exch def
- (1. Object number of the first object in the group.) two_column
-
- dup 32 bitread
- dup /ihint_1st_obj_pos exch def
- (2. Location of the first object in the group.) two_column
-
- dup 32 bitread
- dup /ihint_obj_cnt exch def
- (3. Number of objects in the group.) two_column
-
- dup 32 bitread
- dup /ihint_group_sz exch def
- (4. Length of the object group in bytes.) two_column
-
- dup 32 bitread
- dup /ihint_shared_cnt exch def
- (5. Number of shared object references.) two_column
-
- dup 16 bitread
- dup /ihint_shared_obj_bits exch def
- (6. Bits for the max shared object id used by the interactive form or the logical structure hierarchy.)
- 1 index hint_sobits ne {
- (\n*** This fiels is not equal to max shared object ID bits ***) concatstrings
- } if
-
- pop
-
- (7. Shared object identifier.) array_header
- hint_stream bytealign
- /ihint_shared_obj_id [
- ihint_shared_cnt {
- hint_stream hint_sobits bitread
- } repeat
- ] readonly def
-
- ihint_shared_obj_id dump_array
-} bind def
-
-% Enumerate all documented hint tables.
-/dump_all_tables { % <<stream>> dump_all_tables -
- (Page offset hint table) table_header
- hint_stream 0 set_align
- dump_page_offset_table
-
- (S, Shared object hint table) table_header
- dup /S .knownget {
- hint_stream exch set_align
- dump_shared_object_table
- } {
- (Required table is not found.) error_msg
- } ifelse
-
- dup /T .knownget {
- (T, Thumbnail hint table) table_header
- hint_stream exch set_align
- dump_thumbnail_table
- } if
-
- dup /O .knownget {
- (O, Outline hint table) table_header
- hint_stream exch set_align
- dump_generic_table
- } if
-
- dup /A .knownget {
- (A, Thread information hint table) table_header
- hint_stream exch set_align
- dump_generic_table
- } if
-
- dup /E .knownget {
- (E, Named destination hint table) table_header
- hint_stream exch set_align
- dump_generic_table
- } if
-
- dup /V .knownget {
- (V, Interactive form hint table) table_header
- hint_stream exch set_align
- dump_interactive_table
- } if
-
- dup /I .knownget {
- (I, Information dictionary hint table) table_header
- hint_stream exch set_align
- dump_generic_table
- } if
-
- dup /C .knownget {
- (C, Logical structure hint table) table_header
- hint_stream exch set_align
- dump_interactive_table
- } if
-
- dup /L .knownget {
- (L, Page label hint table) table_header
- hint_stream exch set_align
- dump_generic_table
- } if
-
- pop
-} bind def
-
-
-% Load PDF file and extract the hint stream.
-/pdf_dump_hints { % <infile> pdf_dump_hints -
- dup (r) file % fname
- false exch % fname F file
- {
- dup 7 string readstring pop % fname F file ()
- (%PDF-1.) ne { pop exit } if % fname F file
- dup 0 setfileposition
- dup token not { pop exit } if % fname F file obj
- dup type /integertype ne { pop exit } if % fname F file obj
- 1 index token not { pop pop exit } if % fname F file obj gen
- dup type /integertype ne {pop pop exit}if % fname F file obj gen
- 4 2 roll % fname obj gen F file
- dup 0 setfileposition
- exch true or % fname obj gen file T
- exit
- } loop
- {
- pdfdict begin
- pdfopenfile dup begin
- 40 dict begin
- /IDict exch def
- .setsafe
-
- % Read all objects into memory.
- Trailer touch
- resolveR % fname <<>>
- dup /Linearized known {
- dup /L get % fname <<>> Len
- 3 -1 roll status not { 0 0 0 0 } if % <<>> Len
- pop pop exch pop % <<>> Len len
- eq {
- /LinearizationParams exch def
- LinearizationParams /H get
- dup length 2 eq {
- 0 get PDFoffset add PDFfile exch setfileposition
- PDFfile token pop
- PDFfile token pop
- resolveR dup true resolvestream
- /ReusableStreamDecode filter
- bitstream dup bytealign
- /hint_stream exch def
-
- dump_all_tables
- } {
- pop
- (Overflow hint stream is not supported.) =
- } ifelse
- } {
- pop
- (Wrong file length in linearization dictionary.) =
- } ifelse
- } {
- pop (The file is not linearized.) =
- } ifelse
- end % temporary dict
- end % IDict
- end
- } {
- pop
- (Input file is not a valid PDF file.) =
- } ifelse
-} bind def
-
-% Initial setup
-/dump_hints {
- counttomark 1 eq {
- exch pop
- save exch
- 3000000 setvmthreshold
- pdfoptdict begin
- pdf_dump_hints
- end
- restore
- true
- } {
- cleartomark false
- } ifelse
-} bind def
-
-/shellarguments {false} def
-(pdfopt.ps) runlibfile
-currentdict /shellarguments undef
-
-% Check for command line arguments.
-mark shellarguments {
- dump_hints not {
- (Usage: gs -dNODISPLAY -- dumphint.ps input.pdf) = flush
- } if
-} {
- pop
-} ifelse
-
-% EOF
diff --git a/Master/tlpkg/tlgs/lib/fixmswrd.pl b/Master/tlpkg/tlgs/lib/fixmswrd.pl deleted file mode 100755 index 521aaeabd4b..00000000000 --- a/Master/tlpkg/tlgs/lib/fixmswrd.pl +++ /dev/null @@ -1,206 +0,0 @@ -#!/usr/bin/perl -# $Id: fixmswrd.pl 6300 2005-12-28 19:56:24Z giles $ - -# (C) 1997 Anthony Shipman -# -# This software is provided 'as-is', without any express or implied -# warranty. In no event will the authors be held liable for any damages -# arising from the use of this software. -# -# Permission is granted to anyone to use this software for any purpose, -# including commercial applications, and to alter it and redistribute it -# freely, subject to the following restrictions: -# -# 1. The origin of this software must not be misrepresented; you must not -# claim that you wrote the original software. If you use this software -# in a product, an acknowledgment in the product documentation would be -# appreciated but is not required. -# 2. Altered source versions must be plainly marked as such, and must not be -# misrepresented as being the original software. -# 3. This notice may not be removed or altered from any source distribution. -# -# Anthony Shipman shipmana@acm.org - -# This program patches the postscript generated by MS Word printer drivers -# so that they work with ghostview 1.5. The problem is that the document -# structuring conventions are not followed by Word. The pages are supposed -# to be independent but they depend on a dictionary being opened outside -# of the pages. The erroneous structure is -# -# %%EndSetup -# NTPSOct95 begin -# %%Page: 1 1 -# <text> -# showpage -# %%Page: 2 2 -# <text> -# showpage -# ...... -# %%Trailer -# ... -# end -# %%EOF -# -# This only works if the all of the structure around the pages is preserved. -# The opening of NTPSOct95 happens outside of any structured section so -# it is never seen by ghostview. We change the structure to -# -# %%EndSetup -# %%Page: 1 1 -# NTPSOct95 begin -# <text> -# showpage -# end -# %%Page: 2 2 -# NTPSOct95 begin -# <text> -# showpage -# end -# ...... -# %%Trailer -# ... -# %%EOF -# -# That is the dictionary opening is repeated inside each page. -# -# We add a comment to the document to mark that it has been converted. -# This has the form -# %LOCALGhostviewPatched -# -# Usage: -# fixmswrd [-v] [file [output-file]] - -require 'getopts.pl'; - -#================================================================= - -$program = "fixmswrd"; - -sub usage { - die "Usage: $program [-v] [file [output-file]]\n"; -} - -#================================================================= - -&Getopts("v") || &usage; - -$verbose = $opt_v; - - -$infile = shift(@ARGV); -if ($infile) -{ - open(INFILE, $infile) || die "$program: Cannot read from $infile\n"; - $handle = "INFILE"; -} -else -{ - $handle = "STDIN"; -} - - -$outfile = shift(@ARGV); -if ($outfile) -{ - open(OUTFILE, ">$outfile") || die "$program: Cannot write to $outfile\n"; - select(OUTFILE); -} - -# This reads the header comments and detects the presence of the marker. -$have_marker = 0; - -undef $dict_name; -undef $dict_line; - -&read_comments; -&put_comments; - -if ($have_marker) -{ - $verbose && print STDERR "$program: Warning - already converted\n"; - - while(<$handle>) # pass the file through unchanged. - { - print; - } -} -else -{ - $seen_trailer = 0; - - while(<$handle>) # massage the file - { - if ($dict_line) - { - next if (/$dict_line/o); # drop the old begin line - $seen_trailer = 1 if (/^%%Trailer/); - next if ($seen_trailer and /^end/); # drop the old end line - } - - print; - - if (/^%%Page:/) - { - print "$dict_name begin\n"; # add at the start of the page - } - elsif (/^showpage/) - { - print "end\n"; # add at the end of the page - } - elsif (/^%%BeginResource: procset (\S+)/) - { - $dict_name = $1; - $dict_line = "^$dict_name begin"; - } - elsif (/^%%BeginProcSet: (\S+)/) # for older document versions - { - $dict_name = $1; - $dict_line = "^$dict_name begin"; - } - elsif (/^%%EndProlog:/) - { - unless ($dict_line) - { - $verbose && - print STDERR "$program: Warning - unrecognised document structure\n"; - } - } - } -} - -exit 0; - -#================================================================= - - -# This reads all of the header comments into an array which we can write -# out again later. In addition we detect the presence of the marker comment. - -sub read_comments -{ - @headers = (); - - while (<$handle>) - { # without chopping - push(@headers, $_); - if (/^%LOCALGhostviewPatched/) - { - $have_marker = 1; - } - last if /^%%EndComments/; - } -} - - - -sub put_comments -{ - foreach $h (@headers) - { - if (!$have_marker and ($h =~ /^%%EndComments/)) - { - print "%LOCALGhostviewPatched\n"; - } - print $h; # contains the newline - } -} diff --git a/Master/tlpkg/tlgs/lib/font2c.ps b/Master/tlpkg/tlgs/lib/font2c.ps deleted file mode 100644 index c5234d72b02..00000000000 --- a/Master/tlpkg/tlgs/lib/font2c.ps +++ /dev/null @@ -1,675 +0,0 @@ -% Copyright (C) 1992, 1993, 1994, 1995, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: font2c.ps 6300 2005-12-28 19:56:24Z giles $
-% font2c.ps
-% Write out a PostScript Type 0 or Type 1 font as C code
-% that can be linked with the interpreter.
-% This even works on protected fonts, if you use the -dWRITESYSTEMDICT
-% switch in the command line. The code is reentrant and location-
-% independent and has no external references, so it can be put into
-% a sharable library even on VMS.
-
-/font2cdict 100 dict dup begin
-
-% Define the maximum string length that all compilers will accept.
-% This must be approximately
-% min(max line length, max string literal length) / 4 - 5.
-
-/max_wcs 50 def
-
-% Define a temporary file for writing out procedures.
-/wtempname (_.tmp) def
-
-% ------ Protection utilities ------ %
-
-% Protection values are represented by a mask:
-/a_noaccess 0 def
-/a_executeonly 1 def
-/a_readonly 3 def
-/a_all 7 def
-/prot_names
- [ (0) (a_execute) null (a_readonly) null null null (a_all)
- ] def
-/prot_opers
- [ {noaccess} {executeonly} {} {readonly} {} {} {} {}
- ] def
-
-% Get the protection of an object.
- /getpa
- { dup wcheck
- { pop a_all }
- { % Check for executeonly or noaccess objects in protected.
- dup protected exch known
- { protected exch get }
- { pop a_readonly }
- ifelse
- }
- ifelse
- } bind def
-
-% Get the protection appropriate for (all the) values in a dictionary.
- /getva
- { a_noaccess exch
- { exch pop
- dup type dup /stringtype eq 1 index /arraytype eq or
- exch /packedarraytype eq or
- { getpa a_readonly and or }
- { pop pop a_all exit }
- ifelse
- }
- forall
- } bind def
-
-% Keep track of executeonly and noaccess objects,
-% but don't let the protection actually take effect.
-.currentglobal
-false .setglobal % so protected can reference local objs
-/protected % do first so // will work
- systemdict wcheck { 1500 dict } { 1 dict } ifelse
-def
-systemdict wcheck not
- { (Warning: you will not be able to convert protected fonts.\n) print
- (If you need to convert a protected font, please\n) print
- (restart the program and specify the -dWRITESYSTEMDICT switch.\n) print
- flush
- (%end) .skipeof
- }
-if
-userdict begin
- /executeonly
- { dup //protected exch //a_executeonly put readonly
- } bind def
- /noaccess
- { dup //protected exch //a_noaccess put readonly
- } bind def
-end
-true .setglobal
-systemdict begin
- /executeonly
- { userdict /executeonly get exec
- } bind odef
- /noaccess
- { userdict /noaccess get exec
- } bind odef
-end
-%end
-.setglobal
-
-% ------ Output utilities ------ %
-
-% By convention, the output file is named cfile.
-
-% Define some utilities for writing the output file.
- /wtstring 100 string def
- /wb {cfile exch write} bind def
- /ws {cfile exch writestring} bind def
- /wl {ws (\n) ws} bind def
- /wt {wtstring cvs ws} bind def
-
-% Write a C string. Some compilers have unreasonably small limits on
-% the length of a string literal or the length of a line, so every place
-% that uses wcs must either know that the string is short,
-% or be prepared to use wcca instead.
- /wbx
- { 8#1000 add 8 (0000) cvrs dup 0 (\\) 0 get put ws
- } bind def
- /wcst
- [
- 32 { /wbx load } repeat
- 95 { /wb load } repeat
- 129 { /wbx load } repeat
- ] def
- ("\\) { wcst exch { (\\) ws wb } put } forall
- /wcs
- { (") ws { dup wcst exch get exec } forall (") ws
- } bind def
- /can_wcs % Test if can use wcs
- { length max_wcs le
- } bind def
- /wncs % name -> C string
- { wtstring cvs wcs
- } bind def
-% Write a C string as an array of character values.
-% We only need this because of line and literal length limitations.
- /wca % <string> <prefix> <suffix> wca -
- { 0 4 -2 roll exch
- { % Stack: suffix n prefix char
- exch ws
- exch dup 19 ge { () wl pop 0 } if 1 add
- exch dup 32 ge 1 index 126 le and
- { 39 wb dup 39 eq 1 index 92 eq or { 92 wb } if wb 39 wb }
- { wt }
- ifelse (,)
- } forall
- pop pop ws
- } bind def
- /wcca % <string> wcca -
- { ({\n) (}) wca
- } bind def
-
-% Write object protection attributes. Note that dictionaries and arrays are
-% the only objects that can be writable.
- /wpa
- { dup xcheck { (a_executable|) ws } if
- dup type dup /dicttype eq exch /arraytype eq or
- { getpa }
- { getpa a_readonly and }
- ifelse prot_names exch get ws
- } bind def
- /wva
- { getva prot_names exch get ws
- } bind def
-
-% ------ Object writing ------ %
-
- /wnstring 128 string def
-
-% Convert an object to a string to be scanned at a later time.
- /cvos % <obj> cvos <string>
- { % We'd like to use == and write directly to a string,
- % but we can't do the former because of operators,
- % and we can't do the latter because we can't predict
- % how long the string would have to be....
- wtempname (w) file dup 3 -1 roll wproc closefile
- wtempname status pop pop pop exch pop string
- wtempname (r) file dup 3 -1 roll readstring pop exch closefile
- } bind def
-
-% Write a string/name or null as an element of a string/name/null array.
-% Convert any other kind of value to a token to be read back in.
- /wsn
- { dup null eq
- { pop (\t255,255,) wl
- }
- { dup type /nametype eq { wnstring cvs } if
- dup type /stringtype ne { cvos (255,) ws } if
- dup length 256 idiv wt (,) ws
- dup length 256 mod wt
- (,) (,\n) wca
- }
- ifelse
- } bind def
-% Write a packed string/name/null array.
- /wsna % <name> <(string|name|null)*> wsna -
- { (\tstatic const unsigned char ) ws exch wt ([] = {) wl
- { wsn } forall
- (\t0\n};) wl
- } bind def
-
-% Write a number or an array of numbers, as refs.
-/isnumber
- { type dup /integertype eq exch /realtype eq or
- } bind def
-/wnums
- { dup isnumber
- { (real_v\() ws wt (\),) ws }
- { { wnums } forall }
- ifelse
- } bind def
-
-% Test whether a procedure or unusual array can be written (printed).
-/iswx 4 dict dup begin
- /arraytype { { iswproc } isall } def
- /nametype { pop true } def
- /operatortype { pop true } def % assume it has been bound in
- /packedarraytype /arraytype load def
-end def
-/iswnx 6 dict dup begin
- /arraytype { { iswproc } isall } def
- /integertype { pop true } def
- /nametype { pop true } def
- /realtype { pop true } def
- /stringtype { pop true } def
- /packedarraytype /arraytype load def
-end def
-/iswproc % <obj> iswproc <bool>
- { dup xcheck { iswx } { iswnx } ifelse
- 1 index type .knownget { exec } { pop false } ifelse
- } bind def
-
-% Write a printable procedure (one for which iswproc returns true).
-/wproca 3 dict dup begin
- /arraytype
- { 1 index ({) writestring
- { 1 index ( ) writestring 1 index exch wproc } forall
- (}) writestring
- } bind def
- /packedarraytype /arraytype load def
- /operatortype { .writecvs } bind def % assume binding would work
-end def
-/wproc % <file> <proc> wproc -
- { dup type wproca exch .knownget { exec } { write==only } ifelse
- } bind def
-
-% Write a named object. Return true if this was possible.
-% Legal types are: boolean, integer, name, real, string,
-% array of (integer, integer+real, name, null+string),
-% and certain procedures and other arrays (see iswproc above).
-% All other objects are either handled specially or ignored.
- /isall % <array> <proc> isall <bool>
- { true 3 -1 roll
- { 2 index exec not { pop false exit } if }
- forall exch pop
- } bind def
- /wott 8 dict dup begin
- /arraytype
- { woatt
- { aload pop 2 index 2 index exec
- { exch pop exec exit }
- { pop pop }
- ifelse
- }
- forall
- } bind def
- /booleantype
- { { (\tmake_true\(&) } { (\tmake_false\(&) } ifelse ws
- wt (\);) wl true
- } bind def
- /integertype
- { (\tmake_int\(&) ws exch wt (, ) ws
- wt (\);) wl true
- } bind def
- /nametype
- { (\tcode = (*pprocs->name_create)\(i_ctx_p, &) ws exch wt
- (, ) ws wnstring cvs wcs % OK, names are short
- (\);) wl
- (\tif ( code < 0 ) return code;) wl
- true
- } bind def
- /packedarraytype
- /arraytype load def
- /realtype
- { (\tmake_real\(&) ws exch wt (, (float)) ws
- wt (\);) wl true
- } bind def
- /stringtype
- { ({\tstatic const unsigned char s_[] = ) ws
- dup dup can_wcs { wcs } { wcca } ifelse
- (;) wl
- (\tmake_const_string\(&) ws exch wt
- (, a_readonly, ) ws length wt (, (const byte *)s_\);) wl
- (}) wl true
- } bind def
- end def
-% Write some other kind of object, if known.
- /wother
- { dup otherobjs exch known
- { otherobjs exch get (\t) ws exch wt ( = ) ws wt (;) wl true }
- { pop pop false }
- ifelse
- } bind def
-% Top-level procedure.
- /wo % name obj -> OK
- { dup type wott exch .knownget { exec } { wother } ifelse
- } bind def
-
-% Write an array (called by wo).
- /wap % <name> <array> wap -
- { dup xcheck not 1 index wcheck not and 1 index rcheck and
- { pop pop }
- { (\tr_set_attrs\(&) ws exch wt (, ) ws wpa (\);) wl }
- ifelse
- } bind def
- /wnuma { % <name> <array> <element_C_type> <<type>_v> wnuma -
- ({\tstatic const ref_\() ws exch ws (\) a_[] = {) wl exch
- % Stack: name type_v array
- dup length 0 eq {
- (\t) ws 1 index ws (\(0\)) wl
- } {
- dup {
- (\t) ws 2 index ws (\() ws wt (\),) wl
- } forall
- } ifelse exch pop
- % Stack: name array
- (\t};) wl
- dup wcheck {
- (\tcode = (*pprocs->scalar_array_create)\(i_ctx_p, &) ws exch wt
- (, (const ref *)a_, ) ws dup length wt
- (, ) ws wpa (\);) wl
- (\tif ( code < 0 ) return code;) wl
- } {
- (\tmake_const_array\(&) ws exch wt
- (, avm_foreign|) ws dup wpa (, ) ws length wt
- (, (const ref *)a_\);) wl
- } ifelse
- (}) wl
- } bind def
- /woatt [
- % Integers
- { { { type /integertype eq } isall }
- { (long) (integer_v) wnuma true }
- }
- % Integers + reals
- { { { type dup /integertype eq exch /realtype eq or } isall }
- { (float) (real_v) wnuma true }
- }
- % Strings + nulls
- { { { type dup /nulltype eq exch /stringtype eq or } isall }
- { ({) ws dup (sa_) exch wsna
- (\tcode = (*pprocs->string_array_create)\(i_ctx_p, &) ws exch wt
- (, \(const char *\)sa_, ) ws dup length wt (, ) ws wpa (\);) wl
- (\tif ( code < 0 ) return code;) wl
- (}) wl true
- }
- }
- % Names
- { { { type /nametype eq } isall }
- { ({) ws dup (na_) exch wsna
- (\tcode = (*pprocs->name_array_create)\(i_ctx_p, &) ws 1 index wt
- (, \(const char *\)na_, ) ws dup length wt (\);) wl
- (\tif ( code < 0 ) return code;) wl
- wap (}) wl true
- }
- }
- % Procedure
- { { iswproc }
- { dup cvos
- % Stack: name proc string
- ({\tstatic const unsigned char s_[] = ) ws
- dup dup can_wcs { wcs } { wcca } ifelse
- (;) wl
- (\tcode = (*pprocs->ref_from_string)\(i_ctx_p, &) ws 2 index wt
- (, \(const char *\)s_, ) ws length wt (\);) wl
- (\tif ( code < 0 ) return code;) wl
- wap (}) wl true
- wtempname deletefile
- }
- }
- % Default
- { { pop true }
- { wother }
- }
- ] def
-
-% Write a named dictionary. We assume the ref is already declared.
- /wd % <name> <dict> <extra> wd -
- { 3 1 roll
- ({) ws
- (\tref v_[) ws dup length wt (];) wl
- dup [ exch
- { counttomark 2 sub wtstring cvs
- (v_[) exch concatstrings (]) concatstrings exch wo not
- { (Skipping ) print ==only (....\n) print }
- if
- } forall
- ]
- % Stack: array of keys (names)
- ({) ws dup (str_keys_) exch wsna
- (\tstatic const cfont_dict_keys keys_ =) wl
- (\t { 0, 0, ) ws length wt (, ) ws 3 -1 roll wt (, ) ws
- dup wpa (, ) ws dup wva ( };) wl pop
- (\tcode = \(*pprocs->ref_dict_create\)\(i_ctx_p, &) ws wt
- (, &keys_, \(const char *\)str_keys_, v_\);) wl
- (\tif ( code < 0 ) return code;) wl
- (}) wl
- (}) wl
- } bind def
-
-% Write character dictionary keys.
-% We save a lot of space by abbreviating keys which appear in
-% StandardEncoding or ISOLatin1Encoding.
-% Writes code to declare and initialize enc_keys_, str_keys, and keys_.
-/wcdkeys % <dict> wcdkeys -
- { % Write keys present in StandardEncoding or ISOLatin1Encoding,
- % pushing other keys on the o-stack.
- (static const charindex enc_keys_[] = {) wl
- dup [ exch 0 exch
- { pop decoding 1 index known
- { decoding exch get ({) ws dup -8 bitshift wt
- (,) ws 255 and wt (}, ) ws
- 1 add dup 5 mod 0 eq { (\n) ws } if
- }
- { exch }
- ifelse
- }
- forall pop
- ]
- ({0,0}\n};) wl
- % Write other keys.
- (str_keys_) exch wsna
- % Write the declaration for keys_.
- (static const cfont_dict_keys keys_ = {) wl
- (\tenc_keys_, countof\(enc_keys_\) - 1,) wl
- (\t) ws dup length wt ( - \(countof\(enc_keys_\) - 1\), 0, ) ws
- dup wpa (, ) ws wva () wl
- (};) wl
- } bind def
-
-% Enumerate character dictionary values in the same order that
-% the keys appear in enc_keys_ and str_keys_.
-% <proc> is called with each value in turn.
-/cdforall % <dict> <proc> cdforall -
- { 2 copy
- { decoding 3 index known
- { 3 -1 roll pop exec }
- { pop pop pop }
- ifelse
- }
- /exec cvx 3 packedarray cvx
- /forall cvx
- 5 -2 roll
- { decoding 3 index known
- { pop pop pop }
- { 3 -1 roll pop exec }
- ifelse
- }
- /exec cvx 3 packedarray cvx
- /forall cvx
- 6 packedarray cvx exec
- } bind def
-
-% ------ Writers for special objects ------ %
-
-/writespecial 10 dict dup begin
-
- /FontInfo { 0 wd } def
-
- /Private { 0 wd } def
-
- /CharStrings
- { ({) wl
- dup wcdkeys
- (static const unsigned char values_[] = {) wl
- { wsn } cdforall
- (\t0\n};) wl
- (\tcode = \(*pprocs->string_dict_create\)\(i_ctx_p, &) ws wt
- (, &keys_, (const char *)str_keys_, \(const char *\)values_\);) wl
- (\tif ( code < 0 ) return code;) wl
- (}) wl
- } bind def
-
- /Metrics
- { ({) wl
- dup wcdkeys
- (static const ref_(float) values_[] = {) wl
- dup { (\t) ws wnums () wl } cdforall
- (\t0\n};) wl
- (static const unsigned char lengths_[] = {) wl
- { (\t) ws dup isnumber
- { pop 0 }
- { length 1 add }
- ifelse wt (,) wl
- } cdforall
- (\t0\n};) wl
- (\tcode = \(*pprocs->num_dict_create\)\(i_ctx_p, &) ws wt
- (, &keys_, str_keys_, (const ref *)values_, lengths_\);) wl
- (\tif ( code < 0 ) return code;) wl
- (}) wl
- } bind def
-
- /Metrics2 /Metrics load def
-
- /FDepVector pop % (converted to a list of font names)
-
-end def
-
-% ------ The main program ------ %
-
-% Construct an inverse dictionary of encodings.
-[ /StandardEncoding /ISOLatin1Encoding
- /SymbolEncoding /DingbatsEncoding
- /KanjiSubEncoding
-]
-dup length dict begin
- { mark exch dup { .findencoding exch def } stopped cleartomark
- } forall
-currentdict end /encodingnames exch def
-
-% Invert the StandardEncoding and ISOLatin1Encoding vectors.
-512 dict begin
- 0 1 255 { dup ISOLatin1Encoding exch get exch 256 add def } for
- 0 1 255 { dup StandardEncoding exch get exch def } for
-currentdict end /decoding exch def
-
-/writefont % cfilename procname -> [writes the current font]
- { (gsf_) exch concatstrings
- /fontprocname exch def
- /cfname exch def
- /cfile cfname (w) file def
-
-% Remove unwanted keys from the font.
- currentfont dup length dict begin { def } forall
- { /FID /MIDVector /CurMID } { currentdict exch undef } forall
- /Font currentdict end def
-
-% Replace the FDepVector with a list of font names.
- Font /FDepVector .knownget
- { [ exch { /FontName get } forall ]
- Font /FDepVector 3 -1 roll put
- }
- if
-
-% Find all the special objects we know about.
-% wo uses this to write out references to otherwise intractable objects.
- /otherobjs writespecial length dict dup begin
- writespecial
- { pop Font 1 index .knownget { exch def } { pop } ifelse
- }
- forall
- end def
-
-% Define a dummy FontInfo, in case the font doesn't have one.
- /FontInfo 0 dict def
-
-% Write out the boilerplate.
- Font begin
- (/****************************************************************) wl
- ( Portions of this file are subject to the following notice(s):) wl
- systemdict /copyright get wl
- FontInfo /Notice .knownget
- { (----------------------------------------------------------------) wl wl
- } if
- (****************************************************************/) wl
- () wl
- (/* ) ws cfname ws ( */) wl
- (/* This file was created by the ) ws product ws ( font2c utility. */) wl
- () wl
- (#undef DEBUG) wl
- (#include "ccfont.h") wl
- () wl
-
-% Write the procedure prologue.
- (#ifdef __PROTOTYPES__) wl
- (ccfont_proc\() ws fontprocname ws (\);) wl
- (int) wl
- fontprocname ws ((i_ctx_t *i_ctx_p, const cfont_procs *pprocs, ref *pfont)) wl
- (#else) wl
- (int) wl
- fontprocname ws ((i_ctx_p, pprocs, pfont) i_ctx_t *i_ctx_p; const cfont_procs *pprocs; ref *pfont;) wl
- (#endif) wl
- ({\tint code;) wl
- (\tref Font;) wl
- otherobjs
- { exch pop (\tref ) ws wt (;) wl }
- forall
-
-% Write out the special objects.
- otherobjs
- { exch writespecial 2 index get exec
- }
- forall
-
-% Write out the main font dictionary.
-% If possible, substitute the encoding name for the encoding;
-% PostScript code will fix this up.
- { /Encoding /PrefEnc }
- { Font 1 index .knownget
- { encodingnames exch .knownget { def } { pop } ifelse }
- { pop }
- ifelse
- }
- forall
- (Font) Font FontType 0 eq { 5 } { 1 } ifelse wd
-
-% Finish the procedural initialization code.
- (\t*pfont = Font;) wl
- (\treturn 0;) wl
- (}) wl
- end % Font
-
- cfile closefile
-
- } bind def
-
-end def % font2cdict
-
-% Compute the procedure name from the font name.
-% Replace all non-alphanumeric characters with '_'.
-/makefontprocnamemap 256 string
- 0 1 255 { 2 copy 95 put pop } for
- (0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz)
- { 2 copy dup put pop } forall
-readonly def
-/makefontprocname % <fontname> makefontprocname <procnamestring>
- { dup length string cvs
- dup length 1 sub -1 0
- { % Stack: string index
- 2 copy 2 copy get //makefontprocnamemap exch get put pop
- }
- for
- } def
-
-/writefont { font2cdict begin writefont end } def
-
-% If the program was invoked from the command line, run it now.
-[ shellarguments
- { counttomark dup 2 eq exch 3 eq or
- { counttomark -1 roll cvn
- (Converting ) print dup =only ( font.\n) print flush
- % Ensure that we get a clean copy of the font from the
- % file system.
- 2 { % do both local and global
- currentglobal not setglobal
- dup undefinefont
- } repeat
- findfont setfont
- (FontName is ) print currentfont /FontName get ==only (.\n) print flush
- counttomark 1 eq
- { % Construct the procedure name from the file name.
- currentfont /FontName get makefontprocname
- }
- if
- writefont
- (Done.\n) print flush
- }
- { cleartomark
- (Usage: font2c fontname cfilename.c [shortname]\n) print
- ( e.g.: font2c Courier cour.c\n) print flush
- mark
- }
- ifelse
- }
-if pop
diff --git a/Master/tlpkg/tlgs/lib/font2pcl.ps b/Master/tlpkg/tlgs/lib/font2pcl.ps deleted file mode 100644 index 8da03b0f85f..00000000000 --- a/Master/tlpkg/tlgs/lib/font2pcl.ps +++ /dev/null @@ -1,603 +0,0 @@ -% Copyright (C) 1993, 1994, 1995, 1997 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: font2pcl.ps 6300 2005-12-28 19:56:24Z giles $
-% font2pcl.ps
-% Write out a font as a PCL bitmap font.
-
-/pcldict 60 dict def
-
-% Write out the current font as a PCL bitmap font.
-% The current transformation matrix defines the font size and orientation.
-
-/WriteResolution? false def % true=use "resolution bound font" format,
- % false=use older format
-
-/LJ4 false def % true=use LJ4 Typeface code
- % false=use LJIIP/IID/IIIx Typeface code
-
-pcldict begin % internal procedures
-
-/findstring % <string> <substring> findstring <bool>
- { search { pop pop pop true } { pop false } ifelse
- } def
-
- % Determine which set of keywords is present in a string.
- % The last keyword set must be empty.
-
-/keysearch % <string> <array of arrays of keywords> keysearch <index>
- { 0 1 2 index length 1 sub
- { 2 copy get true exch
- { % Stack: <string> <a.a.k.> <index> <bool> <keyword>
- 4 index exch findstring and
- }
- forall
- { 0 exch getinterval exit
- }
- if pop
- }
- for
- exch pop length % invalid index if missing
- } def
-
- % Determine the device height of a string in quarter-dots.
-
-/charheight % <string> charheight <int>
- { gsave newpath 0 0 moveto false charpath
- pathbbox exch pop exch sub exch pop 0 exch grestore
- dtransform add abs 4 mul cvi
- } def
-
- % Compute an integer version of the transformed FontBBox.
-
-/inflate % <num> inflate <num>
- { dup 0 gt { ceiling } { floor } ifelse
- } def
-/ixbbox % - ixbbox <llx> <lly> <urx> <ury>
- { /FontBBox load aload pop % might be executable or literal
- 4 2 roll transform exch truncate cvi exch truncate cvi
- 4 2 roll transform exch inflate cvi exch inflate cvi
- } def
-
- % Determine the original font of a possibly transformed font.
- % Since some badly behaved PostScript files construct transformed
- % fonts "by hand", we can't just rely on the OrigFont pointers.
- % Instead, if a font with the given name exists, and if its
- % entries for FontType and UniqueID match those of the font we
- % obtain by following the OrigFont chain, we use that font.
-
-/origfont
- { { dup /OrigFont known not { exit } if /OrigFont get } loop
- FontDirectory 1 index /FontName get .knownget
- { % Stack: origfont namedfont
- 1 index /FontType get 1 index /FontType get eq
- { 1 index /UniqueID .knownget
- { 1 index /UniqueID .knownget
- { eq { exch } if }
- { pop }
- ifelse
- }
- if
- }
- if pop
- }
- if
- } def
-
-
- % Determine the bounding box of the current device's image.
- % Free variables: row, zerow.
-
-/devbbox % <rw> <rh> devbbox <ymin> <ymax1> <xmin> <xmax1>
- { % Find top and bottom whitespace.
- dup
- { dup 0 eq { exit } if 1 sub
- dup currentdevice exch row copyscanlines
- zerow ne { 1 add exit } if
- }
- loop % ymax1
- 0
- { 2 copy eq { exit } if
- dup currentdevice exch row copyscanlines
- zerow ne { exit } if
- 1 add
- }
- loop % ymin
- exch
- % Find left and right whitespace.
- 3 index 0
- % Stack: rw rh ymin ymax1 xmin xmax1
- 3 index 1 4 index 1 sub
- { currentdevice exch row copyscanlines .findzeros
- exch 4 1 roll .max 3 1 roll .min exch
- }
- for % xmin xmax1
- % Special check: xmin > xmax1 if height = 0
- 2 copy gt { exch pop dup } if
- 6 -2 roll pop pop
-
- } def
-
- % Write values on outfile.
-
- /w1 { 255 and outfile exch write } def
- /w2 { dup -8 bitshift w1 w1 } def
- /wbyte % <byte> <label> wbyte
- { VDEBUG { print ( =byte= ) print dup == flush } { pop } ifelse w1
- } def
- /wword % <word16> <label> wword
- { VDEBUG { print ( =word= ) print dup == flush } { pop } ifelse w2
- } def
- /wdword % <word32> <label> wdword
- { VDEBUG { print ( =dword= ) print dup == flush } { pop } ifelse
- dup -16 bitshift w2 w2
- } def
-
-/style.posture.keys
- [ { (Italic) } { (Oblique) }
- { }
- ] def
-/style.posture.values <010100> def
-
-/style.appearance.width.keys
- [ { (Ultra) (Compressed) }
- { (Extra) (Compressed) }
- { (Extra) (Condensed) }
- { (Extra) (Extended) }
- { (Extra) (Expanded) }
- { (Compressed) }
- { (Condensed) }
- { (Extended) }
- { (Expanded) }
- { }
- ] def
-/style.appearance.width.values <04030207070201060600> def
-
-/width.type.keys
- [ { (Ultra) (Compressed) }
- { (Extra) (Compressed) }
- { (Extra) (Condensed) }
- { (Extra) (Expanded) }
- { (Compressed) }
- { (Condensed) }
- { (Expanded) }
- { }
- ] def
-/width.type.values <fbfcfd03fdfe0200> def
-
-/stroke.weight.keys
- [ { (Ultra) (Thin) }
- { (Ultra) (Black) }
- { (Extra) (Thin) }
- { (Extra) (Light) }
- { (Extra) (Bold) }
- { (Extra) (Black) }
- { (Demi) (Light) }
- { (Demi) (Bold) }
- { (Semi) (Light) }
- { (Semi) (Bold) }
- { (Thin) }
- { (Light) }
- { (Bold) }
- { (Black) }
- { }
- ] def
-/stroke.weight.values <f907fafc0406fe02ff01fbfd030500> def
-
-/vendor.keys
- [ { (Agfa) }
- { (Bitstream) }
- { (Linotype) }
- { (Monotype) }
- { (Adobe) }
- { }
- ] def
-/vendor.default.index 4 def % might as well be Adobe
-/old.vendor.values <020406080a00> def
-/new.vendor.values <010203040500> def
-/vendor.initials (CBLMA\000) def
-
-currentdict readonly end pop % pcldict
-
-
-% Convert and write a PCL font for the current font and transformation.
-
-% Write the font header. We split this off only to avoid overflowing
-% the limit on the maximum size of a procedure.
-% Free variables: outfile uury u0y rw rh orientation uh ully
-/writefontheader
- { outfile (\033\)s) writestring
- outfile 64 WriteResolution? { 4 add } if
- Copyright length add write==only
- outfile (W) writestring
- WriteResolution? { 20 68 } { 0 64 } ifelse
- (Font Descriptor Size) wword
- (Header Format) wbyte
- 1 (Font Type) wbyte
- FullName style.posture.keys keysearch style.posture.values exch get
- FullName style.appearance.width.keys keysearch
- style.appearance.width.values exch get 4 mul add
- PaintType 2 eq { 32 add } if
- /style exch def
- style -8 bitshift (Style MSB) wbyte
- 0 (Reserved) wbyte
- /baseline uury 1 sub u0y sub def
- baseline (Baseline Position) wword
- rw (Cell Width) wword
- rh (Cell Height) wword
- orientation (Orientation) wbyte
- FontInfo /isFixedPitch .knownget not { false } if
- { 0 } { 1 } ifelse (Spacing) wbyte
- % Use loop/exit to fake a multiple-exit block.
- { Encoding StandardEncoding eq { 10 (J) exit } if
- Encoding ISOLatin1Encoding eq { 11 (J) exit } if
- Encoding SymbolEncoding eq { 19 (M) exit } if
- Encoding DingbatsEncoding eq { 10 (L) exit } if
-% (Warning: unknown Encoding, using ISOLatin1.\n) print flush
- 11 (J) exit
- }
- loop
- 0 get 64 sub exch 32 mul add (Symbol Set) wword
- ( ) stringwidth pop 0 dtransform add abs 4 mul
- /pitch exch def
- pitch cvi (Pitch) wword
- uh 4 mul (Height) wword % Height
- (x) charheight (x-Height) wword
- FullName width.type.keys keysearch
- width.type.values exch get (Width Type) wbyte
- style 255 and (Style LSB) wbyte
- FullName stroke.weight.keys keysearch
- stroke.weight.values exch get (Stroke Weight) wbyte
- FullName vendor.keys keysearch
- dup vendor.initials exch get 0 eq
- { % No vendor in FullName, try Notice
- pop Copyright vendor.keys keysearch
- dup vendor.initials exch get 0 eq { pop vendor.default.index } if
- }
- if
- /vendor.index exch def
- 0 (Typeface LSB) wbyte % punt
- 0 (Typeface MSB) wbyte % punt
- 0 (Serif Style) wbyte % punt
- 2 (Quality) wbyte
- 0 (Placement) wbyte
- gsave FontMatrix concat rot neg rotate
- /ulwidth
- FontInfo /UnderlineThickness .knownget
- { 0 exch dtransform exch pop abs }
- { resolution 100 div }
- ifelse def
- FontInfo /UnderlinePosition .knownget
- { 0 exch transform exch pop negY ulwidth 2 div add }
- { ully ulwidth add }
- ifelse u0y sub
- round cvi 1 .max 255 .min (Underline Position) wbyte
- ulwidth round cvi 1 .max 255 .min (Underline Thickness) wbyte
- grestore
- uh 1.2 mul 4 mul cvi (Text Height) wword
- (average lowercase character) dup stringwidth
- pop 0 dtransform add abs
- exch length div 4 mul cvi (Text Width) wword
- 0
- { dup Encoding exch get /.notdef ne { exit } if
- 1 add
- }
- loop (First Code) wword
- 255
- { dup Encoding exch get /.notdef ne { exit } if
- 1 sub
- }
- loop (Last Code) wword
- pitch dup cvi sub 256 mul cvi (Pitch Extended) wbyte
- 0 (Height Extended) wbyte
- 0 (Cap Height) wword % (default)
- currentfont /UniqueID known { UniqueID } { 0 } ifelse
- 16#c1000000 add (Font Number (Adobe UniqueID)) wdword
- FontName length 16 .max string
- dup FontName exch cvs pop
- outfile exch 0 16 getinterval writestring % Font Name
- WriteResolution?
- { resolution dup (X Resolution) wword (Y Resolution) wword
- }
- if
- outfile Copyright writestring % Copyright
- } def
-
-/writePCL % <fontfile> <resolution> writePCL -
- {
- save
- currentfont begin
- pcldict begin
- 80 dict begin % allow for recursion
- /saved exch def
- /resolution exch def
- /outfile exch def
- matrix currentmatrix dup 4 0 put dup 5 0 put setmatrix
-
- % Supply some default values so we don't have to check later.
-
- currentfont /FontInfo known not { /FontInfo 1 dict def } if
- currentfont /FontName known not { /FontName () def } if
- /Copyright FontInfo /Notice .knownget not { () } if def
- /FullName
- FontInfo /FullName .knownget not
- { FontName dup length string cvs }
- if def
-
- % Determine the original font, and its relationship to this one.
-
- /OrigFont currentfont origfont def
- /OrigMatrix OrigFont /FontMatrix get def
- /OrigMatrixInverse OrigMatrix matrix invertmatrix def
- /ScaleMatrix matrix currentfont OrigFont ne
- { FontMatrix exch OrigMatrixInverse exch concatmatrix
- } if
- def
- /CurrentScaleMatrix
- matrix currentmatrix
- matrix defaultmatrix
- dup 0 get 1 index 3 get mul 0 lt
- 1 index dup 1 get exch 2 get mul 0 gt or
- /flipY exch def
- dup invertmatrix
- dup concatmatrix
- def
- /negY flipY { {neg} } { {} } ifelse def
-
- % Print debugging information.
-
- /CDEBUG where { pop } { /CDEBUG false def } ifelse
- /VDEBUG where { pop } { /VDEBUG false def } ifelse
- CDEBUG { /VDEBUG true def } if
- DEBUG
- { (currentmatrix: ) print matrix currentmatrix ==
- (defaultmatrix: ) print matrix defaultmatrix ==
- (flipY: ) print flipY ==
- (scaling matrix: ) print CurrentScaleMatrix ==
- (FontMatrix: ) print FontMatrix ==
- (FontBBox: ) print /FontBBox load ==
- currentfont OrigFont ne
- { OrigFont /FontName .knownget { (orig FontName: ) print == } if
- (orig FontMatrix: ) print OrigMatrix ==
- } if
- currentfont /ScaleMatrix .knownget { (ScaleMatrix: ) print == } if
- gsave
- FontMatrix concat
- (combined matrix: ) print matrix currentmatrix ==
- grestore
- flush
- } if
-
- % Determine the orientation.
-
- ScaleMatrix matrix currentmatrix dup concatmatrix
- 0 1 3
- { 1 index 1 get 0 eq 2 index 2 get 0 eq and 2 index 0 get 0 gt and
- { exit } if
- pop -90 matrix rotate exch dup concatmatrix
- }
- for
- dup type /integertype ne
- { (Only rotations by multiples of 90 degrees are supported:\n) print
- == flush
- saved end end end restore stop
- }
- if
- /orientation exch def
- /rot orientation 90 mul def
- DEBUG { (orientation: ) print orientation == flush } if
-
- dup dup 0 get exch 3 get negY sub abs 0.5 ge
- { (Only identical scaling in X and Y is supported:\n) print
- exch flipY 3 array astore ==
- currentdevice .devicename ==
- matrix defaultmatrix == flush
- saved end end end restore stop
- }
- if pop
-
- % Determine the font metrics, in the PCL character coordinate system,
- % which has +Y going towards the top of the page.
-
- gsave
- FontMatrix concat
- 0 0 transform
- negY round cvi /r0y exch def
- round cvi /r0x exch def
- ixbbox
- negY /rury exch def /rurx exch def
- negY /rlly exch def /rllx exch def
- /rminx rllx rurx .min def
- /rminy rlly negY rury negY .min def
- /rw rurx rllx sub abs def
- /rh rury rlly sub abs def
- gsave rot neg rotate
- 0 0 transform
- negY round cvi /u0y exch def
- round cvi /u0x exch def
- ixbbox
- negY /uury exch def /uurx exch def
- negY /ully exch def /ullx exch def
- /uw uurx ullx sub def
- /uh uury ully sub def
- grestore
- DEBUG
- { (rmatrix: ) print matrix currentmatrix ==
- (rFontBBox: ) print [rllx rlly rurx rury] ==
- (uFontBBox: ) print [ullx ully uurx uury] ==
- flush
- } if
- grestore
-
- % Disable the character cache, to avoid excessive allocation
- % and memory sandbars.
-
- mark cachestatus /upper exch def
- cleartomark 0 setcachelimit
-
- % Write the font header.
-
- writefontheader
-
- % Establish an image device for rasterizing characters.
-
- matrix currentmatrix
- dup 4 rminx neg put
- dup 5 rminy neg put
- % Round the width up to a multiple of 8
- % so we don't get garbage bits in the last byte of each row.
- rw 7 add -8 and rh <ff 00> makeimagedevice
- /cdevice exch def
- nulldevice % prevent page device switching
- cdevice setdevice
-
- % Rasterize each character in turn.
-
- /raster rw 7 add 8 idiv def
- /row raster string def
- /zerow row length string def
- 0 1 Encoding length 1 sub
- { /cindex exch def
- Encoding cindex get /.notdef ne
- { VDEBUG { Encoding cindex get == flush } if
- erasepage initgraphics
- 0 0 moveto currentpoint transform add
- ( ) dup 0 cindex put show
- currentpoint transform add exch sub round cvi
- /cwidth exch abs def
- rw rh devbbox
- VDEBUG
- { (image bbox: ) print 4 copy 4 2 roll 4 array astore == flush
- } if
- % Save the device bounding box.
- % Note that this is in current device coordinates,
- % not PCL (right-handed) coordinates.
- /bqx exch def /bpx exch def /bqy exch def /bpy exch def
- % Re-render with the character justified to (0,0).
- % This may be either the lower left or the upper left corner.
- bpx neg bpy neg idtransform moveto
- erasepage
- VDEBUG { (show point: ) print [ currentpoint transform ] == flush } if
- ( ) dup 0 cindex put show
- % Find the bounding box. Note that xmin and ymin are now 0,
- % xmax1 = xw, and ymax1 = yh.
- rw rh devbbox
- /xw exch def
- % xmin or ymin can be non-zero only if the character is blank.
- xw 0 eq
- { pop }
- { dup 0 ne { (Non-zero xmin! ) print = } { pop } ifelse }
- ifelse
- /yh exch def
- yh 0 eq
- { pop }
- { dup 0 ne { (Non-zero ymin! ) print = } { pop } ifelse }
- ifelse
-
- /xbw xw 7 add 8 idiv def
- /xright raster 8 mul xw sub def
- % Write the Character Code command.
- outfile (\033*c) writestring
- outfile cindex write==only
- outfile (E) writestring
- % Write the Character Definition command.
- outfile (\033\(s) writestring
- yh xbw mul 16 add
- outfile exch write=only
- % Record the character position for the .PCM file.
- /cfpos outfile fileposition 1 add def
- outfile (W\004\000\016\001) writestring
- orientation (Orientation) wbyte 0 (Reserved) wbyte
- rminx bpx add r0x sub (Left Offset) wword
- flipY { rminy bpy add neg } { rminy bqy add } ifelse r0y sub
- (Top Offset) wword
- xw (Character Width) wword
- yh (Character Height) wword
- cwidth orientation 2 ge { neg } if 4 mul (Delta X) wword
- % Write the character data.
- flipY { 0 1 yh 1 sub } { yh 1 sub -1 0 } ifelse
- { cdevice exch row copyscanlines
- 0 xbw getinterval
- CDEBUG
- { dup
- { 8
- { dup 128 ge { (+) } { (.) } ifelse print
- 127 and 1 bitshift
- }
- repeat pop
- }
- forall (\n) print
- }
- if
- outfile exch writestring
- }
- for
- }
- { /bpx 0 def /bpy 0 def /bqx 0 def /bqy 0 def
- /cwidth 0 def
- /cfpos 0 def
- }
- ifelse
-
- }
- for
-
- % Wrap up.
-
- upper setcachelimit
- outfile closefile
-
- nulldevice % prevent page device switching
- saved end end end restore
-
- } def
-
-% Provide definitions for testing with older or non-custom interpreters.
-
-/.findzeros where { pop (%END) .skipeof } if
-/.findzeros
- { userdict begin /zs exch def /zl zs length def
- 0 { dup zl ge { exit } if dup zs exch get 0 ne { exit } if 1 add } loop
- zl { dup 0 eq { exit } if dup 1 sub zs exch get 0 ne { exit } if 1 sub } loop
- exch 3 bitshift exch 3 bitshift
- 2 copy lt
- { exch zs 1 index -3 bitshift get
- { dup 16#80 and 0 ne { exit } if exch 1 add exch 1 bitshift } loop pop
- exch zs 1 index -3 bitshift 1 sub get
- { dup 1 and 0 ne { exit } if exch 1 sub exch -1 bitshift } loop pop
- }
- if end
- } bind def
-%END
-
-/write=only where { pop (%END) .skipeof } if
-/w=s 128 string def
-/write=only
- { w=s cvs writestring
- } bind def
-%END
-
-%**************** Test
-/PCLTEST where {
- pop
- /DEBUG true def
- /CDEBUG true def
- /VDEBUG true def
- /Times-Roman findfont 10 scalefont setfont
- (t.pcf) (w) file
- 300 72 div dup scale
- 300 writePCL
- flush quit
-} if
diff --git a/Master/tlpkg/tlgs/lib/ghostpdf.inf b/Master/tlpkg/tlgs/lib/ghostpdf.inf deleted file mode 100644 index a3536f7c6c3..00000000000 --- a/Master/tlpkg/tlgs/lib/ghostpdf.inf +++ /dev/null @@ -1,44 +0,0 @@ -; GHOSTPDF.INF (for Windows 2k, XP and XP x64 edition) - -[Version] -Signature="$Windows NT$" -Provider=Ghostgum Software Pty Ltd -ClassGUID={4D36E979-E325-11CE-BFC1-08002BE10318} -Class=Printer -CatalogFile=oemprint.cat - -DriverVer=01/02/2007,1.0.0.1 - -; Manufacturer section -[Manufacturer] -"Ghostscript"=Ghostscript,NTamd64,NTia64 - -; Model sections -[Ghostscript] -"Ghostscript PDF" = GHOSTPDF.PPD, Ghostscript_PDF, Ghostscript_PDF_Writer - -[Ghostscript.NTamd64] -"Ghostscript PDF" = GHOSTPDF.PPD, Ghostscript_PDF, Ghostscript_PDF_Writer - -[Ghostscript.NTia64] -"Ghostscript PDF" = GHOSTPDF.PPD, Ghostscript_PDF, Ghostscript_PDF_Writer - -; Installer section -[GHOSTPDF.PPD] -CopyFiles=@GHOSTPDF.PPD -DataSection=PSCRIPT_DATA -Include=NTPRINT.INF -Needs=PSCRIPT.OEM - -[DestinationDirs] -DefaultDestDir=66000 - -[SourceDisksNames] -1=%Disk1%,,,"" - -[SourceDisksFiles] -GHOSTPDF.PPD =1 - -[Strings] -Disk1="Ghostscript PPD Setup Disk 1" -; end of ghostpdf.inf diff --git a/Master/tlpkg/tlgs/lib/gs_agl.ps b/Master/tlpkg/tlgs/lib/gs_agl.ps deleted file mode 100644 index 1cf0b5e858e..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_agl.ps +++ /dev/null @@ -1,1069 +0,0 @@ -% Copyright (C) 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_agl.ps 8178 2007-08-05 13:55:26Z leonardo $
-
-% This file was derived from the Adobe Glyph List, version 1.2, dated
-% 22 Oct 1998, at
-% http://partners.adobe.com/asn/developer/typeforum/glyphlist.txt
-% That file does not contain any copyright notice.
-
-% The AdobeGlyphList dictionary maps glyph names to Unicode values.
-% Nearly all names map to a single value; however, a few names map to
-% multiple values. See the above file, and also
-% http://www.adobe.com/devnet/opentype/archives/glyph.html
-% for more details.
-
-/AdobeGlyphList 1500 dict
-dup /A 16#0041 put
-dup /AE 16#00C6 put
-dup /AEacute 16#01FC put
-dup /AEsmall 16#F7E6 put
-dup /Aacute 16#00C1 put
-dup /Aacutesmall 16#F7E1 put
-dup /Abreve 16#0102 put
-dup /Acircumflex 16#00C2 put
-dup /Acircumflexsmall 16#F7E2 put
-dup /Acute 16#F6C9 put
-dup /Acutesmall 16#F7B4 put
-dup /Adieresis 16#00C4 put
-dup /Adieresissmall 16#F7E4 put
-dup /Agrave 16#00C0 put
-dup /Agravesmall 16#F7E0 put
-dup /Alpha 16#0391 put
-dup /Alphatonos 16#0386 put
-dup /Amacron 16#0100 put
-dup /Aogonek 16#0104 put
-dup /Aring 16#00C5 put
-dup /Aringacute 16#01FA put
-dup /Aringsmall 16#F7E5 put
-dup /Asmall 16#F761 put
-dup /Atilde 16#00C3 put
-dup /Atildesmall 16#F7E3 put
-dup /B 16#0042 put
-dup /Beta 16#0392 put
-dup /Brevesmall 16#F6F4 put
-dup /Bsmall 16#F762 put
-dup /C 16#0043 put
-dup /Cacute 16#0106 put
-dup /Caron 16#F6CA put
-dup /Caronsmall 16#F6F5 put
-dup /Ccaron 16#010C put
-dup /Ccedilla 16#00C7 put
-dup /Ccedillasmall 16#F7E7 put
-dup /Ccircumflex 16#0108 put
-dup /Cdotaccent 16#010A put
-dup /Cedillasmall 16#F7B8 put
-dup /Chi 16#03A7 put
-dup /Circumflexsmall 16#F6F6 put
-dup /Csmall 16#F763 put
-dup /D 16#0044 put
-dup /Dcaron 16#010E put
-dup /Dcroat 16#0110 put
-dup /Delta [16#2206 16#0394] put
-dup /Dieresis 16#F6CB put
-dup /DieresisAcute 16#F6CC put
-dup /DieresisGrave 16#F6CD put
-dup /Dieresissmall 16#F7A8 put
-dup /Dotaccentsmall 16#F6F7 put
-dup /Dsmall 16#F764 put
-dup /E 16#0045 put
-dup /Eacute 16#00C9 put
-dup /Eacutesmall 16#F7E9 put
-dup /Ebreve 16#0114 put
-dup /Ecaron 16#011A put
-dup /Ecircumflex 16#00CA put
-dup /Ecircumflexsmall 16#F7EA put
-dup /Edieresis 16#00CB put
-dup /Edieresissmall 16#F7EB put
-dup /Edotaccent 16#0116 put
-dup /Egrave 16#00C8 put
-dup /Egravesmall 16#F7E8 put
-dup /Emacron 16#0112 put
-dup /Eng 16#014A put
-dup /Eogonek 16#0118 put
-dup /Epsilon 16#0395 put
-dup /Epsilontonos 16#0388 put
-dup /Esmall 16#F765 put
-dup /Eta 16#0397 put
-dup /Etatonos 16#0389 put
-dup /Eth 16#00D0 put
-dup /Ethsmall 16#F7F0 put
-dup /Euro 16#20AC put
-dup /F 16#0046 put
-dup /Fsmall 16#F766 put
-dup /G 16#0047 put
-dup /Gamma 16#0393 put
-dup /Gbreve 16#011E put
-dup /Gcaron 16#01E6 put
-dup /Gcircumflex 16#011C put
-dup /Gcommaaccent 16#0122 put
-dup /Gdotaccent 16#0120 put
-dup /Grave 16#F6CE put
-dup /Gravesmall 16#F760 put
-dup /Gsmall 16#F767 put
-dup /H 16#0048 put
-dup /H18533 16#25CF put
-dup /H18543 16#25AA put
-dup /H18551 16#25AB put
-dup /H22073 16#25A1 put
-dup /Hbar 16#0126 put
-dup /Hcircumflex 16#0124 put
-dup /Hsmall 16#F768 put
-dup /Hungarumlaut 16#F6CF put
-dup /Hungarumlautsmall 16#F6F8 put
-dup /I 16#0049 put
-dup /IJ 16#0132 put
-dup /Iacute 16#00CD put
-dup /Iacutesmall 16#F7ED put
-dup /Ibreve 16#012C put
-dup /Icircumflex 16#00CE put
-dup /Icircumflexsmall 16#F7EE put
-dup /Idieresis 16#00CF put
-dup /Idieresissmall 16#F7EF put
-dup /Idotaccent 16#0130 put
-dup /Ifraktur 16#2111 put
-dup /Igrave 16#00CC put
-dup /Igravesmall 16#F7EC put
-dup /Imacron 16#012A put
-dup /Iogonek 16#012E put
-dup /Iota 16#0399 put
-dup /Iotadieresis 16#03AA put
-dup /Iotatonos 16#038A put
-dup /Ismall 16#F769 put
-dup /Itilde 16#0128 put
-dup /J 16#004A put
-dup /Jcircumflex 16#0134 put
-dup /Jsmall 16#F76A put
-dup /K 16#004B put
-dup /Kappa 16#039A put
-dup /Kcommaaccent 16#0136 put
-dup /Ksmall 16#F76B put
-dup /L 16#004C put
-dup /LL 16#F6BF put
-dup /Lacute 16#0139 put
-dup /Lambda 16#039B put
-dup /Lcaron 16#013D put
-dup /Lcommaaccent 16#013B put
-dup /Ldot 16#013F put
-dup /Lslash 16#0141 put
-dup /Lslashsmall 16#F6F9 put
-dup /Lsmall 16#F76C put
-dup /M 16#004D put
-dup /Macron 16#F6D0 put
-dup /Macronsmall 16#F7AF put
-dup /Msmall 16#F76D put
-dup /Mu 16#039C put
-dup /N 16#004E put
-dup /Nacute 16#0143 put
-dup /Ncaron 16#0147 put
-dup /Ncommaaccent 16#0145 put
-dup /Nsmall 16#F76E put
-dup /Ntilde 16#00D1 put
-dup /Ntildesmall 16#F7F1 put
-dup /Nu 16#039D put
-dup /O 16#004F put
-dup /OE 16#0152 put
-dup /OEsmall 16#F6FA put
-dup /Oacute 16#00D3 put
-dup /Oacutesmall 16#F7F3 put
-dup /Obreve 16#014E put
-dup /Ocircumflex 16#00D4 put
-dup /Ocircumflexsmall 16#F7F4 put
-dup /Odieresis 16#00D6 put
-dup /Odieresissmall 16#F7F6 put
-dup /Ogoneksmall 16#F6FB put
-dup /Ograve 16#00D2 put
-dup /Ogravesmall 16#F7F2 put
-dup /Ohorn 16#01A0 put
-dup /Ohungarumlaut 16#0150 put
-dup /Omacron 16#014C put
-dup /Omega [16#2126 16#03A9] put
-dup /Omegatonos 16#038F put
-dup /Omicron 16#039F put
-dup /Omicrontonos 16#038C put
-dup /Oslash 16#00D8 put
-dup /Oslashacute 16#01FE put
-dup /Oslashsmall 16#F7F8 put
-dup /Osmall 16#F76F put
-dup /Otilde 16#00D5 put
-dup /Otildesmall 16#F7F5 put
-dup /P 16#0050 put
-dup /Phi 16#03A6 put
-dup /Pi 16#03A0 put
-dup /Psi 16#03A8 put
-dup /Psmall 16#F770 put
-dup /Q 16#0051 put
-dup /Qsmall 16#F771 put
-dup /R 16#0052 put
-dup /Racute 16#0154 put
-dup /Rcaron 16#0158 put
-dup /Rcommaaccent 16#0156 put
-dup /Rfraktur 16#211C put
-dup /Rho 16#03A1 put
-dup /Ringsmall 16#F6FC put
-dup /Rsmall 16#F772 put
-dup /S 16#0053 put
-dup /SF010000 16#250C put
-dup /SF020000 16#2514 put
-dup /SF030000 16#2510 put
-dup /SF040000 16#2518 put
-dup /SF050000 16#253C put
-dup /SF060000 16#252C put
-dup /SF070000 16#2534 put
-dup /SF080000 16#251C put
-dup /SF090000 16#2524 put
-dup /SF100000 16#2500 put
-dup /SF110000 16#2502 put
-dup /SF190000 16#2561 put
-dup /SF200000 16#2562 put
-dup /SF210000 16#2556 put
-dup /SF220000 16#2555 put
-dup /SF230000 16#2563 put
-dup /SF240000 16#2551 put
-dup /SF250000 16#2557 put
-dup /SF260000 16#255D put
-dup /SF270000 16#255C put
-dup /SF280000 16#255B put
-dup /SF360000 16#255E put
-dup /SF370000 16#255F put
-dup /SF380000 16#255A put
-dup /SF390000 16#2554 put
-dup /SF400000 16#2569 put
-dup /SF410000 16#2566 put
-dup /SF420000 16#2560 put
-dup /SF430000 16#2550 put
-dup /SF440000 16#256C put
-dup /SF450000 16#2567 put
-dup /SF460000 16#2568 put
-dup /SF470000 16#2564 put
-dup /SF480000 16#2565 put
-dup /SF490000 16#2559 put
-dup /SF500000 16#2558 put
-dup /SF510000 16#2552 put
-dup /SF520000 16#2553 put
-dup /SF530000 16#256B put
-dup /SF540000 16#256A put
-dup /Sacute 16#015A put
-dup /Scaron 16#0160 put
-dup /Scaronsmall 16#F6FD put
-dup /Scedilla [16#015E 16#F6C1] put
-dup /Scircumflex 16#015C put
-dup /Scommaaccent 16#0218 put
-dup /Sigma 16#03A3 put
-dup /Ssmall 16#F773 put
-dup /T 16#0054 put
-dup /Tau 16#03A4 put
-dup /Tbar 16#0166 put
-dup /Tcaron 16#0164 put
-dup /Tcommaaccent [16#0162 16#021A] put
-dup /Theta 16#0398 put
-dup /Thorn 16#00DE put
-dup /Thornsmall 16#F7FE put
-dup /Tildesmall 16#F6FE put
-dup /Tsmall 16#F774 put
-dup /U 16#0055 put
-dup /Uacute 16#00DA put
-dup /Uacutesmall 16#F7FA put
-dup /Ubreve 16#016C put
-dup /Ucircumflex 16#00DB put
-dup /Ucircumflexsmall 16#F7FB put
-dup /Udieresis 16#00DC put
-dup /Udieresissmall 16#F7FC put
-dup /Ugrave 16#00D9 put
-dup /Ugravesmall 16#F7F9 put
-dup /Uhorn 16#01AF put
-dup /Uhungarumlaut 16#0170 put
-dup /Umacron 16#016A put
-dup /Uogonek 16#0172 put
-dup /Upsilon 16#03A5 put
-dup /Upsilon1 16#03D2 put
-dup /Upsilondieresis 16#03AB put
-dup /Upsilontonos 16#038E put
-dup /Uring 16#016E put
-dup /Usmall 16#F775 put
-dup /Utilde 16#0168 put
-dup /V 16#0056 put
-dup /Vsmall 16#F776 put
-dup /W 16#0057 put
-dup /Wacute 16#1E82 put
-dup /Wcircumflex 16#0174 put
-dup /Wdieresis 16#1E84 put
-dup /Wgrave 16#1E80 put
-dup /Wsmall 16#F777 put
-dup /X 16#0058 put
-dup /Xi 16#039E put
-dup /Xsmall 16#F778 put
-dup /Y 16#0059 put
-dup /Yacute 16#00DD put
-dup /Yacutesmall 16#F7FD put
-dup /Ycircumflex 16#0176 put
-dup /Ydieresis 16#0178 put
-dup /Ydieresissmall 16#F7FF put
-dup /Ygrave 16#1EF2 put
-dup /Ysmall 16#F779 put
-dup /Z 16#005A put
-dup /Zacute 16#0179 put
-dup /Zcaron 16#017D put
-dup /Zcaronsmall 16#F6FF put
-dup /Zdotaccent 16#017B put
-dup /Zeta 16#0396 put
-dup /Zsmall 16#F77A put
-dup /a 16#0061 put
-dup /aacute 16#00E1 put
-dup /abreve 16#0103 put
-dup /acircumflex 16#00E2 put
-dup /acute 16#00B4 put
-dup /acutecomb 16#0301 put
-dup /adieresis 16#00E4 put
-dup /ae 16#00E6 put
-dup /aeacute 16#01FD put
-dup /afii00208 16#2015 put
-dup /afii10017 16#0410 put
-dup /afii10018 16#0411 put
-dup /afii10019 16#0412 put
-dup /afii10020 16#0413 put
-dup /afii10021 16#0414 put
-dup /afii10022 16#0415 put
-dup /afii10023 16#0401 put
-dup /afii10024 16#0416 put
-dup /afii10025 16#0417 put
-dup /afii10026 16#0418 put
-dup /afii10027 16#0419 put
-dup /afii10028 16#041A put
-dup /afii10029 16#041B put
-dup /afii10030 16#041C put
-dup /afii10031 16#041D put
-dup /afii10032 16#041E put
-dup /afii10033 16#041F put
-dup /afii10034 16#0420 put
-dup /afii10035 16#0421 put
-dup /afii10036 16#0422 put
-dup /afii10037 16#0423 put
-dup /afii10038 16#0424 put
-dup /afii10039 16#0425 put
-dup /afii10040 16#0426 put
-dup /afii10041 16#0427 put
-dup /afii10042 16#0428 put
-dup /afii10043 16#0429 put
-dup /afii10044 16#042A put
-dup /afii10045 16#042B put
-dup /afii10046 16#042C put
-dup /afii10047 16#042D put
-dup /afii10048 16#042E put
-dup /afii10049 16#042F put
-dup /afii10050 16#0490 put
-dup /afii10051 16#0402 put
-dup /afii10052 16#0403 put
-dup /afii10053 16#0404 put
-dup /afii10054 16#0405 put
-dup /afii10055 16#0406 put
-dup /afii10056 16#0407 put
-dup /afii10057 16#0408 put
-dup /afii10058 16#0409 put
-dup /afii10059 16#040A put
-dup /afii10060 16#040B put
-dup /afii10061 16#040C put
-dup /afii10062 16#040E put
-dup /afii10063 16#F6C4 put
-dup /afii10064 16#F6C5 put
-dup /afii10065 16#0430 put
-dup /afii10066 16#0431 put
-dup /afii10067 16#0432 put
-dup /afii10068 16#0433 put
-dup /afii10069 16#0434 put
-dup /afii10070 16#0435 put
-dup /afii10071 16#0451 put
-dup /afii10072 16#0436 put
-dup /afii10073 16#0437 put
-dup /afii10074 16#0438 put
-dup /afii10075 16#0439 put
-dup /afii10076 16#043A put
-dup /afii10077 16#043B put
-dup /afii10078 16#043C put
-dup /afii10079 16#043D put
-dup /afii10080 16#043E put
-dup /afii10081 16#043F put
-dup /afii10082 16#0440 put
-dup /afii10083 16#0441 put
-dup /afii10084 16#0442 put
-dup /afii10085 16#0443 put
-dup /afii10086 16#0444 put
-dup /afii10087 16#0445 put
-dup /afii10088 16#0446 put
-dup /afii10089 16#0447 put
-dup /afii10090 16#0448 put
-dup /afii10091 16#0449 put
-dup /afii10092 16#044A put
-dup /afii10093 16#044B put
-dup /afii10094 16#044C put
-dup /afii10095 16#044D put
-dup /afii10096 16#044E put
-dup /afii10097 16#044F put
-dup /afii10098 16#0491 put
-dup /afii10099 16#0452 put
-dup /afii10100 16#0453 put
-dup /afii10101 16#0454 put
-dup /afii10102 16#0455 put
-dup /afii10103 16#0456 put
-dup /afii10104 16#0457 put
-dup /afii10105 16#0458 put
-dup /afii10106 16#0459 put
-dup /afii10107 16#045A put
-dup /afii10108 16#045B put
-dup /afii10109 16#045C put
-dup /afii10110 16#045E put
-dup /afii10145 16#040F put
-dup /afii10146 16#0462 put
-dup /afii10147 16#0472 put
-dup /afii10148 16#0474 put
-dup /afii10192 16#F6C6 put
-dup /afii10193 16#045F put
-dup /afii10194 16#0463 put
-dup /afii10195 16#0473 put
-dup /afii10196 16#0475 put
-dup /afii10831 16#F6C7 put
-dup /afii10832 16#F6C8 put
-dup /afii10846 16#04D9 put
-dup /afii299 16#200E put
-dup /afii300 16#200F put
-dup /afii301 16#200D put
-dup /afii57381 16#066A put
-dup /afii57388 16#060C put
-dup /afii57392 16#0660 put
-dup /afii57393 16#0661 put
-dup /afii57394 16#0662 put
-dup /afii57395 16#0663 put
-dup /afii57396 16#0664 put
-dup /afii57397 16#0665 put
-dup /afii57398 16#0666 put
-dup /afii57399 16#0667 put
-dup /afii57400 16#0668 put
-dup /afii57401 16#0669 put
-dup /afii57403 16#061B put
-dup /afii57407 16#061F put
-dup /afii57409 16#0621 put
-dup /afii57410 16#0622 put
-dup /afii57411 16#0623 put
-dup /afii57412 16#0624 put
-dup /afii57413 16#0625 put
-dup /afii57414 16#0626 put
-dup /afii57415 16#0627 put
-dup /afii57416 16#0628 put
-dup /afii57417 16#0629 put
-dup /afii57418 16#062A put
-dup /afii57419 16#062B put
-dup /afii57420 16#062C put
-dup /afii57421 16#062D put
-dup /afii57422 16#062E put
-dup /afii57423 16#062F put
-dup /afii57424 16#0630 put
-dup /afii57425 16#0631 put
-dup /afii57426 16#0632 put
-dup /afii57427 16#0633 put
-dup /afii57428 16#0634 put
-dup /afii57429 16#0635 put
-dup /afii57430 16#0636 put
-dup /afii57431 16#0637 put
-dup /afii57432 16#0638 put
-dup /afii57433 16#0639 put
-dup /afii57434 16#063A put
-dup /afii57440 16#0640 put
-dup /afii57441 16#0641 put
-dup /afii57442 16#0642 put
-dup /afii57443 16#0643 put
-dup /afii57444 16#0644 put
-dup /afii57445 16#0645 put
-dup /afii57446 16#0646 put
-dup /afii57448 16#0648 put
-dup /afii57449 16#0649 put
-dup /afii57450 16#064A put
-dup /afii57451 16#064B put
-dup /afii57452 16#064C put
-dup /afii57453 16#064D put
-dup /afii57454 16#064E put
-dup /afii57455 16#064F put
-dup /afii57456 16#0650 put
-dup /afii57457 16#0651 put
-dup /afii57458 16#0652 put
-dup /afii57470 16#0647 put
-dup /afii57505 16#06A4 put
-dup /afii57506 16#067E put
-dup /afii57507 16#0686 put
-dup /afii57508 16#0698 put
-dup /afii57509 16#06AF put
-dup /afii57511 16#0679 put
-dup /afii57512 16#0688 put
-dup /afii57513 16#0691 put
-dup /afii57514 16#06BA put
-dup /afii57519 16#06D2 put
-dup /afii57534 16#06D5 put
-dup /afii57636 16#20AA put
-dup /afii57645 16#05BE put
-dup /afii57658 16#05C3 put
-dup /afii57664 16#05D0 put
-dup /afii57665 16#05D1 put
-dup /afii57666 16#05D2 put
-dup /afii57667 16#05D3 put
-dup /afii57668 16#05D4 put
-dup /afii57669 16#05D5 put
-dup /afii57670 16#05D6 put
-dup /afii57671 16#05D7 put
-dup /afii57672 16#05D8 put
-dup /afii57673 16#05D9 put
-dup /afii57674 16#05DA put
-dup /afii57675 16#05DB put
-dup /afii57676 16#05DC put
-dup /afii57677 16#05DD put
-dup /afii57678 16#05DE put
-dup /afii57679 16#05DF put
-dup /afii57680 16#05E0 put
-dup /afii57681 16#05E1 put
-dup /afii57682 16#05E2 put
-dup /afii57683 16#05E3 put
-dup /afii57684 16#05E4 put
-dup /afii57685 16#05E5 put
-dup /afii57686 16#05E6 put
-dup /afii57687 16#05E7 put
-dup /afii57688 16#05E8 put
-dup /afii57689 16#05E9 put
-dup /afii57690 16#05EA put
-dup /afii57694 16#FB2A put
-dup /afii57695 16#FB2B put
-dup /afii57700 16#FB4B put
-dup /afii57705 16#FB1F put
-dup /afii57716 16#05F0 put
-dup /afii57717 16#05F1 put
-dup /afii57718 16#05F2 put
-dup /afii57723 16#FB35 put
-dup /afii57793 16#05B4 put
-dup /afii57794 16#05B5 put
-dup /afii57795 16#05B6 put
-dup /afii57796 16#05BB put
-dup /afii57797 16#05B8 put
-dup /afii57798 16#05B7 put
-dup /afii57799 16#05B0 put
-dup /afii57800 16#05B2 put
-dup /afii57801 16#05B1 put
-dup /afii57802 16#05B3 put
-dup /afii57803 16#05C2 put
-dup /afii57804 16#05C1 put
-dup /afii57806 16#05B9 put
-dup /afii57807 16#05BC put
-dup /afii57839 16#05BD put
-dup /afii57841 16#05BF put
-dup /afii57842 16#05C0 put
-dup /afii57929 16#02BC put
-dup /afii61248 16#2105 put
-dup /afii61289 16#2113 put
-dup /afii61352 16#2116 put
-dup /afii61573 16#202C put
-dup /afii61574 16#202D put
-dup /afii61575 16#202E put
-dup /afii61664 16#200C put
-dup /afii63167 16#066D put
-dup /afii64937 16#02BD put
-dup /agrave 16#00E0 put
-dup /aleph 16#2135 put
-dup /alpha 16#03B1 put
-dup /alphatonos 16#03AC put
-dup /amacron 16#0101 put
-dup /ampersand 16#0026 put
-dup /ampersandsmall 16#F726 put
-dup /angle 16#2220 put
-dup /angleleft 16#2329 put
-dup /angleright 16#232A put
-dup /anoteleia 16#0387 put
-dup /aogonek 16#0105 put
-dup /approxequal 16#2248 put
-dup /aring 16#00E5 put
-dup /aringacute 16#01FB put
-dup /arrowboth 16#2194 put
-dup /arrowdblboth 16#21D4 put
-dup /arrowdbldown 16#21D3 put
-dup /arrowdblleft 16#21D0 put
-dup /arrowdblright 16#21D2 put
-dup /arrowdblup 16#21D1 put
-dup /arrowdown 16#2193 put
-dup /arrowhorizex 16#F8E7 put
-dup /arrowleft 16#2190 put
-dup /arrowright 16#2192 put
-dup /arrowup 16#2191 put
-dup /arrowupdn 16#2195 put
-dup /arrowupdnbse 16#21A8 put
-dup /arrowvertex 16#F8E6 put
-dup /asciicircum 16#005E put
-dup /asciitilde 16#007E put
-dup /asterisk 16#002A put
-dup /asteriskmath 16#2217 put
-dup /asuperior 16#F6E9 put
-dup /at 16#0040 put
-dup /atilde 16#00E3 put
-dup /b 16#0062 put
-dup /backslash 16#005C put
-dup /bar 16#007C put
-dup /beta 16#03B2 put
-dup /block 16#2588 put
-dup /braceex 16#F8F4 put
-dup /braceleft 16#007B put
-dup /braceleftbt 16#F8F3 put
-dup /braceleftmid 16#F8F2 put
-dup /bracelefttp 16#F8F1 put
-dup /braceright 16#007D put
-dup /bracerightbt 16#F8FE put
-dup /bracerightmid 16#F8FD put
-dup /bracerighttp 16#F8FC put
-dup /bracketleft 16#005B put
-dup /bracketleftbt 16#F8F0 put
-dup /bracketleftex 16#F8EF put
-dup /bracketlefttp 16#F8EE put
-dup /bracketright 16#005D put
-dup /bracketrightbt 16#F8FB put
-dup /bracketrightex 16#F8FA put
-dup /bracketrighttp 16#F8F9 put
-dup /breve 16#02D8 put
-dup /brokenbar 16#00A6 put
-dup /bsuperior 16#F6EA put
-dup /bullet 16#2022 put
-dup /c 16#0063 put
-dup /cacute 16#0107 put
-dup /caron 16#02C7 put
-dup /carriagereturn 16#21B5 put
-dup /ccaron 16#010D put
-dup /ccedilla 16#00E7 put
-dup /ccircumflex 16#0109 put
-dup /cdotaccent 16#010B put
-dup /cedilla 16#00B8 put
-dup /cent 16#00A2 put
-dup /centinferior 16#F6DF put
-dup /centoldstyle 16#F7A2 put
-dup /centsuperior 16#F6E0 put
-dup /chi 16#03C7 put
-dup /circle 16#25CB put
-dup /circlemultiply 16#2297 put
-dup /circleplus 16#2295 put
-dup /circumflex 16#02C6 put
-dup /club 16#2663 put
-dup /colon 16#003A put
-dup /colonmonetary 16#20A1 put
-dup /comma 16#002C put
-dup /commaaccent 16#F6C3 put
-dup /commainferior 16#F6E1 put
-dup /commasuperior 16#F6E2 put
-dup /congruent 16#2245 put
-dup /copyright 16#00A9 put
-dup /copyrightsans 16#F8E9 put
-dup /copyrightserif 16#F6D9 put
-dup /currency 16#00A4 put
-dup /cyrBreve 16#F6D1 put
-dup /cyrFlex 16#F6D2 put
-dup /cyrbreve 16#F6D4 put
-dup /cyrflex 16#F6D5 put
-dup /d 16#0064 put
-dup /dagger 16#2020 put
-dup /daggerdbl 16#2021 put
-dup /dblGrave 16#F6D3 put
-dup /dblgrave 16#F6D6 put
-dup /dcaron 16#010F put
-dup /dcroat 16#0111 put
-dup /degree 16#00B0 put
-dup /delta 16#03B4 put
-dup /diamond 16#2666 put
-dup /dieresis 16#00A8 put
-dup /dieresisacute 16#F6D7 put
-dup /dieresisgrave 16#F6D8 put
-dup /dieresistonos 16#0385 put
-dup /divide 16#00F7 put
-dup /dkshade 16#2593 put
-dup /dnblock 16#2584 put
-dup /dollar 16#0024 put
-dup /dollarinferior 16#F6E3 put
-dup /dollaroldstyle 16#F724 put
-dup /dollarsuperior 16#F6E4 put
-dup /dong 16#20AB put
-dup /dotaccent 16#02D9 put
-dup /dotbelowcomb 16#0323 put
-dup /dotlessi 16#0131 put
-dup /dotlessj 16#F6BE put
-dup /dotmath 16#22C5 put
-dup /dsuperior 16#F6EB put
-dup /e 16#0065 put
-dup /eacute 16#00E9 put
-dup /ebreve 16#0115 put
-dup /ecaron 16#011B put
-dup /ecircumflex 16#00EA put
-dup /edieresis 16#00EB put
-dup /edotaccent 16#0117 put
-dup /egrave 16#00E8 put
-dup /eight 16#0038 put
-dup /eightinferior 16#2088 put
-dup /eightoldstyle 16#F738 put
-dup /eightsuperior 16#2078 put
-dup /element 16#2208 put
-dup /ellipsis 16#2026 put
-dup /emacron 16#0113 put
-dup /emdash 16#2014 put
-dup /emptyset 16#2205 put
-dup /endash 16#2013 put
-dup /eng 16#014B put
-dup /eogonek 16#0119 put
-dup /epsilon 16#03B5 put
-dup /epsilontonos 16#03AD put
-dup /equal 16#003D put
-dup /equivalence 16#2261 put
-dup /estimated 16#212E put
-dup /esuperior 16#F6EC put
-dup /eta 16#03B7 put
-dup /etatonos 16#03AE put
-dup /eth 16#00F0 put
-dup /exclam 16#0021 put
-dup /exclamdbl 16#203C put
-dup /exclamdown 16#00A1 put
-dup /exclamdownsmall 16#F7A1 put
-dup /exclamsmall 16#F721 put
-dup /existential 16#2203 put
-dup /f 16#0066 put
-dup /female 16#2640 put
-dup /ff 16#FB00 put
-dup /ffi 16#FB03 put
-dup /ffl 16#FB04 put
-dup /fi 16#FB01 put
-dup /figuredash 16#2012 put
-dup /filledbox 16#25A0 put
-dup /filledrect 16#25AC put
-dup /five 16#0035 put
-dup /fiveeighths 16#215D put
-dup /fiveinferior 16#2085 put
-dup /fiveoldstyle 16#F735 put
-dup /fivesuperior 16#2075 put
-dup /fl 16#FB02 put
-dup /florin 16#0192 put
-dup /four 16#0034 put
-dup /fourinferior 16#2084 put
-dup /fouroldstyle 16#F734 put
-dup /foursuperior 16#2074 put
-dup /fraction [16#2044 16#2215] put
-dup /franc 16#20A3 put
-dup /g 16#0067 put
-dup /gamma 16#03B3 put
-dup /gbreve 16#011F put
-dup /gcaron 16#01E7 put
-dup /gcircumflex 16#011D put
-dup /gcommaaccent 16#0123 put
-dup /gdotaccent 16#0121 put
-dup /germandbls 16#00DF put
-dup /gradient 16#2207 put
-dup /grave 16#0060 put
-dup /gravecomb 16#0300 put
-dup /greater 16#003E put
-dup /greaterequal 16#2265 put
-dup /guillemotleft 16#00AB put
-dup /guillemotright 16#00BB put
-dup /guilsinglleft 16#2039 put
-dup /guilsinglright 16#203A put
-dup /h 16#0068 put
-dup /hbar 16#0127 put
-dup /hcircumflex 16#0125 put
-dup /heart 16#2665 put
-dup /hookabovecomb 16#0309 put
-dup /house 16#2302 put
-dup /hungarumlaut 16#02DD put
-dup /hyphen [16#002D 16#00AD] put
-dup /hypheninferior 16#F6E5 put
-dup /hyphensuperior 16#F6E6 put
-dup /i 16#0069 put
-dup /iacute 16#00ED put
-dup /ibreve 16#012D put
-dup /icircumflex 16#00EE put
-dup /idieresis 16#00EF put
-dup /igrave 16#00EC put
-dup /ij 16#0133 put
-dup /imacron 16#012B put
-dup /infinity 16#221E put
-dup /integral 16#222B put
-dup /integralbt 16#2321 put
-dup /integralex 16#F8F5 put
-dup /integraltp 16#2320 put
-dup /intersection 16#2229 put
-dup /invbullet 16#25D8 put
-dup /invcircle 16#25D9 put
-dup /invsmileface 16#263B put
-dup /iogonek 16#012F put
-dup /iota 16#03B9 put
-dup /iotadieresis 16#03CA put
-dup /iotadieresistonos 16#0390 put
-dup /iotatonos 16#03AF put
-dup /isuperior 16#F6ED put
-dup /itilde 16#0129 put
-dup /j 16#006A put
-dup /jcircumflex 16#0135 put
-dup /k 16#006B put
-dup /kappa 16#03BA put
-dup /kcommaaccent 16#0137 put
-dup /kgreenlandic 16#0138 put
-dup /l 16#006C put
-dup /lacute 16#013A put
-dup /lambda 16#03BB put
-dup /lcaron 16#013E put
-dup /lcommaaccent 16#013C put
-dup /ldot 16#0140 put
-dup /less 16#003C put
-dup /lessequal 16#2264 put
-dup /lfblock 16#258C put
-dup /lira 16#20A4 put
-dup /ll 16#F6C0 put
-dup /logicaland 16#2227 put
-dup /logicalnot 16#00AC put
-dup /logicalor 16#2228 put
-dup /longs 16#017F put
-dup /lozenge 16#25CA put
-dup /lslash 16#0142 put
-dup /lsuperior 16#F6EE put
-dup /ltshade 16#2591 put
-dup /m 16#006D put
-dup /macron [16#00AF 16#02C9] put
-dup /male 16#2642 put
-dup /minus 16#2212 put
-dup /minute 16#2032 put
-dup /msuperior 16#F6EF put
-dup /mu [16#00B5 16#03BC] put
-dup /multiply 16#00D7 put
-dup /musicalnote 16#266A put
-dup /musicalnotedbl 16#266B put
-dup /n 16#006E put
-dup /nacute 16#0144 put
-dup /napostrophe 16#0149 put
-dup /ncaron 16#0148 put
-dup /ncommaaccent 16#0146 put
-dup /nine 16#0039 put
-dup /nineinferior 16#2089 put
-dup /nineoldstyle 16#F739 put
-dup /ninesuperior 16#2079 put
-dup /notelement 16#2209 put
-dup /notequal 16#2260 put
-dup /notsubset 16#2284 put
-dup /nsuperior 16#207F put
-dup /ntilde 16#00F1 put
-dup /nu 16#03BD put
-dup /numbersign 16#0023 put
-dup /o 16#006F put
-dup /oacute 16#00F3 put
-dup /obreve 16#014F put
-dup /ocircumflex 16#00F4 put
-dup /odieresis 16#00F6 put
-dup /oe 16#0153 put
-dup /ogonek 16#02DB put
-dup /ograve 16#00F2 put
-dup /ohorn 16#01A1 put
-dup /ohungarumlaut 16#0151 put
-dup /omacron 16#014D put
-dup /omega 16#03C9 put
-dup /omega1 16#03D6 put
-dup /omegatonos 16#03CE put
-dup /omicron 16#03BF put
-dup /omicrontonos 16#03CC put
-dup /one 16#0031 put
-dup /onedotenleader 16#2024 put
-dup /oneeighth 16#215B put
-dup /onefitted 16#F6DC put
-dup /onehalf 16#00BD put
-dup /oneinferior 16#2081 put
-dup /oneoldstyle 16#F731 put
-dup /onequarter 16#00BC put
-dup /onesuperior 16#00B9 put
-dup /onethird 16#2153 put
-dup /openbullet 16#25E6 put
-dup /ordfeminine 16#00AA put
-dup /ordmasculine 16#00BA put
-dup /orthogonal 16#221F put
-dup /oslash 16#00F8 put
-dup /oslashacute 16#01FF put
-dup /osuperior 16#F6F0 put
-dup /otilde 16#00F5 put
-dup /p 16#0070 put
-dup /paragraph 16#00B6 put
-dup /parenleft 16#0028 put
-dup /parenleftbt 16#F8ED put
-dup /parenleftex 16#F8EC put
-dup /parenleftinferior 16#208D put
-dup /parenleftsuperior 16#207D put
-dup /parenlefttp 16#F8EB put
-dup /parenright 16#0029 put
-dup /parenrightbt 16#F8F8 put
-dup /parenrightex 16#F8F7 put
-dup /parenrightinferior 16#208E put
-dup /parenrightsuperior 16#207E put
-dup /parenrighttp 16#F8F6 put
-dup /partialdiff 16#2202 put
-dup /percent 16#0025 put
-dup /period 16#002E put
-dup /periodcentered [16#00B7 16#2219] put
-dup /periodinferior 16#F6E7 put
-dup /periodsuperior 16#F6E8 put
-dup /perpendicular 16#22A5 put
-dup /perthousand 16#2030 put
-dup /peseta 16#20A7 put
-dup /phi 16#03C6 put
-dup /phi1 16#03D5 put
-dup /pi 16#03C0 put
-dup /plus 16#002B put
-dup /plusminus 16#00B1 put
-dup /prescription 16#211E put
-dup /product 16#220F put
-dup /propersubset 16#2282 put
-dup /propersuperset 16#2283 put
-dup /proportional 16#221D put
-dup /psi 16#03C8 put
-dup /q 16#0071 put
-dup /question 16#003F put
-dup /questiondown 16#00BF put
-dup /questiondownsmall 16#F7BF put
-dup /questionsmall 16#F73F put
-dup /quotedbl 16#0022 put
-dup /quotedblbase 16#201E put
-dup /quotedblleft 16#201C put
-dup /quotedblright 16#201D put
-dup /quoteleft 16#2018 put
-dup /quotereversed 16#201B put
-dup /quoteright 16#2019 put
-dup /quotesinglbase 16#201A put
-dup /quotesingle 16#0027 put
-dup /r 16#0072 put
-dup /racute 16#0155 put
-dup /radical 16#221A put
-dup /radicalex 16#F8E5 put
-dup /rcaron 16#0159 put
-dup /rcommaaccent 16#0157 put
-dup /reflexsubset 16#2286 put
-dup /reflexsuperset 16#2287 put
-dup /registered 16#00AE put
-dup /registersans 16#F8E8 put
-dup /registerserif 16#F6DA put
-dup /revlogicalnot 16#2310 put
-dup /rho 16#03C1 put
-dup /ring 16#02DA put
-dup /rsuperior 16#F6F1 put
-dup /rtblock 16#2590 put
-dup /rupiah 16#F6DD put
-dup /s 16#0073 put
-dup /sacute 16#015B put
-dup /scaron 16#0161 put
-dup /scedilla [16#015F 16#F6C2] put
-dup /scircumflex 16#015D put
-dup /scommaaccent 16#0219 put
-dup /second 16#2033 put
-dup /section 16#00A7 put
-dup /semicolon 16#003B put
-dup /seven 16#0037 put
-dup /seveneighths 16#215E put
-dup /seveninferior 16#2087 put
-dup /sevenoldstyle 16#F737 put
-dup /sevensuperior 16#2077 put
-dup /shade 16#2592 put
-dup /sigma 16#03C3 put
-dup /sigma1 16#03C2 put
-dup /similar 16#223C put
-dup /six 16#0036 put
-dup /sixinferior 16#2086 put
-dup /sixoldstyle 16#F736 put
-dup /sixsuperior 16#2076 put
-dup /slash 16#002F put
-dup /smileface 16#263A put
-dup /space [16#0020 16#00A0] put
-dup /spade 16#2660 put
-dup /ssuperior 16#F6F2 put
-dup /sterling 16#00A3 put
-dup /suchthat 16#220B put
-dup /summation 16#2211 put
-dup /sun 16#263C put
-dup /t 16#0074 put
-dup /tau 16#03C4 put
-dup /tbar 16#0167 put
-dup /tcaron 16#0165 put
-dup /tcommaaccent [16#0163 16#021B] put
-dup /therefore 16#2234 put
-dup /theta 16#03B8 put
-dup /theta1 16#03D1 put
-dup /thorn 16#00FE put
-dup /three 16#0033 put
-dup /threeeighths 16#215C put
-dup /threeinferior 16#2083 put
-dup /threeoldstyle 16#F733 put
-dup /threequarters 16#00BE put
-dup /threequartersemdash 16#F6DE put
-dup /threesuperior 16#00B3 put
-dup /tilde 16#02DC put
-dup /tildecomb 16#0303 put
-dup /tonos 16#0384 put
-dup /trademark 16#2122 put
-dup /trademarksans 16#F8EA put
-dup /trademarkserif 16#F6DB put
-dup /triagdn 16#25BC put
-dup /triaglf 16#25C4 put
-dup /triagrt 16#25BA put
-dup /triagup 16#25B2 put
-dup /tsuperior 16#F6F3 put
-dup /two 16#0032 put
-dup /twodotenleader 16#2025 put
-dup /twoinferior 16#2082 put
-dup /twooldstyle 16#F732 put
-dup /twosuperior 16#00B2 put
-dup /twothirds 16#2154 put
-dup /u 16#0075 put
-dup /uacute 16#00FA put
-dup /ubreve 16#016D put
-dup /ucircumflex 16#00FB put
-dup /udieresis 16#00FC put
-dup /ugrave 16#00F9 put
-dup /uhorn 16#01B0 put
-dup /uhungarumlaut 16#0171 put
-dup /umacron 16#016B put
-dup /underscore 16#005F put
-dup /underscoredbl 16#2017 put
-dup /union 16#222A put
-dup /universal 16#2200 put
-dup /uogonek 16#0173 put
-dup /upblock 16#2580 put
-dup /upsilon 16#03C5 put
-dup /upsilondieresis 16#03CB put
-dup /upsilondieresistonos 16#03B0 put
-dup /upsilontonos 16#03CD put
-dup /uring 16#016F put
-dup /utilde 16#0169 put
-dup /v 16#0076 put
-dup /w 16#0077 put
-dup /wacute 16#1E83 put
-dup /wcircumflex 16#0175 put
-dup /wdieresis 16#1E85 put
-dup /weierstrass 16#2118 put
-dup /wgrave 16#1E81 put
-dup /x 16#0078 put
-dup /xi 16#03BE put
-dup /y 16#0079 put
-dup /yacute 16#00FD put
-dup /ycircumflex 16#0177 put
-dup /ydieresis 16#00FF put
-dup /yen 16#00A5 put
-dup /ygrave 16#1EF3 put
-dup /z 16#007A put
-dup /zacute 16#017A put
-dup /zcaron 16#017E put
-dup /zdotaccent 16#017C put
-dup /zero 16#0030 put
-dup /zeroinferior 16#2080 put
-dup /zerooldstyle 16#F730 put
-dup /zerosuperior 16#2070 put
-dup /zeta 16#03B6 put
-def
diff --git a/Master/tlpkg/tlgs/lib/gs_btokn.ps b/Master/tlpkg/tlgs/lib/gs_btokn.ps deleted file mode 100644 index f2f88bb8e2c..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_btokn.ps +++ /dev/null @@ -1,331 +0,0 @@ -% Copyright (C) 1994, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_btokn.ps 7631 2007-01-22 03:26:28Z lpd $
-% Initialization file for binary tokens.
-% When this is run, systemdict is still writable,
-% but everything defined here goes into level2dict.
-
-% Define whether or not to allow writing dictionaries.
-% This is a non-standard feature!
-/WRITEDICTS false def
-
-languagelevel 1 .setlanguagelevel
-level2dict begin
-
-% Initialization for the system name table.
-
-mark
-% 0
- /abs /add /aload /anchorsearch /and
- /arc /arcn /arct /arcto /array
- /ashow /astore /awidthshow /begin /bind
- /bitshift /ceiling /charpath /clear /cleartomark
-% 20
- /clip /clippath /closepath /concat /concatmatrix
- /copy /count /counttomark /currentcmykcolor /currentdash
- /currentdict /currentfile /currentfont /currentgray /currentgstate
- /currenthsbcolor /currentlinecap /currentlinejoin /currentlinewidth /currentmatrix
-% 40
- /currentpoint /currentrgbcolor /currentshared /curveto /cvi
- /cvlit /cvn /cvr /cvrs /cvs
- /cvx /def /defineusername /dict /div
- /dtransform /dup /end /eoclip /eofill
-% 60
- /eoviewclip /eq /exch /exec /exit
- /file /fill /findfont /flattenpath /floor
- /flush /flushfile /for /forall /ge
- /get /getinterval /grestore /gsave /gstate
-% 80
- /gt /identmatrix /idiv /idtransform /if
- /ifelse /image /imagemask /index /ineofill
- /infill /initviewclip /inueofill /inufill /invertmatrix
- /itransform /known /le /length /lineto
-% 100
- /load /loop /lt /makefont /matrix
- /maxlength /mod /moveto /mul /ne
- /neg /newpath /not /null /or
- /pathbbox /pathforall /pop /print /printobject
-% 120
- /put /putinterval /rcurveto /read /readhexstring
- /readline /readstring /rectclip /rectfill /rectstroke
- /rectviewclip /repeat /restore /rlineto /rmoveto
- /roll /rotate /round /save /scale
-% 140
- /scalefont /search /selectfont /setbbox /setcachedevice
- /setcachedevice2 /setcharwidth /setcmykcolor /setdash /setfont
- /setgray /setgstate /sethsbcolor /setlinecap /setlinejoin
- /setlinewidth /setmatrix /setrgbcolor /setshared /shareddict
-% 160
- /show /showpage /stop /stopped /store
- /string /stringwidth /stroke /strokepath /sub
- /systemdict /token /transform /translate /truncate
- /type /uappend /ucache /ueofill /ufill
-% 180
- /undef /upath /userdict /ustroke /viewclip
- /viewclippath /where /widthshow /write /writehexstring
- /writeobject /writestring /wtranslation /xor /xshow
- /xyshow /yshow /FontDirectory /SharedFontDirectory /Courier
-% 200
- /Courier-Bold /Courier-BoldOblique /Courier-Oblique /Helvetica /Helvetica-Bold
- /Helvetica-BoldOblique /Helvetica-Oblique /Symbol /Times-Bold /Times-BoldItalic
- /Times-Italic /Times-Roman /execuserobject /currentcolor /currentcolorspace
- /currentglobal /execform /filter /findresource /globaldict
-% 220
- /makepattern /setcolor /setcolorspace /setglobal /setpagedevice
- /setpattern
-% pad to 256
- counttomark 256 exch sub { 0 } repeat
-% 256
- /= /== /ISOLatin1Encoding /StandardEncoding
-% 260
- ([) cvn (]) cvn /atan /banddevice /bytesavailable
- /cachestatus /closefile /colorimage /condition /copypage
- /cos /countdictstack /countexecstack /cshow /currentblackgeneration
- /currentcacheparams /currentcolorscreen /currentcolortransfer /currentcontext /currentflat
-% 280
- /currenthalftone /currenthalftonephase /currentmiterlimit /currentobjectformat /currentpacking
- /currentscreen /currentstrokeadjust /currenttransfer /currentundercolorremoval /defaultmatrix
- /definefont /deletefile /detach /deviceinfo /dictstack
- /echo /erasepage /errordict /execstack /executeonly
-% 300
- /exp /false /filenameforall /fileposition /fork
- /framedevice /grestoreall /handleerror /initclip /initgraphics
- /initmatrix /instroke /inustroke /join /kshow
- /ln /lock /log /mark /monitor
-% 320
- /noaccess /notify /nulldevice /packedarray /quit
- /rand /rcheck /readonly /realtime /renamefile
- /renderbands /resetfile /reversepath /rootfont /rrand
- /run /scheck /setblackgeneration /setcachelimit /setcacheparams
-% 340
- /setcolorscreen /setcolortransfer /setfileposition /setflat /sethalftone
- /sethalftonephase /setmiterlimit /setobjectformat /setpacking /setscreen
- /setstrokeadjust /settransfer /setucacheparams /setundercolorremoval /sin
- /sqrt /srand /stack /status /statusdict
-% 360
- /true /ucachestatus /undefinefont /usertime /ustrokepath
- /version /vmreclaim /vmstatus /wait /wcheck
- /xcheck /yield /defineuserobject /undefineuserobject /UserObjects
- /cleardictstack
-% 376
- /A /B /C /D /E /F /G /H /I /J /K /L /M
- /N /O /P /Q /R /S /T /U /V /W /X /Y /Z
- /a /b /c /d /e /f /g /h /i /j /k /l /m
- /n /o /p /q /r /s /t /u /v /w /x /y /z
-% 428
- /setvmthreshold (<<) cvn
- (>>) cvn /currentcolorrendering /currentdevparams /currentoverprint /currentpagedevice
- /currentsystemparams /currentuserparams /defineresource /findencoding /gcheck
-% 440
- /glyphshow /languagelevel /product /pstack /resourceforall
- /resourcestatus /revision /serialnumber /setcolorrendering /setdevparams
- /setoverprint /setsystemparams /setuserparams /startjob /undefineresource
- /GlobalFontDirectory /ASCII85Decode /ASCII85Encode /ASCIIHexDecode /ASCIIHexEncode
-% 460
- /CCITTFaxDecode /CCITTFaxEncode /DCTDecode /DCTEncode /LZWDecode
- /LZWEncode /NullEncode /RunLengthDecode /RunLengthEncode /SubFileDecode
- /CIEBasedA /CIEBasedABC /DeviceCMYK /DeviceGray /DeviceRGB
- /Indexed /Pattern /Separation /CIEBasedDEF /CIEBasedDEFG
-% 480
- /DeviceN
-% 481 -- end
-.packtomark .installsystemnames
-
-% Define printobject and writeobject.
-% These are mostly implemented in PostScript, so that we don't have to
-% worry about interrupts or callbacks when writing to the output file.
-
-% Define procedures for accumulating the space required to represent
-% an object in binary form. The procedures for composite objects (arrays
-% and dictionaries) leave different results on the stack:
-% <#refs> <#chars> <simple_obj> -proc- <#refs> <#chars>
-% <#refs> <#chars> <array|dict> -proc- <array|dict> <#refs> <#chars>
-% This is required so that .writeobjects can also accumulate the actual
-% list of composite objects to write in the binary object sequence.
-/cntdict mark
- /integertype /pop load
- /realtype 1 index
- /marktype 1 index
- /nulltype 1 index
- /booleantype 1 index
- /nametype { length add } bind
- /stringtype 1 index
- /arraytype null
- /dicttype null
-.dicttomark def
-/.cntobj { % <<arguments and results as for procedures in cntdict>>
- dup type //cntdict exch get exec
-} .bind def
-cntdict /arraytype {
- dup dup length 5 -1 roll add 4 2 roll { .cntobj } forall
-} bind put
-cntdict /dicttype {
- WRITEDICTS {
- dup dup length 2 mul 5 -1 roll add 4 2 roll {
- % We have to use .execn here, rather than simply rolling the
- % value under the top elements, because key might involve arrays
- % or dictionaries.
- cvlit {.cntobj} exch 2 .execn .cntobj
- } forall
- } {
- /writeobject .systemvar /typecheck signalerror
- } ifelse
-} bind put
-
-/w2dict mark
- /nametype { 2 copy .writecvs pop } bind
- /stringtype 1 index
-.dicttomark def
-
-/.bosheader { % <top_length> <total_length> <string8> .bosheader
- % <string4|8>
- dup 0 currentobjectformat 127 add put % object format => BOS tag
- 2 index 255 le 2 index 65531 le and {
- % Use the short header format: tag toplen(1) totlen(2)
- exch 4 add exch
- 0 4 getinterval
- dup 1 5 -1 roll put
- } {
- % Use the long header format: tag 0(1) toplen(2) totlen(4)
- exch 8 add exch
- 0 0 4 2 roll .bosobject exch pop exch pop % store with byte swapping
- } ifelse % Stack: shortlen str
- exch dup -8 bitshift exch 255 and % str hibyte lobyte
- currentobjectformat 1 and 0 eq { % lsb first
- exch
- } if
- 2 index 3 3 -1 roll put
- 1 index 2 3 -1 roll put
-} .bind def
-
-/.writeobjects { % <file> <tag> <array> .writeobjects -
- mark exch
-
- % Count the space required for refs and strings.
-
- dup length 0 3 -1 roll
- % Stack: file tag -mark- #refs #chars array
- dup 4 1 roll { .cntobj } forall
-
- % Write the header.
-
- % Stack: file tag -mark- array1 ... (array|dict)N #refs #chars
- counttomark 3 add -2 roll 4 1 roll
- % Stack: -mark- array1 ... (array|dict)N tag #refs #chars file
- dup counttomark 1 sub index length
- 4 index 3 bitshift 4 index add
- (xxxxxxxx) .bosheader writestring
-
- % Write the objects per se.
-
- 3 1 roll pop
- counttomark 1 sub index length 3 bitshift exch
- 3 bitshift
- % Stack: -mark- array1 ... (array|dict)N tag file ref# char#
- counttomark 4 sub {
- counttomark -1 roll dup 6 1 roll
- % Stack: ... objN tag file ref# char# objN
- dup type /dicttype eq { % can't be first object
- { 5 1 roll (x\000xxxxxx) .bosobject
- 3 index exch writestring
- 4 -1 roll (x\000xxxxxx) .bosobject
- 3 index exch writestring
- } forall
- } {
- { (x\000xxxxxx) .bosobject
- dup 1 6 index put
- 3 index exch writestring
- 4 -1 roll pop 0 4 1 roll % clear tag
- } forall
- } ifelse
- } repeat
-
- % Write the strings and names.
-
- pop pop exch pop
- % Stack: -mark- array1 ... array|dictN file
- counttomark 1 sub {
- counttomark -1 roll {
- % The counting pass ensured that the keys and values
- % of any dictionary must be writable objects.
- % Hence, we are processing a dictionary iff
- % the next-to-top stack element is not a file.
- 1 index type /filetype ne {
- exch 2 index exch dup type //w2dict exch .knownget
- { exec } { pop } ifelse pop
- } if
- dup type //w2dict exch .knownget { exec } { pop } ifelse
- } forall
- } repeat
-
- % Clean up.
-
- % Stack: -mark- file
- pop pop
-
-} .bind def
-
-/printobject { % <obj> <tag> printobject -
- currentobjectformat 0 eq {
- /printobject .systemvar /undefined signalerror
- } if
- (%stdout) (w) file 2 index 2 index .writeobject pop pop
-} odef
-/writeobject { % <file> <obj> <tag> writeobject -
- currentobjectformat 0 eq {
- /writeobject .systemvar /undefined signalerror
- } if
- 2 .argindex pop % check # of args
- .writeobject
-} odef
-/.writeobject {
- 3 copy exch
- % We must allocate the array in local VM
- % to avoid a possible invalidaccess.
- .currentglobal false .setglobal exch 1 array astore exch .setglobal
- .writeobjects pop pop pop
-} .bind def
-
-% Implement binary error message output.
-/.objectprinttest { % <obj> .objectprinttest -
- % This is a pseudo-operator so it will restore the stack
- % if it gets an error.
- mark 0 0 3 .argindex .cntobj cleartomark pop
-} bind odef
-/.printerror {
- $error /binary get .languagelevel 2 ge and {
- currentobjectformat 0 ne {
- [ /Error $error /errorname get $error /command get
- % Convert the object with cvs if it isn't printable.
- dup { .objectprinttest } .internalstopped {
- pop 100 string cvs
- } if
- false ] 250 printobject
- }
- //.printerror % known to be a procedure
- ifelse
- }
- //.printerror % known to be a procedure
- ifelse
-} bind def
-
-currentdict /cntdict .undef
-currentdict /w2dict .undef
-
-% End of level2dict
-
-end
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_ccfnt.ps b/Master/tlpkg/tlgs/lib/gs_ccfnt.ps deleted file mode 100644 index c33186bf356..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_ccfnt.ps +++ /dev/null @@ -1,75 +0,0 @@ -% Copyright (C) 1994, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_ccfnt.ps 6300 2005-12-28 19:56:24Z giles $
-% Find and register all the precompiled font operators in systemdict.
-
-/registerfont % <fontname> <fontdict> registerfont <font>
- { CCFONTDEBUG { (Registering ) print 1 index = } if
- dup begin
- Encoding type /nametype eq
- { Encoding .findencoding /Encoding exch def
- }
- if
- dup /PrefEnc known
- { PrefEnc type /nametype eq
- { PrefEnc .findencoding /PrefEnc exch def
- }
- if
- }
- if
- dup /FDepVector known
- { /FDepVector [ FDepVector
- { .FontDirectory 1 index .knownget
- { exch pop }
- { ccfonts 1 index .knownget
- { registerfont
- }
- { Fontmap 1 index known
- { findfont }
- { pop NullFont }
- ifelse
- }
- ifelse
- }
- ifelse
- }
- forall ] readonly def
- }
- if
- end
- % Use the value of definefont appropriate at run-time, not bind-time
- /definefont load exec
- } bind odef
-% Bind recursive call (bind descends into oparrays: feature!)
-/registerfont dup load bind def
-
-/.loadinitialfonts {
- //.loadinitialfonts exec
- NOCCFONTS not {
- /ccfonts mark
- 0 1 null .getccfont 1 sub { .getccfont dup /FontName get exch } for
- .dicttomark def
- % Make sure these fonts are registered as "resources".
- currentfile {
- pop ccfonts {
- .FontDirectory 2 index known { pop pop } { registerfont pop } ifelse
- } forall
- } .execasresource
- currentdict /ccfonts .undef
- } if
-} bind def
-
-currentdict /registerfont .undef
diff --git a/Master/tlpkg/tlgs/lib/gs_ce_e.ps b/Master/tlpkg/tlgs/lib/gs_ce_e.ps deleted file mode 100644 index 33ed1751b83..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_ce_e.ps +++ /dev/null @@ -1,47 +0,0 @@ -% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_ce_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Adobe CE (Central European) encoding vector.
-% We define it by differences from the ISOLatin1Encoding vector.
-/CEEncoding
-ISOLatin1Encoding 0 39 getinterval aload pop
-% 047
- /quotesingle
-ISOLatin1Encoding 40 56 getinterval aload pop
-% 140
- /grave
-ISOLatin1Encoding 97 31 getinterval aload pop
-% 20x
- /.notdef /.notdef /quotesinglbase /.notdef /quotedblbase /ellipsis /dagger /daggerdbl
- /.notdef /perthousand /Scaron /guilsinglleft /Sacute /Tcaron /Zcaron /Zacute
- /.notdef /grave /acute /circumflex /tilde /bullet /endash /emdash
- /.notdef /trademark /scaron /guilsinglright /sacute /tcaron /zcaron /zacute
-% 24x
- /space /caron /breve /Lslash /currency /Aogonek /brokenbar /section
- /dieresis /copyright /Scommaaccent /guillemotleft /logicalnot /hyphen /registered /Zdotaccent
- /degree /plusminus /ogonek /lslash /acute /mu /paragraph /periodcentered
- /cedilla /aogonek /scommaaccent /guillemotright /Lcaron /hungarumlaut /lcaron /zdotaccent
-% 30x
- /Racute /Aacute /Acircumflex /Abreve /Adieresis /Lacute /Cacute /Ccedilla
- /Ccaron /Eacute /Eogonek /Edieresis /Ecaron /Iacute /Icircumflex /Dcaron
- /Dcroat /Nacute /Ncaron /Oacute /Ocircumflex /Ohungarumlaut /Odieresis /multiply
- /Rcaron /Uring /Uacute /Uhungarumlaut /Udieresis /Yacute /Tcommaaccent /germandbls
-% 34x
- /racute /aacute /acircumflex /abreve /adieresis /lacute /cacute /ccedilla
- /ccaron /eacute /eogonek /edieresis /ecaron /iacute /icircumflex /dcaron
- /dcroat /nacute /ncaron /oacute /ocircumflex /ohungarumlaut /odieresis /divide
- /rcaron /uring /uacute /uhungarumlaut /udieresis /yacute /tcommaaccent /dotaccent
-256 packedarray .defineencoding
diff --git a/Master/tlpkg/tlgs/lib/gs_cet.ps b/Master/tlpkg/tlgs/lib/gs_cet.ps deleted file mode 100644 index 83d91c7b4ce..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cet.ps +++ /dev/null @@ -1,61 +0,0 @@ -%!PS
-% Set defaults for Ghostscript to match Adobe CPSI behaviour for CET
-% $Id: gs_cet.ps 7723 2007-02-20 23:35:19Z alexcher $
-
-% do this in the server level so it is persistent across jobs
-true 0 startjob not {
- (*** Warning: CET startup is not in server default) = flush
-} if
-
-300 .sethiresscreen % needed for language switch build since it
- % processes gs_init.ps BEFORE setting the resolution
-
-0 array 0 setdash % CET 09-08 wants local setdash
-
-currentglobal true setglobal
-
-{
- systemdict dup dup dup
- /version (3017.102) put % match CPSI 3017.102
- /product (PhotoPRINT SE 5.0v2) put % match CPSI 3017.102
- /revision 0 put % match CPSI 3017.103 Tek shows revision 5
- /serialnumber 233640 put % match CPSI 3017.102 Tek shows serialnumber 1401788461
- systemdict /deviceinfo undef % for CET 20-23-1
-} superexec
-
-{ } bind dup
-setblackgeneration
-setundercolorremoval
-0 array cvx readonly dup dup dup setcolortransfer
-
-% CPSI doesn't define "Localization" resource.
-/Localization /Category undefineresource
-
-% Some previously compile time options such as USE_ADOBE_CMYK_RGB
-% and GS_CHAR_FILL are now dynamic. Force CPSI compatibility.
-true .setCPSImode
-
-setglobal
-
-% Remove all but 'letter' page size
-<<
-currentpagedevice /InputAttributes get
-1 1 2 index length 1 sub {
- 1 index exch undef
-} for
-/InputAttributes exch
->>
-setpagedevice
-
-% Patch setsmoothness, currentsmoothness for a better view of shadings :
-userdict /.smoothness currentsmoothness put
-/setsmoothness {
- dup type dup /integertype eq exch /realtype eq or {
- userdict /.smoothness 3 2 roll cvr put
- } {
- /setsmoothness .systemvar /typecheck signalerror
- } ifelse
-} bind odef
-/currentsmoothness { userdict /.smoothness get } bind odef % for 09-55.PS, 09-57.PS .
-
-false 0 startjob pop % re-enter encapsulated mode
diff --git a/Master/tlpkg/tlgs/lib/gs_cff.ps b/Master/tlpkg/tlgs/lib/gs_cff.ps deleted file mode 100644 index 94b1f61d318..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cff.ps +++ /dev/null @@ -1,783 +0,0 @@ -% Copyright (C) 1997, 1998, 1999, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_cff.ps 8239 2007-09-14 05:23:52Z alexcher $
-% Loader for CFF (compressed) fonts, including OpenType CFFs.
-% The following are not implemented yet:
-% Deleted entries in the Name Index
-% Embedded PostScript
-% Multiple Master fonts
-% Chameleon fonts
-% Synthetic fonts
-
-% ---------------- Font loading machinery ---------------- %
-
-% Augment the FONTPATH machinery so it recognizes OpenType CFF font sets.
-
-/.scanfontheaders where {
- pop /.scanfontheaders [
- .scanfontheaders aload pop (OTTO*)
- ] def
-} if
-
-% Load a font file that might be an OpenType CFF font set.
-
-% <file> .loadfontfile -
-/.loadnonottofontfile /.loadfontfile load def
-/.loadfontfile {
- dup 4 string .peekstring pop (OTTO) eq {
- % If this is a font at all, it's an OpenType CFF font set.
- .init_otto_font_file
- % Use a random FontSet resource name. ****** WRONG ******
- realtime rand xor =string cvs exch false
- ReadData
- } {
- % Not a TrueType font.
- .loadnonottofontfile
- } ifelse
-} bind def
-
-% <file> .init_otto_font_file <file>
-/.init_otto_font_file {
- /FontSetInit /ProcSet findresource begin
- 2 dict begin
- /f exch def /cff null def
- card32 pop card16 6 { next pop } repeat dup {
- % Stack: numtables tablesleft
- dup 0 eq {
- pop pop /.loadottofontfile cvx /invalidfont signalerror
- } if
- f 4 string readstring pop (CFF ) eq { sub exit } if
- f 12 string readstring pop pop 1 sub % skip to next table
- } loop
- % Stack: tablesread
- card32 pop card32 card32
- % Stack: tablesread start length
- exch 3 -1 roll 1 add 16 mul 12 add sub
- f exch subfilefilter flushfile % skip to start
- f exch subfilefilter end
-} bind def
-
-30 dict begin
-
-% ---------------- Standard strings (actually names) ---------------- %
-
-/StandardStrings mark
- % The initial StandardStrings that that denote characters are
- % defined as a pseudo-Encoding.
-% 0
- /CFFStandardStrings .findencoding aload pop
-% 379
- (001.000)
-% 380
- (001.001) (001.002) (001.003) /Black /Bold
- /Book /Light /Medium /Regular /Roman
- /Semibold
-.packtomark def
-
-% ---------------- Standard encodings ---------------- %
-
-/StandardEncodings [
-
-% StandardEncoding
-mark
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
- 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
- 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
- 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64
- 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80
- 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 0
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110
- 0 111 112 113 114 0 115 116 117 118 119 120 121 122 0 123
- 0 124 125 126 127 128 129 130 131 0 132 133 0 134 135 136
- 137 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 138 0 139 0 0 0 0 140 141 142 143 0 0 0 0
- 0 144 0 0 0 145 0 0 146 147 148 149 0 0 0 0
-.packtomark
-
-% ExpertEncoding
-mark
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 1 229 230 0 231 232 233 234 235 236 237 238 13 14 15 99
- 239 240 241 242 243 244 245 246 247 248 27 28 249 250 251 252
- 0 253 254 255 256 257 0 0 0 258 0 0 259 260 261 262
- 0 0 263 264 265 0 266 109 110 267 268 269 0 270 271 272
- 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288
- 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 0
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 304 305 306 0 0 307 308 309 310 311 0 312 0 0 313
- 0 0 314 315 0 0 316 317 318 0 0 0 158 155 163 319
- 320 321 322 323 324 325 0 0 326 150 164 169 327 328 329 330
- 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346
- 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362
- 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378
-.packtomark
-
-] readonly def
-
-% ---------------- Standard Charsets ---------------- %
-
-% We include an explicit 0 at the beginning of each charset.
-
-/StandardCharsets [
-
-% ISOAdobe
-mark
- 0
- 1 1 228 { } for
-.packtomark
-
-% Expert
-mark
- 0
- 1 229 230 231 232 233 234 235 236 237 238 13 14 15 99 239
- 240 241 242 243 244 245 246 247 248 27 28 249 250 251 252 253
- 254 255 256 257 258 259 260 261 262 263 264 265 266 109 110 267
- 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283
- 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299
- 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315
- 316 317 318 158 155 163 319 320 321 322 323 324 325 326 150 164
- 169 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341
- 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357
- 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373
- 374 375 376 377 378
-.packtomark
-
-% ExpertSubset
-mark
- 0
- 1 231 232 235 236 237 238 13 14 15 99 239 240 241 242 243
- 244 245 246 247 248 27 28 249 250 251 253 254 255 256 257 258
- 259 260 261 262 263 264 265 266 109 110 267 268 269 270 272 300
- 301 302 305 314 315 158 155 163 320 321 322 323 324 325 326 150
- 164 169 327 328 329 330 331 332 333 334 335 336 337 338 339 340
- 341 342 343 344 345 346
-.packtomark
-
-] readonly def
-
-% ---------------- Font loading ---------------- %
-
-% ------ Utilities ------ %
-
-/advance { % <n> advance -
- f cff eq { pos add /pos exch store } { pop } ifelse
-} bind def
-/next { % - next <byte>
- f read {
- 1 advance
- CFFDEBUG { ( ) print dup = } if
- } if
-} bind def
-/next2 { % - next2 <byte1> <byte2>
- f read {
- f read {
- 2 advance
- CFFDEBUG { ( ) print 1 index =only (,) print dup = } if
- } {
- 1 advance
- CFFDEBUG { ( ) print dup = } if
- } ifelse
- } if
-} bind def
-/nextstring { % <length> nextstring <string>
- dup 0 eq {
- pop ()
- } {
- string f exch readstring pop dup length advance
- CFFDEBUG { ( ) print dup == } if
- } ifelse
-} bind def
-/card8 % - card8 <card8>
- /next load
-def
-/card16 { % - card16 <card16>
- next2 exch 8 bitshift add
-} bind def
-/card32 { % - card32 <card32>
- card16 16 bitshift card16 add
-} bind def
-/offsetprocs [
- /card8 load
- /card16 load
- { card8 16 bitshift card16 add } bind
- /card32 load
-] readonly def
-/offsetproc { % <offsize> offsetproc <proc>
- 1 sub //offsetprocs exch get
-} bind def
-/offset { % <offsize> offset <offset>
- offsetproc exec
-} bind def
-/sid % - <sid> sid
- /card16 load
-def
-/Index { % <name> Index <name> <array>
- CFFDEBUG { (% reading Index: ) print dup = } if
- mark card16 dup 0 ne {
- 1 exch next offsetproc dup exec pop exch {
- dup exec dup 4 -1 roll sub 3 1 roll exch
- } repeat pop
- } if pop .packtomark
- CFFDEBUG { (% Index lengths = ) print dup === } if
- [ exch { nextstring } forall ] readonly
-} bind def
-/tokens { % - tokens <num1> ... <op#> (op# = 12 means EOF)
- {
- f read not { 12 exit } if
- CFFDEBUG { (..) print dup = } if
- 1 advance
- dup 12 eq { pop next 32 add exit } if
- dup 28 lt { exit } if
- dup 32 lt {
- 28 sub {
- { card16 32768 xor 32768 sub }
- { 4 offset dup 16#7fffffff gt { -1 32 bitshift add } if }
- { tokenreal }
- { 31 exit }
- } exch get exec
- } {
- dup 247 lt {
- 139 sub
- } {
- 247 sub {
- { next 108 add }
- { next 364 add }
- { next 620 add }
- { next 876 add }
- { next 108 add neg }
- { next 364 add neg }
- { next 620 add neg }
- { next 876 add neg }
- % 255 is deliberately omitted and will cause a rangecheck
- } exch get exec
- } ifelse
- } ifelse
- } loop
-} bind def
-/tokenbuf 100 string def
-/tokenput { % <index> <str> tokenput <index+length>
- dup length 3 1 roll
- tokenbuf 2 index 3 -1 roll putinterval add
-} bind def
-/tokenrealarray [
- (0)(1)(2)(3)(4)(5)(6)(7)(8)(9)(.)(E)
- (E-)
- () % ignore the invalid value
- (-)
- { exit } bind
-] readonly def
-/tokenreal { % - tokenreal <float>
- 0 {
- next exch 1 index -4 bitshift tokenrealarray exch get exec tokenput
- % We must leave the byte on the stack temporarily so that
- % the exit will see a consistent stack state.
- 1 index 15 and tokenrealarray exch get exec tokenput exch pop
- } loop
- tokenbuf 0 3 -1 roll getinterval cvr exch pop
-} bind def
-/Dict { % <opsdict> Dict -
- /opdict exch store {
- mark tokens
- CFFDEBUG { (tokens: ) print ] dup === mark exch aload pop } if
- opdict exch .knownget { exec } if cleartomark
- } loop cleartomark
-} bind def
-/idstring { % <sid> idstring <string|name>
- dup 391 lt { //StandardStrings } { 391 sub strings } ifelse exch get
-} bind def
-/idname { % <sid> idname <name>
- idstring dup type /nametype ne { cvn } if
-} bind def
-/subfilefilter { % <file> <length> subfilefilter <filter>
- % SubFileDecode interprets a length of 0 as infinite.
- dup 0 le { pop pop () 0 } if () /SubFileDecode filter
-} bind def
-
-% ------ Top dictionary ------ %
-
-/offput { % <offset> <proc> offput -
- 1 index 0 le
- CFFDEBUG { dup { (not ) print } if (queued: ) print 2 index =only ( ) print 1 index === } if
- { pop pop
- }
- { currentdict exch aload length 1 add packedarray cvx
- offsets 3 1 roll put
- }
- ifelse
-} bind def
-/queueput { % <font> <proc> queueput -
- 16#7fffffff offsets { pop .min } forall
- pos sub nextstring
- 3 1 roll aload length 2 add packedarray cvx
- [ queued aload pop counttomark 2 add -1 roll ]
- /queued exch store
-} bind def
-/printvk { % <value> <key> printvk <value> <key>
- CFFDEBUG { (\t% ) print dup =only ( = ) print 1 index === } if
-} bind def
-/xxput { % <value> <key> <dict> xxput -
- 3 1 roll exch put
-} bind def
-/putfi { % <value> <key> putfi -
- printvk FontInfo xxput
-} bind def
-/xdef { % <value> <key> xdef -
- exch def
-} bind def
-/pxdef { % <value> <key> pxdef -
- printvk xdef
-} bind def
-/topdictops mark
- 12 { CFFDEBUG { (\t% EOD) = } if exit }
- 0 { idstring /version putfi }
- 1 { idstring /Notice putfi }
- 32 { idstring /Copyright putfi }
- 2 { idstring /FullName putfi }
- 3 { idstring /FamilyName putfi }
- 4 { idstring /Weight putfi }
- 33 { 0 ne /isFixedPitch putfi }
- 34 { /ItalicAngle putfi }
- 35 { /UnderlinePosition putfi }
- 36 { /UnderlineThickness putfi }
- 37 { /PaintType pxdef }
- 38 { /FontType pxdef } % actually CharstringType
- 39 { counttomark array astore /FontMatrix pxdef }
- 13 { /UniqueID pxdef }
- 5 { counttomark array astore /FontBBox pxdef }
- 40 { /StrokeWidth pxdef }
- 14 { counttomark array astore /XUID pxdef }
- 15 {
- /charset printvk pop
- dup StandardCharsets length lt {
- StandardCharsets exch get /charset xdef
- } {
- { queuecharset } offput
- } ifelse
- }
- 16 {
- /Encoding printvk pop
- dup StandardEncodings length lt {
- /Encoding xdef
- } {
- { queueEncoding } offput
- } ifelse
- }
- 17 { { readCharStrings } offput }
- 18 { exch /readPrivate cvx 2 packedarray offput }
- % CIDFont operators
- 62 { % ROS, must be first in a CIDFont
- currentdict /FontType undef
- currentdict /Encoding undef
- currentdict /FontMatrix undef
- /CIDFontVersion 0 def
- /CIDFontRevision 0 def
- /CIDFontType 0 def
- /CIDCount 8720 def % Default value defined in CFF spec.
- 3 dict begin
- /Supplement pxdef
- idstring /Ordering pxdef
- idstring /Registry pxdef
- /CIDSystemInfo currentdict end def
- }
- 63 { /CIDFontVersion pxdef }
- 64 { /CIDFontRevision pxdef }
- 65 { /CIDFontType pxdef }
- 66 { /CIDCount pxdef }
- 67 { /UIDBase pxdef }
- 68 { { readFDArray } offput }
- 69 { { readFDSelect } offput }
- % This operator only appears in a FDArray element.
- % We don't really need it, so ignore an error.
- 70 { { idstring } .internalstopped { pop pop } { /FontName pxdef } ifelse }
-.dicttomark readonly def
-
-% readcharset and readFDSelect may require the length of CharStringArray,
-% but these structures may occur in the file before the CharStrings.
-% If that happens, use a hack: assume that all the data up to the next
-% queued read should be read.
-
-/charstringcount { % <font> charstringcount <count> true
- % <font> charstringcount <length> false
- /CharStringArray .knownget {
- length true
- } {
- % Hack: look for the next queued read.
- 16#7fffffff offsets { pop .min } forall
- pos sub false
- } ifelse
-} bind def
-
-/readCharStrings { % <font> readCharStrings -
- /CharStringArray Index put
-} bind def
-
-% ------ Charsets and encodings ------ %
-
-% Note: formats 1 and 2 can overflow the operand stack.
-% We'll fix this if it ever becomes necessary.
-/charsetcount {
- charstringcount { 1 sub } { 2 idiv } ifelse
-} bind def
-/charsetformats [
-{ [ 0 3 -1 roll charsetcount { sid } repeat ]
-} bind
-{ [ 0 3 -1 roll charsetcount {
- dup 0 eq { pop exit } if
- sid card8 1 add 2 index .min { exch 1 sub 1 index 1 add } repeat pop
- } loop ]
-} bind
-{ [ 0 3 -1 roll charsetcount {
- dup 0 eq { pop exit } if
- sid card16 1 add 2 index .min { exch 1 sub 1 index 1 add } repeat pop
- } loop ]
-} bind
-] readonly def
-/queuecharset { % <font> queuecharset -
- { readcharset } queueput
-} bind def
-/readcharset { % <data> <font> readcharset -
- begin 0 () /SubFileDecode filter /f exch store
- charsetformats next get currentdict exch exec /charset exch def end
-} bind def
-
-/encodingformats [
-{ 1 1 next { next exch Encoding 3 1 roll put } for
-} bind
-{ 1 next {
- next next 1 add {
- % Stack: gid code
- Encoding 1 index 3 index put
- exch 1 add exch 1 add
- } repeat pop
- } repeat pop
-} bind
-] readonly def
-/queueEncoding { % <font> queueEncoding -
- { readEncoding } queueput
-} bind def
-/readEncoding { % <data> <font> readEncoding -
- begin 0 () /SubFileDecode filter /f exch store
- /Encoding [ 256 { /.notdef } repeat ] def
- next encodingformats 1 index 127 and get exec
- 128 ge {
- % Read supplementary encodings.
- next {
- Encoding next sid idname put
- } repeat
- } if end
-} bind def
-
-% ------ FDArray and FDSelect ------ %
-
-/readFDArray { % <font> readFDArray -
- /FDarray Index exch pop exch
- 2 dict begin /f null def begin
- [ exch {
- dup length subfilefilter /f exch store
- 10 dict begin
- /FontType 2 def
- /PaintType 0 def
- /FontMatrix [0.001 0 0 0.001 0 0] def
- /Private 20 dict def
- //topdictops Dict currentdict end
- } forall ] /FDArray xdef end end
-} bind def
-
-/fdselectformats [
-% Note: this procedure can overflow the operand stack.
-% We'll fix this if it ever becomes necessary.
-{ [ exch charstringcount pop { card8 } repeat ] } bind % Format 0
-{ /FDSelect cvx /invalidfont signalerror } bind % Format 1
-dup % Format 2
-% The following procedure does not use excessive op-stack space.
-{ pop 65535 array card16 card16 exch % Format 3
- { % Stack: array previndex
- card8 card16
- exch 1 index 4 -1 roll
- exch 1 exch 1 sub
- { 3 index exch 2 index put } for pop
- } repeat
- % now resize the array to the final index.
- 0 exch getinterval
-} bind
-] readonly def
-
-/readFDSelect { % <font> readFDSelect -
- begin fdselectformats next get currentdict exch exec /FDSelect exch def end
-} bind def
-
-
-% ------ Private dictionary ------ %
-
-/deltarray { % -mark- <num1> ... deltarray <num1'> ...
- 0 counttomark 1 sub { counttomark -1 roll add dup } repeat pop
- counttomark array astore
-} bind def
-
-/privatedictops mark
- 12 { CFFDEBUG { (\t% EOD) = } if exit }
- 6 { deltarray /BlueValues pxdef }
- 7 { deltarray /OtherBlues pxdef }
- 8 { deltarray /FamilyBlues pxdef }
- 9 { deltarray /FamilyOtherBlues pxdef }
- 41 { /BlueScale pxdef }
- 42 { /BlueShift pxdef }
- 43 { /BlueFuzz pxdef }
- 10 { 1 array astore /StdHW pxdef }
- 11 { 1 array astore /StdVW pxdef }
- 44 { deltarray /StemSnapH pxdef }
- 45 { deltarray /StemSnapV pxdef }
- 46 { 0 ne /ForceBold pxdef }
- 47 { /ForceBoldThreshold pxdef }
- 48 { /lenIV pxdef }
- 49 { /LanguageGroup pxdef }
- 50 { /ExpansionFactor pxdef }
- 51 { /initialRandomSeed pxdef }
- 19 { PrivateStart add { readSubrs } offput }
- 20 { /defaultWidthX pxdef }
- 21 { /nominalWidthX pxdef }
- % Multiple Master fonts only
- 59 { /NDV pxdef }
- 60 { /CDV pxdef }
- 61 { /lenBuildCharArray pxdef }
-.dicttomark readonly def
-
-/readPrivate { % <font> <size> readPrivate -
- 2 dict begin
- /PrivateStart pos def
- f 3 1 roll exch 1 index f exch subfilefilter /f exch store
- dup /FontType get exch
- /Private get begin
- % Default lenIV to -1 even for Type 1 CharStrings.
- 2 ne { /lenIV -1 def } if
- //privatedictops Dict end
- exch /f exch store advance
- end
-} bind def
-
-/readSubrs { % <font> readSubrs -
- /Subrs Index put
-} bind def
-
-% ------ Main program ------ %
-
-% Clean up after finishing a font.
-/cleanupFont { % (currentdict) cleanupFont -
- % Remove unwanted entries.
- currentdict /charset undef
- currentdict /CharStringArray undef
-} bind def
-
-% Update the Encoding and CharStrings for a real font.
-/finishFont { % (currentdict) finishFont -
- % Construct the real Encoding.
- % The value of Encoding is either a number, for predefined
- % encodings, or an array of mixed GIDs and names.
- /Encoding mark Encoding
- CFFDEBUG { (Encoding: ) print dup === flush } if
- dup type /integertype eq {
- StandardEncodings exch get { idname } forall
- } {
- {
- dup type /integertype eq { charset exch get idname } if
- } forall
- } ifelse .packtomark def
- % Construct the CharStrings.
- % Note that they may only correspond to an initial
- % subset of the charset.
- /CharStrings charset length CharStringArray length .min dict def
- CFFDEBUG {
- charset length =only ( charset ) print
- CharStringArray length =only ( CharStringArray) =
- charset == flush
- } if
- 0 1 CharStrings maxlength 1 sub {
- dup CharStringArray exch get
- exch charset exch get idstring CharStrings xxput
- } for
- cleanupFont
-} bind def
-
-% Replace CharStrings with GlyphDirectory for a CIDFont;
-% Move GlobalSubrs to descendent fonts.
-/finishCIDFont { % (currentdict) finishCIDFont -
- % Construct the GlyphDirectory, similar to CharStrings.
- /FDBytes FDArray length 1 gt { 1 } { 0 } ifelse def
- /GlyphDirectory charset length CharStringArray length .min dict def
- CFFDEBUG {
- charset length =only ( charset ) print
- CharStringArray length =only ( CharStringArray) =
- charset == flush
- } if
- 0 1 GlyphDirectory maxlength 1 sub {
- dup CharStringArray exch get
- % If there is more than one FDArray entry, add the font
- % index to the beginning of each charstring.
- FDBytes 1 eq {
- FDSelect 2 index get
- 1 string dup 0 4 -1 roll put exch concatstrings
- } if
- exch charset exch get GlyphDirectory xxput
- } for
-
- Private /GlobalSubrs .knownget {
- FDArray {
- /Private get /GlobalSubrs 2 index put
- } forall
- pop
- Private /GlobalSubrs undef
- } if
-
- % Clean up.
- currentdict /FDSelect undef
- cleanupFont
-} bind def
-% We need to pass the file as a parameter for the sake of the PDF
-% interpreter. Also for the sake of PDF, a flag forces the font
-% to be defined as <resname> instead of the name embedded in the data.
-% This is needed for subsetted fonts; it is valid if the CFF
-% contains only a single font.
-/StartData { % <resname> <nbytes> StartData -
- currentfile exch subfilefilter false ReadData
-} bind def
-/ReadData { % <resname> <file> <forceresname> ReadData -
-
- % Initialize.
-
- 30 dict begin
- /forceresname exch def
- /cff exch def
- /pos 0 def
- /resname exch cvlit def
- /DEBUG CFFDEBUG def % bring the binding closer
-
- % Read the header.
-
- /f cff def
- /vmajor next def
- /vminor next def
- /hdrsize next def
- /aoffsize next def
- hdrsize 4 gt {
- hdrsize 4 sub dup advance
- f exch () /SubFileDecode filter flushfile
- } if
-
- % Read the Indexes.
-
- /names Index def
- /topdicts Index def
- /strings Index def
- /gsubrs Index def
-
- % Read the top Dicts.
-
- /offsets 50 dict def
- /queued [] def
- /opdict null def % reserve a slot
- /fonts [ topdicts {
- 0 () /SubFileDecode filter /f exch def
- 40 dict begin
- % Preload defaults that differ from PostScript defaults,
- % or that are required.
- /FontType 2 def
- /PaintType 0 def
- /FontMatrix [0.001 0 0 0.001 0 0] def
- /charset StandardCharsets 0 get def
- /Encoding 0 def
- /FontInfo 10 dict
- dup /UnderlinePosition -100 put
- dup /UnderlineThickness 50 put
- def
- /Private 20 dict
- gsubrs length 0 ne { dup /GlobalSubrs gsubrs put } if
- def
- //topdictops Dict
- currentdict end
- } forall ] def
-
- % Read other tables with queued offsets.
- % We process these in order so we can advance if needed.
- % The CFF file may not be positionable.
- { % outer loop since offsets may be updated when processing
- CFFDEBUG { (offsets: ) print [ offsets { pop } forall ] == } if
- [ offsets { pop } forall ] { lt } .sort % process in order of appearance
- {
- /f cff def
- CFFDEBUG { (queued offset: ) print dup =print flush (, current pos=) print pos = } if
- dup pos ne { dup pos sub nextstring pop } if % negative advance will cause error
- offsets exch 2 copy get 3 1 roll undef
- CFFDEBUG { (exec queued: ) print dup == } if
- exec
- } forall
- offsets length 0 eq { exit } if
- } loop
-
- % Process out-of-order tables.
-
- CFFDEBUG { queued length =only ( queued) = flush } if
- queued { exec } forall
-
- % Update Encoding and CharStrings.
-
- fonts {
- begin
- currentdict /CIDFontType known { finishCIDFont } { finishFont } ifelse
- end
- } forall
-
- % Wrap up.
-
- resname mark 0 1 fonts length 1 sub {
- CFFDEBUG { dup =only ( ) print flush } if
- dup names exch get
- forceresname { pop resname } if
- CFFDEBUG { dup == flush } if
- exch fonts exch get
- dup /CIDFontType known {
- % This is a CIDFont.
- dup /CIDFontName 3 index put
- 1 index exch /CIDFont defineresource
- } {
- % This is a font.
- dup /FontName 3 index put
- 1 index exch definefont
- } ifelse
- } for .dicttomark
- end % temporary dict
- end % FontSetInit ProcSet
- /FontSet defineresource pop
-
-} bind def
-
-% ---------------- Resource category definition ---------------- %
-
-currentdict end readonly
-
-languagelevel exch 2 .setlanguagelevel
-
-/FontSet /Generic /Category findresource dup length dict .copydict
-/Category defineresource pop
-
-/FontSetInit exch /ProcSet defineresource pop
-
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_cidcm.ps b/Master/tlpkg/tlgs/lib/gs_cidcm.ps deleted file mode 100644 index 9b410f7cc90..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cidcm.ps +++ /dev/null @@ -1,446 +0,0 @@ -% Copyright (C) 2000 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_cidcm.ps 8492 2008-01-18 21:50:38Z alexcher $
-% Extending Font resource category with CIDFont-CMap fonts.
-
-languagelevel 2 .setlanguagelevel currentglobal true setglobal
-
-
-% In the comments below, 'CSI' is an abbreviation/acronym for CIDSystemInfo.
-% We pre-scan resource files to retrieve the CSI from them.
-% First we define a hidden procset .prs_dict containing
-% necessary variables and procedures.
-% Then we redefine the old /Font category using this procset.
-
-% We maintain internal caches for the CSI values retrieved from
-% resource files. This supposes that document doesn't uninstall
-% resource files. To disable caching, set enable_cache to false.
-
-% We assume that names starting with '.prs' do not appear in resource files.
-% If this causes any problem, this prefix should be systematically changed
-% in this file. ('prs' is an abbreviation for 'prescan'.)
-
-25 dict begin
-
-% Define local variables :
-
-/.prs_dict currentdict def % self-reference (constant)
-/.prs_empty 0 dict readonly def
-/path_buffer 8192 string def
-/name_buffer 1024 string def
-/minus (-) 0 get def % character code constant for '-'
-/period (.) 0 get def % character code constant for '.'
-/CMap 10 dict def % CSI cache for CMaps
-/CIDFont 10 dict def % CSI cache for CIDFonts
-/enable_cache true def % set false to disable cache
-
-% The folloving variables are just placeholders for ones to be set
-% dynamically :
-/.prsFile 0 def % file to prescan
-/.prsResult 0 def % result of prescan
-/.prsDictCount 0 def % save the dictionary stack depth
-
-% Define a dummy CIDInit procset to use while pre-scanning :
-
-/DummyCIDInit 15 dict
-begin
-
- /begincmap {} def
- /usecmap {pop} bind def
-
- {stop} bind
- [ /begincodespacerange /endcodespacerange /beginnotdefchar /endnotdefchar
- /beginnotdefrange /endnotdefrange /begincidchar /endcidchar /begincidrange
- /endcidrange /endcmap /usefont /StartData
- ] {
- 1 index def
- } bind forall
- pop
-
-currentdict end def
-
-% Define a local 'findresource' for pre-scanning :
-% (it returns the dummy CIDInit instead of the regular CIDInit ProcSet)
-
-/findresource { % <InstName> <CatName> findresource <inst>
- 2 copy /ProcSet eq exch % /InstName /CatName bool /InstName
- /CIDInit eq and {
- pop pop //DummyCIDInit
- } {
- //findresource exec
- } ifelse
-} bind def
-
-% Define procedures for pre-scanning :
-
-/StopIfCSIDefined { % - StopIfCSIDefined -
-
- % Check if the dictionary stack contains a dictionary containing /CIDSystemInfo.
- % The search is limited to the top .prsDictCount dictionaries in the stack.
- % If so, retrieve the CSI, and execute stop to terminate the pre-scanning of the file.
- % Otherwise, do nothing, so the pre-scanning continues.
-
- countdictstack //.prs_dict /.prsDictCount get sub dup {
- currentdict /CIDSystemInfo .knownget {
- //.prs_dict exch /.prsResult exch put
- stop
- } if
- currentdict exch end
- } repeat {
- begin
- } repeat
-} bind def
-
-/PrescanFile { % - PrescanFile -
- { //.prs_dict /.prsFile get token {
- dup type % token type
- dup /nametype eq exch /operatortype eq or {
- dup xcheck {
- exec
- //StopIfCSIDefined exec
- } if
- } if
- } {
- stop
- } ifelse
- } loop
-} bind odef
-
-/GetCIDSystemInfoFromFile { % <file> GetCIDSystemInfoFromFile <CSI>
-
- % This procedure reads resource files with 'token',
- % executing the tokens untill /CIDSystemInfo appears to be defined.
- % Normally the resource file creates a new dictionary on
- % dictionary stack and defines /CIDSystemInfo in it.
- %
- % Returns an empty dictionary if no CIDSystemInfo is found.
-
- RESMPDEBUG { (cidcm GetCIDSystemInfoFromFile beg) = } if
- //.prs_dict begin
- /.prsFile exch def
- /.prsResult //.prs_empty def
- /.prsDictCount countdictstack def
- RESMPDEBUG { (cidcm GetCIDSystemInfoFromFile will PrescanFile.) = } if
- { //PrescanFile } stopped pop
- //.prs_dict /.prsResult get
- end
- RESMPDEBUG { (cidcm GetCIDSystemInfoFromFile end) = } if
-} bind def
-
-/GetCIDSystemInfo { % <InstName> <CatName> GetCIDSystemInfo <CSI>
-
- % Retrieve CSI, using caches.
-
- RESMPDEBUG { (cidcm GetCIDSystemInfo beg) = } if
- /Category findresource begin % /InstName
- dup ResourceStatus
- {
- pop 2 lt {
- FindResource /CIDSystemInfo .knownget not {
- //.prs_empty
- } if % CSI
- } { % /InstName
- currentdict /GetCIDSystemInfoFromMap .knownget {
- exec
- } if
- dup type /nametype eq
- {
- RESMPDEBUG { (cidcm GetCIDSystemInfo got a name.) = } if
- //.prs_dict Category get % /InstName CSIs
- dup 2 index known
- //enable_cache and {
- RESMPDEBUG { (cidcm GetCIDSystemInfo from cache.) = } if
- exch get % CSI
- } {
- RESMPDEBUG { (cidcm GetCIDSystemInfo from file.) = } if
- exch % CSIs /InstName
- dup //path_buffer ResourceFileName % CSIs /InstName (path)
- RESMPDEBUG { (cidcm GetCIDSystemInfo from file ) print dup = } if
- currentglobal exch true setglobal % CSIs /InstName g (path)
- mark exch % CSIs /InstName g [ (path)
- { (r) file } stopped {
- cleartomark //.prs_empty
- } {
- exch 1 index % CSIs /InstName g file [ file
- //GetCIDSystemInfoFromFile stopped {
- cleartomark closefile //.prs_empty
- } {
- exch pop exch closefile
- } ifelse
- } ifelse % CSIs /InstName g CSI
- exch setglobal % CSIs /InstName CSI
- dup 4 1 roll % CSI CSIs /InstName CSI
- put % CSI
- RESMPDEBUG {
- (cidcm GetCIDSystemInfo got from file : <<) print
- dup { exch //=string cvs print ( ) print
- //=string cvs print ( ) print
- } forall
- (>>) =
- } if
- } ifelse
- } if
- } ifelse
- } {
- pop //.prs_empty
- } ifelse
- end
- RESMPDEBUG { (cidcm GetCIDSystemInfo end) = } if
-} bind def
-
-/IsCompatibleCSI { % <CSI-M> <CSI-F> IsCompatibleCSI <bool>
-
- % The CSI in a CIDFont may be an array, a dict, or null.
- % If it is an array, it must be of 1 element, which is a dict.
- % In this case the dict is used for testing the compatibility.
- % Two dicts are compatible iff they contain same /Ordering and /Registry.
-
- exch % CSI-F CSI-M
- { dup type /arraytype eq {
- dup length 1 ne {
- pop pop false exit
- } if
- 0 get
- } if % CSI-F CSI-M
- dup type /dicttype ne {
- pop pop false exit
- } if % CSI-F <<CSI-M>>
- exch % <<CSI-M>> CSI-F
- dup type /dicttype ne {
- pop pop false exit
- } if % <<CSI-M>> <<CSI-F>>
- true % <<CSI-M>> <<CSI-F>> bEQ
- [/Registry /Ordering] {
- 2 index 1 index .knownget not {
- 1234567
- } if % <<CSI-M>> <<CSI-F>> bEQ /key vF
- exch % <<CSI-M>> <<CSI-F>> bEQ vF /key
- 4 index exch .knownget not {
- 7654321
- } if % <<CSI-M>> <<CSI-F>> bEQ vF vM
- eq and % <<CSI-M>> <<CSI-F>> bEQ
- } forall
- exch pop exch pop % bEQ
- exit
- } loop
-} bind def
-
-/IsWellComposed { % <CIDFontName> <CMapName> IsWellComposed <bool>
-
- % Check if the given CIDFont and CMap have compatible CSIs.
- exch % /CMapName /CIDFontName
- /CIDFont //GetCIDSystemInfo exec % /CMapName CSI-F
- dup type /dicttype eq {
- dup length 0 ne {
- exch % CSI-F /CMapName
- /CMap //GetCIDSystemInfo exec % CSI-F CSI-M
- //IsCompatibleCSI exec % bool
- } {
- pop pop false
- } ifelse
- } {
- pop pop false
- } ifelse
-} bind def
-
-/IsComposedFont { % <FontName> IsComposedFont <CIDFontName> <CMapName> true
- % <FontName> IsComposedFont false
-
- % Check if the given font name may be decomposed into CIDFont.CMap, CIDFont-CMap
- % or into CIDFont--CMap, such that CIDFont and CMap have compatible CSIs.
- % FontName
- dup type /stringtype ne {
- //name_buffer cvs
- } if % (FontName)
- { dup length 2 sub -1 1 {
- % (FontName) i
- 2 copy get dup //minus eq exch //period eq or {
- 2 copy 2 copy % (FontName) i (FontName) i (FontName) i
- 2 copy get //minus eq {
- 2 copy 1 sub get //minus eq {
- 1 sub
- } if
- } if % (FontName) i (FontName) i (FontName) i0
- 0 exch getinterval cvn % (FontName) i (FontName) i /CIDFontName
- 3 1 roll % (FontName) i /CIDFontName (FontName) i
- 1 add dup % (FontName) i /CIDFontName (FontName) i1 i1
- 5 index length % (FontName) i /CIDFontName (FontName) i1 i1 l
- exch sub getinterval cvn % (FontName) i /CIDFontName /CMapName
- 2 copy //IsWellComposed exec { % (FontName) i /CIDFontName /CMapName
- 4 2 roll pop pop % /CIDFontName /CMapName
- stop
- } if
- pop pop pop
- } {
- pop
- } ifelse % (FontName)
- } for
- pop
- } stopped
-} bind def
-
-/ComposeName { % <CIDFont> <CMap> <scr> ComposeName <CIDFont-CMap>
- dup dup 5 2 roll % (scr) (scr) /CIDFont /CMap (scr)
- 3 2 roll exch cvs length dup % (scr) (scr) /CMap l0 l0
- 4 -1 roll exch //minus put % (scr) /CMap l0
- 1 add dup % (scr) /CMap l1 l1
- 3 index dup length % (scr) /CMap l1 l1 (scr) L
- 2 index sub % (scr) /CMap l1 l1 (scr) LT
- 3 2 roll % (scr) /CMap l1 (scr) LT l1
- exch getinterval % (scr) /CMap l1 (scrT)
- 3 2 roll exch cvs length % (scr) l1 l2
- add 0 exch getinterval % (CIDFont-CMap)
-} bind def
-
-% Redefine the /Font category with CIDFont-CMap construction :
-
-% The following code supposes that the following names are not
-% defined in the old /Font category dictionary :
-% /IsComposedFont, /IsWellComposed .
-
-
-/Font /Category findresource dup length dict copy begin
-
-/FindResource { % <InstName> FindResource <inst>
- dup //ResourceStatus exec {
- pop pop //FindResource exec
- } {
- dup //IsComposedFont exec { % /FontName /CIDFontName /CMapName
- exch [ exch ] composefont % inst
- } {
- //FindResource exec
- } ifelse
- } ifelse
-} bind def
-
-/ResourceStatus { % <InstName> ResourceStatus <nStatus> <nSize> true
- % <InstName> ResourceStatus false
- dup //ResourceStatus exec {
- 3 2 roll pop true % nStatus nSize true
- } {
- //IsComposedFont exec { % /CIDFontName /CMapName
- /CMap resourcestatus { % /CIDFontName nStatusM nSizeM
- exch pop exch % nSizeM /CIDFontName
- /CIDFont resourcestatus { % nSizeM nStatusF nSizeF
- exch pop % nSizeF nSizeM
- dup 0 ge {
- exch dup 0 ge {
- add
- } {
- exch pop
- } ifelse
- } {
- pop
- } ifelse % nSize
- 2 exch true % nStatus nSize true
- } {
- pop pop pop false % work around buggy resource file
- } ifelse
- } {
- pop pop pop false % work around buggy resource file
- } ifelse
- } {
- false
- } ifelse
- } ifelse
-} bind def
-
-/ResourceForAll { % <template> <proc> <scratch> ResourceForAll -
-
- % We suppose that the resourceforall procedure does not
- % define or install new fonts, CMaps, and/or CIDFonts.
-
- % First we create 3 temporary dictionaries to store temporary data
- % about fonts, CMaps and CIDFonts.
- % These dictionaries must be created dynamically, to allow for a possible
- % recursive call to resourceforall from the resourceforall procedure.
- currentglobal false setglobal
- 20 dict 20 dict 20 dict % (templ) proc (scr) g <<CIDFont>> <<CMap>> <<Fonts>>
-
-
- % Store resource identifiers into local dictionaries
- % A resource instance can have a key that is not a name or a string. In this
- % case, resourceforall passes the key directly to proc instead of copying it
- % into the scratch string. This case can arise only for a resource instance
- % defined in virtual memory by a previous defineresource
-
- % Discard non-string keys of CIDFont and CMap because <CIDFontName>-<CMapName>
- % is only defined for names.
-
- { /.DisableResourceOrdering pop % gs_resmp accesses this through execstack - don't remove !
-
- 6 index [ 2 index {exch //null put} aload pop ] cvx bind 6 index //ResourceForAll exec
-
- (*) [ 3 index {exch dup type /stringtype eq { cvn dup put } { pop pop } ifelse } aload pop
- ] cvx bind 6 index /CMap resourceforall
-
- (*) [ 4 index {exch dup type /stringtype eq { cvn dup put } { pop pop } ifelse } aload pop
- ] cvx bind 6 index /CIDFont resourceforall
-
- exit
- } loop % This loop is a pattern for execstack_lookup - don't remove !
- 4 -1 roll setglobal % (templ) proc (scr) <<CIDFont>> <<CMap>> <<Fonts>>
-
- %% Make the list of fonts in the form (/Name status) :
-
- % (templ) proc (scr) <<CIDFont>> <<CMap>> <<Fonts>>
- dup {
- pop dup
- //ResourceStatus exec {
- pop 2 index % (templ) proc (scr) <<CIDFont>> <<CMap>> <<Fonts>> /Name nStatus <<Font>>
- 3 1 roll put % (templ) proc (scr) <<CIDFont>> <<CMap>> <<Fonts>>
- } {
- pop
- } ifelse
- } forall % (templ) proc (scr) <<CIDFont>> <<CMap>> <<Fonts>>
-
- %% Add CIDFont-CMap to it (filtering duplicates) :
-
- 3 2 roll {
- 3 index {
- 3 1 roll % (templ) proc (scr) <<CMap>> <<Font>> /CIDFont /CMap /CIDFont /CMap
- 6 index //ComposeName exec % (templ) proc (scr) <<CMap>> <<Font>> /CIDFont /CMap (Font)
- dup 8 index .stringmatch {
- cvn % (templ) proc (scr) <<CMap>> <<Font>> /CIDFont /CMap /Font
- dup 4 index exch known {
- pop pop
- } {
- 2 index % (templ) proc (scr) <<CMap>> <<Font>> /CIDFont /CMap /Font /CIDFont
- 4 2 roll % (templ) proc (scr) <<CMap>> <<Font>> /Font /CIDFont /CIDFont /CMap
- //IsWellComposed exec {
- exch 2 index exch 2 put % (templ) proc (scr) <<CMap>> <<Font>> /CIDFont
- } {
- exch pop
- } ifelse
- } ifelse
- } {
- pop pop
- } ifelse
- dup % (templ) proc (scr) <<CMap>> <<Font>> /CIDFont /CIDFont
- } forall
- pop pop % (templ) proc (scr) <<CMap>> <<Font>>
- } forall % (templ) proc (scr) <<CMap>> <<Font>>
- exch pop % (templ) proc (scr) <<Font>>
- 4 3 roll pop % proc (scr) <<Font>>
-
- % Make the enumerator and apply it :
- /MappedCategoryRedefiner /ProcSet findresource /MakeResourceEnumerator get exec exec
-} bind def
-
-
-currentdict end /Font exch /Category defineresource pop
-end
-setglobal .setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_ciddc.ps b/Master/tlpkg/tlgs/lib/gs_ciddc.ps deleted file mode 100644 index 3d78d0ed0c6..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_ciddc.ps +++ /dev/null @@ -1,214 +0,0 @@ -% Copyright (C) 1994, 1996, 1997, 1998, 1999, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_ciddc.ps 7873 2007-04-23 13:27:47Z leonardo $
-% Define Decoding and CIDDecoding resource categories and related procsets.
-
-languagelevel 2 .setlanguagelevel
-currentglobal true setglobal
-
-%----------------ParseDecoding procset----------------------------
-
-/ParseDecoding <<
-
-/Parse % <resource_name> <num_tokens> Parse -
-{ dict begin % /ResName
- 0 % /ResName nCode
- { currentfile token not {
- exit
- } if % /ResName nCode token
- dup type /integertype eq { % /ResName nCode
- exch pop
- } {
- 1 index def % /ResName nCode
- } ifelse
- } loop % /ResName nCode
- pop % /ResName
- currentdict end /Decoding % /ResName <<inst>> /Decoding
- defineresource pop
-} bind
-
->> /ProcSet defineresource pop
-
-%----------------Decoding category----------------------------
-
-/Generic /Category findresource dup length dict copy
-dup /InstanceType /dicttype put
-/Decoding exch /Category defineresource pop
-
-%----------------ParseCMap_Inverse procset----------------------------
-
-/ParseCMap_Inverse <<
- /findresource { pop } bind
- /defineresource { pop pop } bind
- /dict {}
- /def { pop pop } bind
- /dup null
- /begin { pop } bind
- /end {}
- /currentdict null
- /CMapName null
- /usecmap { pop } bind
- /begincmap {}
- /endcmap {}
- /begincodespacerange { pop mark } bind
- /endcodespacerange { cleartomark } bind
- /beginnotdefrange { pop mark } bind
- /endnotdefrange { cleartomark } bind
- /beginbfchar { pop mark } bind
- /endbfchar { pop mark } bind
- /beginbfrange { begincidrange }
- /endbfrange { endcidrange }
- /begincidchar { beginbfchar }
- /endcidchar { endbfchar }
- /begincidrange { pop mark } bind
- /endcidrange { cleartomark } bind
->> % Just keep it on stack for a while.
-
-% Now we define another dict for local binding, than merge it with the previous one :
-dup length 5 add dict begin
-
- /.Ranges 40 dict def % Key = CID/256, value = array of 256 integer codes.
- //.Ranges /CIDCount 0 put
-
- /.StringToInt % <string> .StringToInt <integer>
- { 0 exch { exch 8 bitshift add } forall
- } bind def
-
- /.SetCouple % <I> <b> .SetCouple -
- { exch % b I
- dup 256 idiv % b I I0
- dup //.Ranges exch known not {
- dup //.Ranges exch 256 array put
- } if % b I I0
- //.Ranges exch get % b I [Range]
- exch 256 mod % b [Range] I1
- 2 copy get % b [Range] I1 e
- dup //null ne {
- % We've got char code duplicates for same CID.
- dup type /integertype eq {
- 4 3 roll % [Range] I1 e b
- 2 array astore put %
- } {
- dup length 1 add dup dup array dup % b [Range] I1 D l l D' D'
- 3 2 roll 0 exch getinterval % b [Range] I1 D l D' D''
- 4 3 roll exch copy pop % b [Range] I1 l D'
- dup 3 2 roll 1 sub % b [Range] I1 D' D' l-1
- 6 5 roll % [Range] I1 D' D' l-1 b
- put put %
- } ifelse
- } {
- pop 3 2 roll put %
- } ifelse
- } bind def
-
- /endcidrange
- { % Writes the inversed CMap to .Ranges
- counttomark 3 idiv { % (b) (e) I
- exch .StringToInt % (b) I e
- 3 2 roll .StringToInt % I e b
- % Note : this code does't handle multidimentional CID ranges.
- % fixme : optimize below.
- dup 3 2 roll exch sub 1 add % I b d
- { 2 copy //.SetCouple exec % I b
- 1 add exch 1 add exch
- } repeat % I b
- pop % I
- dup //.Ranges /CIDCount get gt { % I
- dup //.Ranges exch /CIDCount exch put
- } if % I
- pop
- } repeat
- pop % mark
- } bind def
-
- /.GetCIDDecoding % - .GetCIDDEcoding <dict>
- { //.Ranges dup length dict copy
- //.Ranges //.PurgeDict exec
- //.Ranges /CIDCount 0 put
- } bind def
-
-currentdict end
-exch copy % Merge the dicts - see above.
-/ProcSet defineresource pop
-
-%----------------CIDDecoding category----------------------------
-% Note that we put all instances in global memory - see FindResource.
-
-/Generic /Category findresource dup length dict copy
-begin
- /Category /CIDDecoding def
- /InstanceType /dicttype def
-
- /.CMapChooser <<
- % This lists CMaps to inverse and unite for creating a CIDDecoding.
- % Choose by FAPIcidfmap.Registry concatenated with TrueType encoding ID.
- % Font renderer must provide the glyph substitution internally.
-
- /CNS1.Big5 [ /ETen-B5-H /ETen-B5-V ]
- /CNS1.Unicode [ /UniCNS-UCS2-H /UniCNS-UCS2-V]
- /GB1.GB2312 [ /GBK-EUC-H /GBK-EUC-V ]
- /GB1.Unicode [ /UniGB-UCS2-H /UniGB-UCS2-V ]
- /Japan1.ShiftJIS [ /90ms-RKSJ-H /90ms-RKSJ-V ]
- /Japan1.Unicode [ /UniJIS-UCS2-H /UniJIS-UCS2-V]
- /Japan2.ShiftJIS [ /90ms-RKSJ-H /90ms-RKSJ-V ]
- /Japan2.Unicode [ /UniHojo-UCS2-H ]
- /Korea1.Johab [ /KSC-Johab-V /KSC-Johab-H ]
- /Korea1.Wansung [ /KSCms-UHC-V /KSCms-UHC-H ]
- /Korea1.Unicode [ /UniKS-UCS2-H /UniKS-UCS2-V ]
- /Identity.Symbol [ /Identity-H /Identity-V ]
- /Unicode.Unicode [ /Identity-UTF16-H ]
- >> def
-
- /.MakeInstance % <name> .MakeInstance <inst>
- { dup % /Name /Name
- //.CMapChooser exch .knownget not {
- (Can't build /) print =string cvs print ( /CIDDecoding resource. See gs_ciddc.ps . ) =
- /findresource cvx /undefinedresource signalerror
- } if % /Name [CMaps]
- exch pop % [CMaps]
- /CMap /Category findresource % [CMaps] <CMapCategory>
- /ParseCMap_Inverse /ProcSet findresource % [CMaps] <CMapCategory> <PCI>
- 3 2 roll { % <CMapCategory> <PCI> /CMapName
- 3 2 roll begin % <PCI> /CMapName
- dup .ResourceFile not {
- (Can't find CMap ) print =string cvs print ( building a CIDDecoding resource. ) =
- /findresource cvx /undefinedresource signalerror
- } if
- currentdict end exch % <PCI> /CMapName <CMapCategory> file
-
- 3 index begin
- cvx exec % <PCI> /CMapName <CMapCategory>
- end
- exch pop exch % <CMapCategory> <PCI>
- } forall
- exch pop begin %
- .GetCIDDecoding
- end
- } bind def
-
- /FindResource % <name> FindResource <dict>
- { currentglobal exch % bGlobal /InstName
- true setglobal
- dup //.MakeInstance exec % bGlobal /InstName <Inst>
- DefineResource % bGlobal <Inst>
- exch setglobal % <Inst>
- } bind def
-
-currentdict end
-/CIDDecoding exch /Category defineresource pop
-
-setglobal
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_cidfm.ps b/Master/tlpkg/tlgs/lib/gs_cidfm.ps deleted file mode 100644 index 48f1b2d888d..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cidfm.ps +++ /dev/null @@ -1,129 +0,0 @@ -% Copyright (C) 2000 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_cidfm.ps 8022 2007-06-05 22:23:38Z giles $
-% Redefine CIDFont category with cidfmap .
-
-languagelevel 2 .setlanguagelevel
-
-4 dict begin
-/CategoryName /CIDFont def
-
-/MapFileName (cidfmap) def
-
-/IsMyRecord % <raw_record> -> <raw_record> bool
-{ % Only for client's needs.
- dup type /nametype eq
-} bind def
-
-/RecordVirtualMethods 3 dict begin
-
- /MakeInstance % <Name> <record> MakeInstance <Name> <Instance> <size>
- { % We know that currentdict is the category.
- /Substitute get FindResource % /Name <<CIDFont>>
- dup length dict copy % /Name <<CIDFont>>
- 1 index ResourceStatus pop exch pop % /Name <<CIDFont>> size
- } bind def
-
- /GetFilePath % <scratch> <Name> <record> GetFilePath <filepath>
- { % We know that currentdict is the category.
- exch pop
- /Substitute get exch ResourceFileName
- } bind def
-
- /GetSize % <Name> <record> GetSize <size>
- { % We know that currentdict is the category.
- /Substitute get ResourceStatus {
- exch pop exch pop
- } {
- /undefinedresource signalerror
- } ifelse
- } bind def
-
- /GetCSI % <record> GetCSI null
- % <record> GetCSI dict
- { % We know that currentdict is the category.
- RESMPDEBUG { (cidfm GetCSI beg ) = } if
- /Substitute get % /Name
- GetCIDSystemInfoFromMap
- RESMPDEBUG { (cidfm GetCSI end ) print dup = } if
- } bind def
-
- /IsActive % <record> IsActive <bool>
- { pop true
- } bind def
-
-currentdict end def
-
-/VerifyMap % <raw_map> VerifyMap -
-{ % Checks for vicious substitution cycles.
- dup length dict copy % <<map>>
- dup length dict % <<map>> <<temp>>
- { % Choose a random record :
- true 2 index { % <<map>> <<temp>> true /Name /Subs
- 3 2 roll pop false exit % <<map>> <<temp>> /Name /Subs false
- } forall
- { exit % <<map>> <<temp>>
- } if % <<map>> <<temp>> /Name /Subs
- % Move the substitution chain to <<temp>>, checking for a cycle :
- 3 index 2 index undef % <<map>> <<temp>> /Name /Subs
- exch 2 index exch 0 put % <<map>> <<temp>> /Subs
- { //IsMyRecord exec not {
- % Not a substitution, the chain terminates.
- pop exit % <<map>> <<temp>>
- } if % <<map>> <<temp>> /Subs
- 1 index 1 index known {
- (Vicious substitution cycle in map file with the entry ) print =string cvs print ( .) =
- /VerifyMap cvx /undefinedresource signalerror
- } if % <<map>> <<temp>> /Subs
- 1 index 1 index 0 put
- dup 3 index exch .knownget not { % <<map>> <<temp>> /Subs
- % No more substitutions, the chain terminates.
- pop exit % <<map>> <<temp>>
- } if % <<map>> <<temp>> /Subs /Subs1
- exch % <<map>> <<temp>> /Subs1 /Subs
- 3 index exch undef % <<map>> <<temp>> /Subs1
- } loop
- % Not cycled, now purge the <<temp>> :
- { % Choose a random record :
- true 1 index { % <<map>> <<temp>> true /Name /Subs
- 3 2 roll pop false exit % <<map>> <<temp>> /Name /Subs false
- } forall
- { exit % <<map>> <<temp>>
- } if % <<map>> <<temp>> /Name /Subs
- % Remove it :
- pop 1 index exch undef % <<map>> <<temp>>
- } loop
- } loop
- pop pop %
-} bind def
-
-/PreprocessRecord % <map> <Name> <raw_record> PreprocessRecord <map> <Name> <record> <bool>
-{ //IsMyRecord exec {
- 1 dict begin
- /Substitute exch def
- /RecordVirtualMethods //RecordVirtualMethods def
- currentdict end
- true
- } {
- false
- } ifelse
-} bind def
-
-currentdict end
-
-/MappedCategoryRedefiner /ProcSet findresource /Redefine get exec
-
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_cidfn.ps b/Master/tlpkg/tlgs/lib/gs_cidfn.ps deleted file mode 100644 index 0daf0d57a4d..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cidfn.ps +++ /dev/null @@ -1,404 +0,0 @@ -% Copyright (C) 1995, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_cidfn.ps 7558 2007-01-03 10:30:52Z leonardo $
-% ProcSet for implementing CIDFont and CIDMap resources.
-% When this is run, systemdict is still writable.
-
-% ---------------- Defining CIDFont resources ---------------- %
-
-% Define a CIDFont resource. This is the defineresource implementation for
-% the CIDFont resource category.
-
-/.checkfonttype { % <cidfont> <fonttype> .checkfonttype <cidfont> <new?>
- 1 index /FID known {
- 1 index /FontType get ne {
- /definefont cvx /invalidfont signalerror
- } if false
- } {
- 1 index /FontType 3 -1 roll put true
- } ifelse
-} bind def
-
-/.cidfonttypes where { pop } { /.cidfonttypes 6 dict def } ifelse
-.cidfonttypes
-
-30 dict begin
-
-% The key in .cidfonttypes is the CIDFontType value;
-% the value is a procedure that takes a font name and the CIDFont dictionary
-% and replaces the latter with a real font.
-
-% ------ CIDFontType 0 (FontType 9) ------ %
-
-% We add the following entries to the CIDFont dictionary, in addition to
-% the ones documented by Adobe:
-% SubrCache - dictionary for caching Subr arrays
-% For CIDFonts where we read the data from disk incrementally:
-% GlyphData is 0 (arbitrary)
-% DataSource - a ReusableStreamDecode filter for the data
-% We also add a FID entry, and possibly a Subrs entry, to each element of
-% FDArray.
-
-dup 0 {
- 9 .checkfonttype {
- /CIDInit /ProcSet findresource begin
- .completefont9
- end
- } if
- 1 index exch .buildfont9 exch pop
-} put % Don't bind it here, because gs_fapi.ps redefines .buildfont9
-
-% Add entries to a new CIDFontType 0 font per documentation (FontMatrix)
-% or for .buildfont9 (FDArray.Private.Subrs).
-/.completefont9 { % <cidfont0> .completefont9 <cidfont0>
- currentglobal 3 1 roll dup gcheck setglobal
- dup /FontMatrix known not {
- dup /FontMatrix [0.001 0 0 0.001 0 0] put
- dup /FDArray get {
- currentglobal exch dup gcheck setglobal
- dup /FontMatrix get [1000 0 0 1000 0 0] matrix concatmatrix
- /FontMatrix exch put
- setglobal
- } forall
- } if
- dup /FDArray get {
- % Read the Subrs if necessary.
- dup /Private get dup /Subrs known not {
- dup /SubrCount .knownget {
- % Stack: font Private SubrCount
- currentglobal 3 1 roll 1 index gcheck setglobal
- array 1 index /Subrs 3 -1 roll put
- % Stack: font global Private
- 2 index begin begin .loadsubrs end end
- setglobal
- } {
- pop
- } ifelse readonly pop
- } {
- pop pop
- } ifelse
- } forall
- 3 -1 roll setglobal
-} bind def
-
-% Read some Subrs for the current Type 1 subfont.
-% The subfont's Private dict is currentdict; the CIDFont itself is the
-% next dictionary on the stack.
-/.readsubrs { % <Subrs> <start> .readsubrs <Subrs>
- 1 SubrCount 1 sub {
- dup SDBytes mul SubrMapOffset add
- dup SDBytes .readint exch SDBytes add SDBytes .readint
- 1 index sub string ReadString 2 index 3 1 roll put
- } for
-} bind def
-
-% Ensure that all the Subrs for the current Type 1 subfont are loaded.
-% The subfont's Private dict is currentdict; the CIDFont itself is the
-% next dictionary on the stack.
-/.loadsubrs {
- Subrs length 0 ne {
- SubrCache SubrMapOffset .knownget {
- % We've already loaded some Subrs at this offset.
- % Make sure we've got as many as we need.
- dup length SubrCount lt {
- % We need to load more.
- SubrCount array exch 1 index copy length .readsubrs
- SubrCache SubrMapOffset 2 index put
- } if
- } {
- % We haven't loaded any Subrs at this offset yet.
- SubrCount array 0 .readsubrs
- SubrCache SubrMapOffset 2 index put
- } ifelse
- Subrs copy pop
- } if
-} bind def
-
-% ------ CIDFontType 1 (FontType 10) ------ %
-
-dup 1 {
- 10 .checkfonttype pop
- 1 index exch .buildfont10 exch pop
-} put % Don't bind it here because gs_fapi.ps redefines .buildfont10
-
-% ------ CIDFontType 2 (FontType 11) ------ %
-
-dup 2 {
- 11 .checkfonttype pop
- 1 index exch .buildfont11 exch pop
-} put % Don't bind it here because gs_fapi.ps redefines .buildfont11
-
-pop % .cidfonttypes
-
-% ---------------- Reading CIDFontType 0 files ---------------- %
-
-/StartData { % <(Binary)|(Hex)> <datalength> StartData -
- % (currentdict is CID font dict)
- % If we're loading a resource file and the data format is
- % binary, we can just save a pointer to the data and load it
- % incrementally.
- mark {
- % Previous versions of this code made provisions for
- % reading hex-encoded data incrementally. Since hex data
- % doesn't seem to be used in practice, we no longer bother.
- 2 index (Binary) ne { stop } if
- currentfile .currentresourcefile ne { stop } if
- % Hack: the pdfwrite driver relies on finalization to write
- % out fonts. However, the font may be finalized after the
- % resource file, in which case the resource file will be
- % closed. So if the current output device is pdfwrite,
- % don't use incremental loading.
- currentdevice .devicename /pdfwrite eq { stop } if
- currentfile fileposition
- } .internalstopped {
- % File is not positionable, or uses hex data.
- % Load the data now.
- cleartomark exch
- currentfile exch
- (Hex) eq { /ASCIIHexDecode filter } if
- exch
- % Stack: file length
- dup 65400 le {
- % readstring with a 0-length string causes a rangecheck,
- % but a data length of 0 is allowed.
- string dup () ne { 1 index exch readstring pop } if
- } {
- mark 3 1 roll {
- % Stack: mark str ... file length
- dup 0 eq { pop exit } if
- dup 65400 .min dup string 3 index exch readstring pop
- % Stack: mark str ... file length newstrlen newstr
- 4 1 roll sub
- } loop
- counttomark 1 add 1 roll ]
- } ifelse
- /GlyphData exch def
- dup currentfile eq { pop } { closefile } ifelse
- } {
- % File is positionable and binary, just save a pointer.
- % Stack: (Binary) length -mark- pos
- /GlyphData 0 def
- exch pop 3 -1 roll pop exch
- % Stack: pos length
- /DataSource currentfile 2 index () .subfiledecode true .reusablestream def
- currentfile 3 1 roll add setfileposition
- } ifelse
- /SubrCache 10 dict def
- CIDFontName currentdict /CIDFont defineresource pop
- end % CID font dict
- end % resource category dict
-} bind def
-
-% Some Adobe fonts include the line
-% /Setup /cid_Setup load def
-% This is apparently included only to prevent proper, conforming PostScript
-% interpreters (as opposed to ATM or a special Adobe font loader) from
-% loading the font, since Setup is not referenced anywhere else in the file.
-/cid_Setup { } def
-
-% ------ Generic ------ %
-
-% Read a string at a given offset in a "file" (binary file or
-% GlyphData in RAM).
-/ReadString { % <pos> <string> ReadString <string>
- GlyphData 0 eq {
- % Read from the file.
- DataSource 3 -1 roll setfileposition
- DataSource exch readstring pop
- } {
- % Read from a string or an array of strings.
- GlyphData .stringsreadstring
- } ifelse
-} bind def
-/.stringsreadstring % <pos> <string> <strings> .stringsreadstring
- % <vmstring>
-{ dup type /stringtype eq
- { 3 1 roll length getinterval
- }
- { { % Stack: pos string glyphdata
- dup 0 get length dup 4 index gt { exit } if
- 4 -1 roll exch sub 3 1 roll
- dup length 1 sub 1 exch getinterval
- }
- loop
- % Stack: pos string glyphdata glyphdata[0]length
- % We know no request can span more than 2 strings.
- 3 index 3 index length add 1 index le
- { % Request fits in a single string: just return a substring.
- pop 0 get 3 1 roll length getinterval
- }
- { % Request spans 2 strings. Copy the first part.
- 1 index 0 get 4 index 3 -1 roll 1 index sub getinterval
- 2 index copy
- % Copy the second part.
- % Stack: pos str glyphdata str1
- length exch 1 get 0 3 index length
- 3 index sub getinterval 2 index 3 1 roll putinterval
- exch pop
- }
- ifelse
- }
- ifelse
-} bind def
-
-% Interpret a byte string as a (big-endian) integer.
-/.cvbsi % <bytes> .cvbsi <int>
-{ 0 exch { exch 8 bitshift add } forall
-} bind def
-
-% Read an integer from binary data.
-/.readint % <pos> <nbytes> .readint <int>
-{ string ReadString .cvbsi
-} bind def
-
-currentdict end
-
-% ---------------- Rendering ---------------- %
-
-% ------ CIDFontType 0 ------ %
-
-/.readglyphdata {
- currentfont exch .type9mapcid
- FDArray exch get exch
-} bind def
-
-% BuildGlyph procedure for CIDFontType 0.
-% The name %Type9BuildGlyph is known to the interpreter.
-/.cid0buildstring 10 string def
-(%Type9BuildGlyph) cvn { % <cidfont> <cid> %Type9BuildGlyph -
- .currentglobal 3 1 roll 1 index gcheck .setglobal
- 1 index begin
- dup .readglyphdata dup null eq {
- % Substitute CID 0. **** WRONG ****
- pop pop 0 .readglyphdata
- } if
- % Stack: cidfont cid subfont charstring
- dup null eq { pop pop pop pop } { %**** WRONG ****
- 4 -1 roll pop
- 3 1 roll exch dup 4 -1 roll 0 0 moveto
- 3 index /FontType get 2 eq { .type2execchar } { .type1execchar } ifelse
- } ifelse %**** WRONG ****
- end
- .setglobal
-} bind def
-
-% ------ CIDFontType 2 ------ %
-
-% BuildGlyph procedure for CIDFontType 2.
-% The name %Type11BuildGlyph is known to the interpreter.
-(%Type11BuildGlyph) cvn { % <cidfont> <cid> %Type11BuildGlyph -
- % We must be prepared for out-of-range CIDs.
- 2 copy { .type11mapcid } .internalstopped {
- pop /CharStrings get /.notdef get
- } if
- % Stack: cidfont cid glyphindex
- 1 index exch .type42execchar
-} bind def
-
-% ---------------- Define resources ---------------- %
-
-languagelevel exch 2 .setlanguagelevel
-
-% Define the CIDInit ProcSet resource.
-% The ProcSet dictionary is still on the stack.
-
-% We might have loaded CMap support already. However, Adobe's
-% protected font downloader defines a CIDInit ProcSet that will be
-% loaded from the filesystem later, so we must check specifically
-% for the ProcSet being defined in VM.
-/CIDInit /ProcSet 2 copy resourcestatus { pop 0 eq } { false } ifelse {
- pop pop findresource dup length 4 index length add dict .copydict
- 4 -1 roll exch .copydict
-} {
- 3 -1 roll
-} ifelse exch defineresource pop
-
-% Define the CIDFont resource category.
-% We break out .buildcidfont because it appears that at least for
-% Type 32 (CIDFontType 4) fonts, the font can be registered in the Font
-% category with only a CIDFontType and no FontType.
-/.buildcidfont { % <name> <fontdict> .buildcidfont
- % <name> <cidfont>
- systemdict /ProvideUnicode .knownget not { false } if {
- /FontEmulationProcs /ProcSet findresource
- /ProvideUnicodeDecoding get exec
- } if
- dup /CIDFontType get //.cidfonttypes exch get exec
-} odef
-
-/CIDFont /Generic /Category findresource dup length dict .copydict
-dup /InstanceType /dicttype put
-dup /DefineResource {
- .buildcidfont
- dup /OrigFont known not {
- dup dup /OrigFont exch .growput % CPSI does it. Adding just for CET 33_all.PS conformity.
- } if
- dup /PaintType known not {
- dup /PaintType 0 .growput % CPSI does it. Adding just for CET 33_all.PS conformity.
- } if
- /Generic /Category findresource /DefineResource get exec
-} put
-% CIDFonts may be defined in CFF OpenType files.
-% Check for this here.
-/.loadcidfontresource {
- dup .ResourceFile {
- {.loadfont} .execasresource
- } {
- dup /undefinedresource signalerror
- } ifelse
-} bind def
-dup /.LoadResource {
- currentglobal {
- .loadcidfontresource
- } {
- true setglobal {.loadcidfontresource} stopped false setglobal {stop} if
- } ifelse
-} bind put
-
-/Category defineresource pop
-
-% Add the new FontType resources.
-
-9 1 11 { dup /FontType defineresource pop } for
-
-% Add the new FMapType resource.
-
-9 dup /FMapType defineresource pop
-
-% Define the CIDMap resource category.
-% These aren't documented, but it's clear what they are for:
-% to give names to CIDMaps for CIDFontType 2 fonts.
-
-/CIDMap /Generic /Category findresource dup length dict .copydict
-dup /.CheckResource {
- % Allow a string, an array of strings, or (as of Adobe release 3011)
- % a dictionary.
- dup type dup dup /stringtype eq exch /dicttype eq or {
- pop true
- } {
- dup /arraytype eq exch /packedarraytype eq or {
- true exch { type /stringtype eq and } forall
- } {
- false
- } ifelse
- } ifelse
-} bind put
-/Category defineresource pop
-
-.setlanguagelevel
-
-%% Replace 1 (gs_ciddc.ps)
-(gs_ciddc.ps) runlibfile
diff --git a/Master/tlpkg/tlgs/lib/gs_cidtt.ps b/Master/tlpkg/tlgs/lib/gs_cidtt.ps deleted file mode 100644 index fc0dbc30357..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cidtt.ps +++ /dev/null @@ -1,141 +0,0 @@ -% Copyright (C) 2000 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_cidtt.ps 8190 2007-08-14 20:48:29Z till $
-% Redefine CIDFont category with an emulation with True Type fonts.
-
-languagelevel 2 .setlanguagelevel
-
-15 dict begin % a temporary dictionary for local binding.
-
-%------------------Copy the FontEmulationProcs here : -------------------
-
-/FontEmulationProcs /ProcSet findresource {
- def
-} forall
-
-currentdict /super.complete_instance currentdict /complete_instance get put
-
-%-------Auxiliary procedures for building CIDFontType 2 from TT file -----------
-
-/GenerateCIDMap % <font> GenerateCIDMap <font>
-{ begin
- % Obtain the maximal CID :
- % This implementation doesn't check whether glyphs really present.
- Decoding /CIDCount get /CIDCount exch def
- % Prepare the CIDMap structure :
- /CIDMap [
- CIDCount 22000 le {
- CIDCount 2 mul string
- } {
- 44000 string
- CIDCount 44000 gt {
- % need three strings
- 44000 string % 22000 2 mul string
- CIDCount 44000 sub 2 mul string
- } {
- CIDCount 22000 sub 2 mul string
- } ifelse
- } ifelse
- ] def
- % Now fill it :
- Decoding TT_cmap SubstNWP GDBytes CIDMap .fillCIDMap
- currentdict end
-} bind def
-
-/load_sfnts % <FontDict> load_sfnts <FontDict>
-{ % Read the True Type file from the path /Path, and buld /sfnts,
- % skipping glyf and loca.
- dup /Path get % <font> (path)
- QUIET not {
- (Loading a TT font from ) print dup print
- ( to emulate a CID font ) print 1 index /CIDFontName get =only ( ... ) print
- } if
- (r) file dup % <font> file file
- 3 1 roll % file <font> file
- 1 index /SubfontID .knownget not { 0 } if % file <font> file SubfontID
- .load_tt_font_stripped exch copy % file <font>
- QUIET not {
- (Done.) =
- } if
- dup 3 1 roll % <font> file <font>
- exch /File exch put % <font>
- dup dup /CIDSystemInfo get /Ordering get (.) % <font> () ()
- 2 index /Decoding get =string cvs % <font> () () ()
- concatstrings concatstrings cvn /Decoding exch put % <font>
- //ChooseDecoding exec % <font>
- //GenerateCIDMap exec % <font>
-} bind def
-
-%-----------TrueType-specific methods for category redefinition : -----------
-
-/RefinePath % <FontDict> RefinePath <FontDict>
-{ dup begin
- Path .libfile {
- dup .filename {
- currentdict exch /Path exch put
- } if
- closefile
- } {
- (Can't find the font file ) print =
- /findfont cvx /undefinedfilename signalerror
- } ifelse
- end
-} bind def
-
-/complete_instance % <font_name> <FontDict> <Options> complete_FAPI_Font <font_name> <FontDict>
-{ 1 index /CIDFontType 2 put % Other types are not emulated yet.
- //super.complete_instance exec
- //RefinePath exec
- //load_sfnts exec
-} bind def
-
-/IsMyRecord % <raw_record> -> <raw_record> bool
-{ dup type /dicttype eq { dup /FileType .knownget { /TrueType eq } { false } ifelse } { false } ifelse
-} bind def
-
-/IsActive % <record> IsActive <bool>
-{ pop true
-} bind def
-
-/CIDFontRecordVirtualMethods //RecordVirtualMethodsStub dup length 3 add dict copy begin
- /GetCSI //TranslateCSI def
- /IsActive //IsActive def
- /MakeInstance % <Name> <record> MakeInstance <Name> <Instance> <size>
- { currentglobal 3 1 roll true setglobal
- //CIDFontOptions //complete_instance exec
- 2 copy //GetSize exec
- 4 3 roll setglobal
- } bind def
-currentdict end def
-
-% Redefine the /CIDFont category :
-4 dict begin
- /CategoryName /CIDFont def
- /IsMapFileOptional true def
- /VerifyMap { pop } bind def
- /PreprocessRecord % <map> <Name> <raw_record> PreprocessRecord <map> <Name> <record> <bool>
- { //IsMyRecord exec dup {
- pop dup /RecordVirtualMethods //CIDFontRecordVirtualMethods put
- true
- } if
- } bind def
-currentdict end
-
-/MappedCategoryRedefiner /ProcSet findresource /Redefine get exec
-
-end % the temporary dictionary for local binding.
-
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_ciecs2.ps b/Master/tlpkg/tlgs/lib/gs_ciecs2.ps deleted file mode 100644 index 17a213e4d13..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_ciecs2.ps +++ /dev/null @@ -1,147 +0,0 @@ -% Copyright (C) 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_ciecs2.ps 6300 2005-12-28 19:56:24Z giles $
-% Level 2 CIEBased color space method dictionaries.
-
-%
-% The validation routines in these method dictionaries perform only
-% partial validations; the .setcie* operators will perform the rest.
-%
-
-% verify that at least one of the CIEBased color spaces is supported
-true
- { /.setcieaspace /.setcieabcspace /.setciedefspace /.setciedefgspace }
- {
- where
- { pop not exit }
- if
- }
-forall
- { currentfile closefile }
-if
-
-
-.currentglobal true .setglobal
-.cspace_util begin
-
-%
-% <obj> check_cie_cspace <obj>
-%
-% Perform a very basic check that an object is a CIEBased color space
-% array.
-%
-/check_cie_cspace
- {
- //check_array exec
- dup 1 get type /dicttype ne
- //setcspace_typecheck
- if
- }
-bind def
-
-
-
-/.setcieaspace where
- {
- pop
- colorspacedict
- /CIEBasedA
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate true
- /cs_get_ncomps //ncomps_1
-
- /cs_get_range
- {
- 1 get /RangeA .knownget not
- { //dflt_range_1 }
- if
- }
- bind
-
- /cs_get_default_color { pop 0 } bind
- /cs_get_currentgray //no_currentgray
- /cs_get_currentrgb //no_currentrgb
- /cs_get_currentcmyk //no_currentcmyk
- /cs_validate //check_cie_cspace
- /cs_substitute //dup_1
- /cs_prepare {}
-
- /cs_install
- {
- NOCIE
- { pop /DeviceGray //.cs_install exec }
- { 1 get .setcieaspace }
- ifelse
- }
- bind
-
- /cs_prepare_color //validate_1
- /cs_complete_setcolor //pop_1
- .dicttomark
- put
- }
-if
-
-/.setcieabcspace where
- {
- pop
- colorspacedict
- /CIEBasedABC
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate true
- /cs_get_ncomps //ncomps_3
-
- /cs_get_range
- {
- 1 get /RangeABC .knownget not
- { //dflt_range_3 }
- if
- }
- bind
-
- /cs_get_default_color { pop 0 0 0 } bind
- /cs_get_currentgray //no_currentgray
- /cs_get_currentrgb //no_currentrgb
- /cs_get_currentcmyk //no_currentcmyk
- /cs_validate //check_cie_cspace
- /cs_substitute //dup_1
- /cs_prepare {}
-
- /cs_install
- {
- NOCIE
- { pop /DeviceRGB //.cs_install exec }
- { 1 get .setcieabcspace }
- ifelse
- }
- bind
-
- /cs_prepare_color //validate_3
- /cs_complete_setcolor //pop_1
- .dicttomark
- put
- }
-if
-
-
-end % .cspace_util
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_ciecs3.ps b/Master/tlpkg/tlgs/lib/gs_ciecs3.ps deleted file mode 100644 index 0d7fb03eff6..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_ciecs3.ps +++ /dev/null @@ -1,137 +0,0 @@ -% Copyright (C) 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_ciecs3.ps 7204 2006-11-15 23:59:58Z ray $
-% Level 3 CIEBased color space method dictionaries.
-% This assumes gs_ciecs2.ps has already been processed.
-
-%
-% The validation routines in these method dictionaries perform only
-% partial validations; the .setcie* operators will perform the rest.
-%
-
-
-.currentglobal true .setglobal
-.cspace_util begin
-
-
-/.setciedefspace where
- {
- pop
- colorspacedict
- /CIEBasedDEF
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate true
- /cs_get_ncomps //ncomps_3
-
- /cs_get_range
- {
- 1 get /RangeDEF .knownget not
- { //dflt_range_3 }
- if
- }
- bind
-
- % per Page 233 of the PLRM, default color should be as close to 0.0 as possible
- % within the RangeDEF
- /cs_get_default_color { 1 get /RangeDEF .knownget {
- aload pop pop 5 1 roll pop 4 1 roll pop 3 1 roll
- } {
- 0.0 0.0 0.0
- } ifelse
- } bind
- /cs_get_currentgray //no_currentgray
- /cs_get_currentrgb //no_currentrgb
- /cs_get_currentcmyk //no_currentcmyk
- /cs_validate //check_cie_cspace
- /cs_substitute //dup_1
- /cs_prepare {}
-
- /cs_install
- {
- NOCIE
- { pop /DeviceRGB //.cs_install exec }
- { 1 get .setciedefspace }
- ifelse
- }
- bind
-
- /cs_prepare_color //validate_3
- /cs_complete_setcolor //pop_1
- .dicttomark
- put
- }
-if
-
-
-/.setciedefgspace where
- {
- pop
- colorspacedict
- /CIEBasedDEFG
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate true
- /cs_get_ncomps //ncomps_4
-
- /cs_get_range
- {
- 1 get /RangeDEFG .knownget not
- { //dflt_range_4 }
- if
- }
- bind
-
- % per Page 233 of the PLRM, default color should be as close to 0.0 as possible
- % within the RangeDEFG
- /cs_get_default_color { 1 get /RangeDEFG .knownget {
- aload pop pop 7 1 roll pop 6 1 roll pop 5 1 roll pop 4 1 roll
- } {
- 0.0 0.0 0.0 0.0
- } ifelse
- } bind
- /cs_get_currentgray //no_currentgray
- /cs_get_currentrgb //no_currentrgb
- /cs_get_currentcmyk //no_currentcmyk
- /cs_validate //check_cie_cspace
- /cs_substitute //dup_1
- /cs_prepare {}
-
- % the use of the DeviceCMYK color space is questionable:
- % it will likely have the wrong polarity
- /cs_install
- {
- NOCIE
- { pop /DeviceCMYK //.cs_install exec }
- { 1 get .setciedefgspace }
- ifelse
- }
- bind
-
- /cs_prepare_color //validate_4
- /cs_complete_setcolor //pop_1
- .dicttomark
- put
- }
-if
-
-
-end % .cspace_util
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_cmap.ps b/Master/tlpkg/tlgs/lib/gs_cmap.ps deleted file mode 100644 index a4c5a55eecd..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cmap.ps +++ /dev/null @@ -1,549 +0,0 @@ -% Copyright (C) 1995, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_cmap.ps 7137 2006-10-30 21:57:56Z ray $
-% ProcSet for implementing CMap resources.
-% When this is run, systemdict is still writable.
-
-% NOTE: Rearranged fonts are not implemented yet.
-
-[
- /CMERGE_DEBUG
- /USE_CIDCHAR_AS_RANGE
-] {dup where {pop pop} { currentdict exch //false def pop } ifelse} forall
-
-% ---------------- Public operators ---------------- %
-
-/.rewriteTempMapsNotDef {
- %
- % Before building .CodeMapData from .TempMaps,
- % we need to replace dst type codes in the notdef map with the value 3,
- % which corresponds to CODE_VALUE_NOTDEF, see gxfcmap.h .
- %
- CMAPDEBUG { (rewriting TempMapsNotDef\n) print flush } if
- .TempMaps 2 get
- dup length 0 gt {
- 0 get
- CMAPDEBUG { (...original...\n) print flush } if
- 1 5 2 index length 1 sub {
- { 1 index exch get 2 3 put } stopped
- { CMAPDEBUG { (cannot rewrite\n) print flush } if }
- { CMAPDEBUG { (rewrite\n) print flush } if } ifelse
- } for
- } if
- pop
- CMAPDEBUG { (...FINISHED...\n) print } if
-} bind def
-
-/.composefontdict { % <name> <cmap|cmapname> <fonts> composefont <name> <font_dict>
- 10 dict begin
- /CMap 2 index dup type /dicttype ne { /CMap findresource } if def
- /FDepVector 1 index cvlit def % temporarily
- /Encoding [ 0 1 FDepVector length 1 sub { } for ] def
- /FontInfo 1 dict def % for .processToUnicode in pdf_font.ps .
- /FDepVector [ 0 1 FDepVector length 1 sub {
- % Stack: name cmap[name] fonts /FDepVector [ fonts... i
- FDepVector 1 index get
- dup type /dicttype ne {
- dup /CIDFont resourcestatus {
- pop pop /CIDFont
- } {
- /Font
- } ifelse findresource
- } if
- exch CMap /FontMatrices get dup length 2 index gt {
- exch get dup //null eq { pop } { makefont } ifelse
- } {
- pop pop
- } ifelse
- } for ] readonly def
- /FMapType 9 def
- /FontMatrix matrix def
- /FontName 3 index def
- CMap /WMode .knownget { /WMode exch def } if
- /FontType 0 def
- pop pop currentdict end
-} bind odef
-
-% composefont doesn't appear in CMap files -- it's documented in
-% the "PostScript Language Reference Manual Supplement".
-/composefont { % <name> <cmap|cmapname> <fonts> composefont <font>
- .composefontdict /Font defineresource
-} bind def
-
-% ---------------- CMap operators ---------------- %
-
-40 dict begin
-
-% Our internal .CodeMapData structure closely mirrors the structures
-% defined in gxfcmap.h (q.v.). () indicate a string, [] indicate an array,
-% ? indicates a Boolean, # indicates an integer, {} for grouping.
-% [[[(first) (last) ...]+] % code space ranges
-% [[(prefix) (key_size,?is_range,value_type,value_size) (keys...)
-% {(values...) | [value ...]} #font_index ]+] % code mappings
-% ...]
-% <<same>> % notdef mappings
-% ]
-% FontMatrices is the array of matrices defined by begin/endusematrix.
-% All of the arrays and strings are read-only after they have been built.
-%
-% Note that the code in zfcmap.c that constructs the C structures from
-% the PostScript structures has intimate knowledge of the above format.
-
-% ****** NOTE: The code currently only handles "well-behaved" CMaps:
-% - CID values only (no bfchars), 16-bit
-% - Entries (both code space and map) must be sorted
-% - Only the last byte must vary in each map range, except for
-% the identity mapping
-
-% ------ Font-level operators ------ %
-
-/begincmap { % - begincmap -
- /.CodeMapData [[[]] [[]] [[]]] def
- /FontMatrices [] def
- /.FontIndex 0 def
- /.TempMaps [20 dict 50 dict 50 dict] def
- /CodeMap //null def % for .buildcmap
-} bind def
-
-/endcmap { % - endcmap -
- .rewriteTempMapsNotDef
-
- CMAPDEBUG {
- 2 (*** undefined charmap ***)
- 1 (*** defined charmap ***)
- 0 (*** code space ranges ***)
- 3 { =
- .TempMaps exch get
- 0 1 2 index length 1 sub {
- dup == (\t) print
- 1 index exch get ==
- } for
- pop
- } repeat
- } if
-
- /.CodeMapData dup load [ exch
- .TempMaps aload pop begin begin begin
- {
- [ exch aload pop
- 0 1 currentdict length 1 sub {
- currentdict exch get
- } for
- ]
- end
- } forall
- ] .endmap def
-
- CMAPDEBUG {
- (*** Content of .CodeMapData ***) =
- 0 .CodeMapData { exch dup == 1 add exch (\t) print == } forall
- pop
- } if
-
- currentdict /.TempMaps undef
- /FontMatrices FontMatrices .endmap def
-} bind def
-
-/.endmap { % <map> .endmap <map>
- dup type /arraytype eq {
- % This might be a shared read-only array inherited via usecmap.
- % Don't try to update its elements if this is the case.
- dup wcheck {
- 0 1 2 index length 1 sub {
- 2 copy 2 copy get .endmap put pop
- } for readonly
- } if
- } {
- dup type /stringtype eq { readonly } if
- } ifelse
-} bind def
-
-/.appendmap { % -mark- <elt> ... <array#> .appendmap -
- .TempMaps exch get counttomark 1 add 1 roll
- ] 1 index length exch put
-} bind def
-
-/begincodespacerange { % <count> begincodespacerange -
- pop mark
-} bind def
-
-/endcodespacerange { % <code_lo> <code_hi> ... endcodespacerange -
- 0 .appendmap
-} bind def
-
-/usecmap { % <CMap_name> usecmap -
- /CMap findresource dup
- % Copy the top level of .CodeMapData
- /.CodeMapData exch /.CodeMapData get copyarray def
- /FontMatrices exch /FontMatrices get copyarray def
-} bind def
-
-/usefont { % <fontID> usefont -
- /.FontIndex exch def
-} bind def
-
-/beginusematrix { % <fontID> beginusematrix -
- FontMatrices wcheck not FontMatrices length 2 index le or {
- FontMatrices length 1 index 1 add .max array
- dup 0 FontMatrices putinterval
- /FontMatrices exch def
- } if
-} bind def
-
-/endusematrix { % <matrix> endusematrix -
- FontMatrices 3 1 roll put
-} bind def
-
-% ------ Rearranged font operators ------ %
-
-/beginrearrangedfont { % <font_name> <font*> beginrearrangedfont -
- 10 dict begin
- /.FontNames exch def
- /.FontName exch def
- begincmap
-} bind def
-/endrearrangedfont { % - endrearrangedfont -
- (REARRANGED FONTS NOT IMPLEMENTED YET.) = flush
- FontName .FontNames 0 get findfont end definefont pop
-} bind def
-
-% ------ Character name/code selector operators ------ %
-
-/beginbfchar { % <count> beginbfchar -
- pop mark
-} bind def
-/endbfchar { % <code> <to_code|charname> ... endbfchar
- counttomark 2 idiv {
- counttomark -2 roll % process in correct order
- .addbfchar
- } repeat 1 .appendmap
-} bind def
-
-/beginbfrange { % <count> beginbfrange -
- pop mark
-} bind def
-/endbfrange { % <code_lo> <code_hi> <to_code|(charname*)> ...
- % endbfrange -
- counttomark 3 idiv {
- counttomark -3 roll % process in correct order
- dup type dup /arraytype eq exch /packedarraytype eq or {
- % Array value, split up.
- exch pop {
- % Stack: code to_code|charname
- 1 index exch .addbfchar
- % Increment the code. As noted above, we require
- % that only the last byte vary, but we still must
- % mask it after incrementing, in case the last
- % value was 0xff.
- % Stack: code prefix params key value fontindex
- 6 -1 roll dup length string copy
- dup dup length 1 sub 2 copy get 1 add 255 and put
- } forall pop
- } {
- % Single value, handle directly.
- .addbfrange
- } ifelse
- } repeat 1 .appendmap
-} bind def
-
-/.addbfchar { % <code> <to_code|charname> .addbfchar
- % <prefix> <params> <key> <value> <font_index>
- 1 index exch .addbfrange
-} bind def
-/.addbfrange { % <code_lo> <code_hi> <to_code|charname>
- % .addbfrange <<same as .addbfchar>>
- 4 string dup 3
- 3 index type /nametype eq {
- 2 index 2 1 put % dst = CODE_VALUE_GLYPH, see gxfcmap.h .
- 4 -1 roll 1 array astore 4 1 roll 4
- } {
- 2 index 2 2 put % dst = CODE_VALUE_CHARS, see gxfcmap.h .
- 3 index length
- } ifelse put
- % Stack: code_lo code_hi value params
- 3 index 3 index eq {
- % Single value.
- 3 -1 roll pop exch () exch
- } {
- % Range.
- dup 0 1 put dup 1 1 put
- 4 2 roll
- dup dup length 1 sub 0 exch getinterval 5 1 roll % prefix
- % Stack: prefix value params code_lo code_hi
- 2 { exch dup length 1 sub 1 getinterval } repeat concatstrings
- 3 -1 roll
- } ifelse
- .FontIndex
-} bind def
-
-% ------ CID selector operators ------ %
-
-/begincidchar { % <count> begincidchar -
- pop mark
-} bind def
-/endcidchar { % <code> <cid> ... endcidchar -
- 1 .endmapchars
-} bind def
-
-/begincidrange { % <count> begincidrange -
- pop mark
-} bind def
-/endcidrange { % <code_lo> <code_hi> <cid_base> ... endcidrange -
- 1 .endmapranges
-} bind def
-
-/.endmapchars { % -mark- <code> <cid> ... <map#> .endmapchars -
- counttomark 1 add 1 roll
- counttomark 2 idiv {
- counttomark -2 roll % process in correct order
- exch % <cid> <code>
- % Construct prefix, params, key, value, font_index
- dup length 1 eq { % 1-byte
- <00 00 00 02> () % <prefix> <param> <null_key>
- } { % N-byte
- dup 0 1 getinterval exch % make 1-byte prefix
- 4 string dup 0
- USE_CIDCHAR_AS_RANGE {
- <00 01 00 02> % skelton for param
- } {
- <00 00 00 02> % skelton for param
- } ifelse
- putinterval
- exch % <prefix> <param> <code>
- dup length % <prefix> <param> <code> N
- 1 sub % <prefix> <param> <code> N-1
- dup % <prefix> <param> <code> N-1 N-1
- 3 index % <prefix> <param> <code> N-1 N-1 <param>
- exch % <prefix> <param> <code> N-1 <param> N-1
- 0 exch % <prefix> <param> <code> N-1 <param> 0 N-1
- put % <prefix> <param'> <code> N-1
- 1 exch % <prefix> <param'> <code> 1 N-1
- getinterval % <prefix> <param'> <key>
-
- USE_CIDCHAR_AS_RANGE {
- dup length 2 mul string % <key> <dkey>
- dup % <key> <dkey> <dkey>
- 2 index % <key> <dkey> <dkey> <key>
- 0 exch putinterval % <key> <dkey'>
- dup % <key> <dkey'> <dkey'>
- 3 -1 roll % <dkey'> <dkey'> <key>
- dup length % <dkey'> <dkey'> <key> N-1
- exch putinterval % <dkey''>
- } if
-
- } ifelse
-
- 4 -1 roll % <prefix> <param'> <key> <cid>
- .endmapvalue % <prefix> <param'> <key> <hex_cid> <font_idx>
- % prefix params keys value fontindex
- counttomark 5 gt { % 2 (or more) ranges (1 range = 5 item)
- 4 index 10 index eq % compare prefix
- 4 index 10 index eq and % compare params
- 1 index 7 index eq and % compare fontindex
- {
- CMAPDEBUG { (merge! char\n) print } if
- pop 4 2 roll pop pop
- % prefix params keys value fontindex keys2 value2
- 5 -1 roll 3 -1 roll concatstrings
- % prefix params value fontindex value2 keys'
- 4 -1 roll 3 -1 roll concatstrings
- % prefix params fontindex keys' values'
- 3 -1 roll
- } if
- } if % end of 2 (or more) ranges
- CMERGE_DEBUG {
- ( prefix:) print 4 index =only
- ( param:) print 3 index =only
- ( key:) print 2 index =only
- ( hex_cid:) print 1 index =only
- ( font_idx:) print 0 index == flush
- } if
- } repeat
- counttomark 2 add -1 roll .appendmap
-} bind def
-
-/.endmapranges { % -mark- <code_lo> <code_hi> <cid_base> ... <map#>
- % .endmapranges -
- counttomark 1 add 1 roll
- counttomark 3 idiv {
- counttomark -3 roll % process in correct order
- % Construct prefix, params, key_lo, key_hi, value, font_index
- 3 1 roll % <cid_base> <code_lo> <code_hi>
- % prefix key
- % 1-byte code: () .
- % 1-byte range: () .
- % N-byte code: . (*)
- % N-byte range: (*) (*)
- dup 2 index eq { % <code_lo> == <code_hi>
- % 0: prefix_len for 1-byte code
- % 1: prefix_len for N-byte code
- dup length 1 eq { 0 } { 1 } ifelse
- } { % <code_lo> != <code_hi>
- % calculate prefix_len for *-byte range
- dup length 1 sub % <cid_base> <code_lo> <code_hi> <code_len-1>
- 0 % initial value for N
- { % <cid_base> <code_lo> <code_hi> (code_len-1) N
- dup 2 index ge { exit } if % if (N >= len - 1) exit
- 3 index 1 index get % N-th byte of code_lo
- 3 index 2 index get % N-th byte of code_hi
- eq { 1 add } { exit } ifelse
- } loop
- exch pop % discard <code_len-1>
- } ifelse
- % cid_base code_lo code_hi prefix_len
-
- % Althogh Adobe CPSI with native CID/CMap support accept
- % multi-dimensional range specification in notdef & cidrange
- % (and CID is calculated as relative position in multi-dimensional
- % range), but older CPSI & ATM cannot handle it.
- %
- % GS accepts such specification, but it's recommended to keep
- % from using this feature for notdef & cidrange.
- % Following is a disabler of this feature.
- % -------------------------------------------------------------
- % counttomark 1 add index % get map#
- % 0 ne { % if not codespacerange
- % 1 index length % get code length
- % 1 index % get prefix length
- % sub % calculate key length
- % 1 gt { % if (key_len > 1),
- % (.endmapranges error) = flush
- % (multi-dimensional range specification is used out of codespacerange)
- % = flush
- % (/) =only
- % CMapName CMapName length string cvs =only
- % (: <) =only
- % 2 index (%stdout) (w) file exch writehexstring
- % (> <) =only
- % 1 index (%stdout) (w) file exch writehexstring
- % (>\n) =only flush
- % quit
- % } if
- % } if
- % -------------------------------------------------------------
-
- 1 index exch 0 exch getinterval
- % cid_base code_lo code_hi prefix
- dup length 3 index length exch sub
- % cid_base code_lo code_hi prefix range_len
- dup 255 gt {
- (too long coderange specification for current GS\n) print
- /.endmapranges cvx /rangecheck signalerror
- } if
- <00 01 00 02> 4 string copy % create initialized param
- dup 0 4 -1 roll put % put range_len into param
-
- % get key_hi
- 3 -1 roll dup length 3 index length dup 3 1 roll sub getinterval
-
- % get key_lo
- 4 -1 roll dup length 4 index length dup 3 1 roll sub getinterval
-
- % make "keys" (concatenated key_lo + key_hi)
- exch concatstrings
-
- %
- 4 -1 roll
- .endmapvalue
-
- % See if we can merge with the previous value.
- % The prefix, params, and font index must match.
- % prefix params keys value fontindex
- counttomark 5 gt { % 2 (or more) ranges (1 range = 5 item)
- 4 index 10 index eq % compare prefix
- 4 index 10 index eq and % compare params
- 1 index 7 index eq and % compare fontindex
- {
- CMAPDEBUG { (merge!\n) print } if
- pop 4 2 roll pop pop
- % prefix params keys value fontindex keys2 value2
- 5 -1 roll 3 -1 roll concatstrings
- % prefix params value fontindex value2 keys'
- 4 -1 roll 3 -1 roll concatstrings
- % prefix params fontindex keys' values'
- 3 -1 roll
- } if
- } if % end of 2 (or more) ranges
- } repeat
- counttomark 2 add -1 roll .appendmap
-} bind def
-
-/.endmapvalue { % <cid> .endmapvalue (hi,lo) .FontIndex
- 2 string dup 0 3 index -8 bitshift put % value
- dup 1 4 -1 roll 255 and put
- .FontIndex % font_index
-} bind def
-
-% ------ notdef operators ------ %
-
-/beginnotdefchar { % <count> beginnotdefchar -
- pop mark
-} bind def
-/endnotdefchar { % <code> <cid> ... endnotdefchar -
- 2 .endmapchars
-} bind def
-
-/beginnotdefrange { % <count> beginnotdefrange -
- pop mark
-} bind def
-/endnotdefrange { % <code_lo> <code_hi> <cid> ... endnotdefrange -
- 2 .endmapranges
-} bind def
-
-% ---------------- Resource category definition ---------------- %
-
-currentdict end
-
-languagelevel exch 2 .setlanguagelevel
-
-/CMap /Generic /Category findresource dup length dict .copydict
-dup /InstanceType /dicttype put
-dup /DefineResource {
- % The AdobePS5 Windows driver emits code that attempts to
- % create CMaps without the required CMapName entry.
- % Work around this here.
- dup /CMapName known not {
- dup wcheck not {
- .currentglobal exch dup wcheck .setglobal
- dup length dict .copydict exch .setglobal
- } if
- dup gcheck 2 index gcheck not and {
- exch .currentglobal exch //true .setglobal
- dup length string copy exch .setglobal exch
- } if dup /CMapName 3 index put
- } if
- % Adobe PS CET 23-25 and others define an almost empty CMap. Tolerate this.
- % With the above, we can actually tolerate: /name << >> defineresource
- dup /CIDSystemInfo known not {
- dup wcheck not {
- .currentglobal exch dup wcheck .setglobal
- dup length dict .copydict exch .setglobal
- } if
- dup /CIDSystemInfo [ //null ] put
- } if
- dup /CodeMap .knownget { //null eq { .buildcmap } if } if
- /Generic /Category findresource /DefineResource get exec
-} bind put
-/Category defineresource pop
- % We might have loaded CID font support already.
-/CIDInit /ProcSet 2 copy { findresource } .internalstopped
- % An interior `stopped' might have reset VM allocation to local.
-//true .setglobal
- { pop pop 3 -1 roll }
- { dup length 4 index length add dict .copydict 4 -1 roll exch .copydict }
-ifelse exch defineresource pop
-
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_cmdl.ps b/Master/tlpkg/tlgs/lib/gs_cmdl.ps deleted file mode 100644 index 2299c5c5f08..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cmdl.ps +++ /dev/null @@ -1,180 +0,0 @@ -% Copyright (C) 1994, 1996, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_cmdl.ps 6300 2005-12-28 19:56:24Z giles $
-% Parse and execute the command line.
-% C code handles the following switches: -h/-? -I -M -v
-
-/cmddict 50 dict def
-cmddict begin
-
-% ---------------- Utility procedures ---------------- %
-
-% Get the next argument from the parsed argument list.
-/nextarg % - nextarg <arg> true
- % - nextarg false
- { argv length 0 eq
- { false }
- { argv dup 0 get exch dup length 1 sub 1 exch getinterval /argv exch def }
- ifelse
- } bind def
-
-% Run a file, under job control if implemented.
-/runjob % <file> runjob -
- { end % cmddict
- /startjob where { pop false () startjob pop }
- run
- //cmddict begin
- } bind def
-/runfilejob % <filename> runfilejob -
- { findlibfile { exch pop } { (r) file } runjob
- } bind def
-
-% Expand arguments. Free variables: expand@.
-/expandarg % <string> expandarg <args...>
- { dup () eq
- { pop
- }
- { dup dup (--) eq exch (-+) eq or
- { pop /expand@ false def
- }
- { expand@ { (@) anchorsearch } { false } ifelse
- { pop findlibfile
- { exch pop }
- { (r) file } % let the error happen
- expandargfile
- }
- if
- }
- ifelse
- }
- } bind def
-/expandargfile % <file> expandargfile <args...>
- { [ exch cvlit
- { token not { exit } if
- dup type /stringtype ne { =string cvs dup length string copy } if
- expandarg
- }
- /exec cvx
- ] cvx loop
- } bind def
-
-% ---------------- Recognized switches ---------------- %
-
-% Switches with arguments are defined as <x>;
-% switches without arguments are defined as -<x>.
-
-% Switches without arguments
-/--
- { nextarg not
- { (-- and -+ require a file name.) = flush }
- { //systemdict /ARGUMENTS argv put /argv [] def runjob }
- ifelse
- } bind def
-/-+ /-- load def
-/-@ /-- load def
-/-A { (@) Z } bind def
-/-c
- { { argv length 0 eq { exit } if
- argv 0 get (-) anchorsearch { pop pop exit } if
- pop nextarg token
- { exch pop % Probably should check for empty.
- end exec //cmddict begin
- }
- if
- }
- loop
- } bind def
-/-e { (#) Z } bind def
-/-E /-e load def
-/-f { } def
-/-q { //systemdict /QUIET true put } bind def
-
-% Switches with arguments
-/d
- { (=) search not { (#) search not { () exch dup } if } if
- exch pop cvn dup where
- { pop (Redefining ) print print ( is not allowed.) = flush pop }
- { exch token
- { exch pop } % Probably should check for empty.
- { true }
- ifelse
- //systemdict 3 1 roll put
- }
- ifelse
- } bind def
-/D /d load def
-/f { dup length 0 ne { runfilejob } if } bind def
-/g
- { (x) search { cvi pop exch cvi } { cvi dup } ifelse
- //systemdict begin /DEVICEHEIGHT exch def /DEVICEWIDTH exch def end
- } bind def
-/r
- { (x) search { cvr pop exch cvr } { cvr dup } ifelse
- //systemdict begin /DEVICEYRESOLUTION exch def /DEVICEXRESOLUTION exch def end
- } bind def
-/s
- { (=) search not { (#) search not { () exch dup } if } if
- exch pop cvn dup where { pop dup load } { () } ifelse
- type /stringtype ne
- { (Redefining ) print print ( is not allowed.) = flush pop }
- { exch //systemdict 3 1 roll put }
- ifelse
- } bind def
-/S /s load def
-/Z { true .setdebug } bind def
-
-% ---------------- Main program ---------------- %
-
-% We process the command line in two passes. In the first pass,
-% we read and expand any @-files as necessary. The second pass
-% does the real work.
-
-/cmdstart
- { //cmddict begin
- /expand@ true def
- [
- % Process the GS_OPTIONS environment variable.
- (GS_OPTIONS) getenv { 0 () /SubFileDecode filter expandargfile } if
- % Process the actual command line.
- .getargv { expandarg } forall
- ] readonly /argv exch def
- % Now interpret the commands.
- { nextarg not { exit } if
- dup 0 get (-) 0 get eq
- { dup length 1 eq
- { pop (%stdin) (r) file runjob
- }
- { dup length 2 gt
- { dup dup length 2 sub 2 exch getinterval exch 1 1 getinterval }
- if currentdict .knownget
- { exec
- }
- { (Ignoring unknown switch ) print
- dup length 1 eq { (-) print print } if print
- () = flush
- }
- ifelse
- }
- ifelse
- }
- { runfilejob
- }
- ifelse
- }
- loop end
- } bind def
-
-end % cmddict
diff --git a/Master/tlpkg/tlgs/lib/gs_cspace.ps b/Master/tlpkg/tlgs/lib/gs_cspace.ps deleted file mode 100644 index c7149c7ba44..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_cspace.ps +++ /dev/null @@ -1,1022 +0,0 @@ -% Copyright (C) 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_cspace.ps 8048 2007-06-13 16:27:33Z tim $
-% basic colorspace mechanism
-
-%
-% This new implementation of color spaces extends the color space
-% formalism to all PostScript levels. Level specific features and
-% operators continue to be accessible only in the appropriate level,
-% but the colorspace concept and associated mechanisms are used
-% throughout.
-%
-% The color space mechanism is built around two dictionaries:
-%
-% .cspace_util
-% A dictionary in global VM that is accessible in userdict only
-% during initialization. This dictionary is intended for various
-% utility procedures that are used in implementing the individual
-% color spaces.
-%
-% colorspacedict
-% A dictionary of methods for each color space type. The keys
-% in this dictionary are color space type names (e.g.: /DeviceGray,
-% /Separation, etc.), and the values are dictionaries of methods.
-% The set of methods is the same for each color space type, and
-% provides a complete implementation for the corresponding color
-% space type. This dictionary is in global VM.
-%
-% The information specific to a color space type is created in a file
-% for that type or group of types (e.g.: gs_csdev.ps, gs_csindx.ps,
-% etc.). These files will generally adhere to the template:
-%
-% .currentglobal true .setglobal
-% <level-specific dictionary> begin
-% ...
-% .cspace_util begin
-% colorspacedict
-% /<color space type name>
-% mark
-% /cs_validate
-% {
-% ...
-% }
-% bind
-% ...
-% .dicttomark
-% put
-% end % .cspace_util
-% end ... % level-specific dictionary
-% .setglobal
-%
-% The methods associated with a color space are listed below (along with
-% their stack handling), followed by descriptions.
-%
-% - cs_potential_indexed_base <bool>
-%
-% - cs_potential_pattern_base <bool>
-%
-% - cs_potential_alternate <bool>
-%
-% - cs_potential_icc_alternate <bool>
-%
-%
-% <name | array> cs_get_ncomps <int>
-%
-% <name | array> cs_get_range <range_array>
-%
-% <name | array> cs_get_default_color <c1> ... <cn>
-%
-%
-% <c1> ... <cn> <name | array> cs_get_currentgray <gray>
-%
-% <c1> ... <cn> <name | array> cs_get_currentrgb <red> <green> <blue>
-%
-% <c1> ... <cn> <name | array> cs_get_currentcmyk
-% <cyan> <magenta> <yellow> <black>
-%
-%
-% <name | array> cs_validate <name | array>
-%
-% <name1 | array1> cs_substitute <name1 | array1> <array2>
-%
-% <name1 | array1> <array2> cs_prepare <name1 | array1> <array2>
-%
-% <name | array> cs_install -
-%
-%
-% <c1> ... <cn> <array> cs_verify_color <c1> ... <cn>
-%
-% <array> cs_complete_color -
-%
-%
-% cs_potential_indexed_base, cs_potential_pattern_base,
-% cs_potential_alternate, cs_potential_icc_alternate
-% These are booleans rather than procedures. They indicate if the color
-% space can be a base space of an Indexed color space (anything except
-% Indexed and Pattern), a Pattern color space (anything except Pattern),
-% the alternative color space of a Separation or DeviceN color space, or
-% the alternative color space of an ICCBased color space. The two
-% parameters are distinct only because of a Ghostscript-specific
-% implementation problem; in principle, there is nothing special about
-% ICCBased color spaces in this regard.
-%
-% cs_get_ncomps
-% Return the number of color components for the color spaces. For Pattern
-% color spaces, the value is -1 if there is no base space, or -(n + 1) if
-% the base space has n components.
-%
-% cs_get_range
-% Return the input Range array appropriate for this color space. This is
-% defined for all color spaces, though it is of interest primarily for
-% CIEBased and ICCBased color spaces. For Indexed color spaces this is
-% [ 0 hival ], where hival is the maximum support index value. For all
-% other non-CIEBased, non-ICCBased color spaces, the range is an array
-% of ncomps elements, all of which are [ 0 1 ], where ncomps is the
-% number of color space components.
-%
-% cs_get_default_color
-% Generates the default color for the current color space. Under normal
-% circumstances this is done internally. It is provided in PostScript
-% only to support an optimization that doesn't change the current color
-% space more often than necessary.
-%
-% cs_get_currentgray, cs_get_currentrgb, cs_get_currentcmyk
-% These procedures are used to implement the currentgray, currentrgb,
-% and currentcmyk operators (which are pseudo-operators in the current
-% implementation).
-%
-% cs_validate
-% Validate the operand color space. Because color spaces are extensively
-% manipulated in PostScript in this implementation, error handling can
-% become burdensome. To make the code somewhat simpler, it is useful to
-% be able to validate a color space prior to manipulation, so as to
-% ensure that errors are not discovered in awkward places.
-%
-% cs_substitute
-% Substitute a device-independent color space for device specific color
-% space. This applies directly to the device-specific color spaces
-% (DeviceGray, DeviceRGB, DeviceCMYK), and indirectly when these color
-% spaces are used as base/alternative color spaces. The mechanism for
-% color substitution is included in all language levels, though it may
-% only be accessed for Language Level 3.
-%
-% The substituted color space is the topmost of the operands pushed.
-% this may or may not be the same as the original color space, which
-% is immediately below it on the operand stack. If the two differ,
-% the substituted space will always be in local VM (and will be
-% writable).
-%
-% Substitution is applied recursively to the base/alternate color
-% space of ICCBased, Indexed, Separation, DeviceN, or Pattern
-% color spaces. Because Ghostscript currently requires that any
-% base or alternative color space be the current color space when
-% the enclosing color space is set, this substitution effectively
-% occurs twice: once in the original color space, and once when the
-% base/alternative color space is made the current color space.
-% We retain the first substitution as we would eventually like to
-% remove the restriction on making the base/alternative color space
-% the current color space.
-%
-% cs_prepare
-% Perform any operations required on the color space for installation.
-% This method exists primarily to allow conversion of PostScript
-% procedures to functions for CIEBased color spaces. Two operands are
-% provided: the original and the substituted color space. If the two
-% differ and the latter is writable, required modifications can
-% be made "in place". Otherwise, a new instance of the second color
-% space must be built.
-%
-% Currently, cs_prepare is not explicitly recursive. Because
-% Ghostscript requires a base/alternate color space to be installed
-% as the current color space prior to installing the enclosing color
-% space, the cs_prepare method will implicitly be called recursively.
-% The reason for not making this explicit is that color space
-% preparation may involve a considerable amount of work, which could
-% be avoided if, for example, an alternative color space will not
-% be used because the enclosing Separation/DeviceN color space is
-% supported in native mode by the process color model. We would
-% eventually like to remove the need to prepare color spaces that
-% will not be used.
-%
-% cs_install
-% This method actually installs the color space in the graphic state.
-% Only the substituted/prepared space (which may be the same as the
-% original space) is passed as an operand; the original space is handled
-% directly by the .setcolorspace operator.
-%
-% The provision of a separate method for this tasks reflects the
-% historical implementation of color spaces in the Ghostscript
-% interpreter. This implementation provides a unique operator for each
-% color space type.
-%
-% cs_prepare_color
-% Modify a set of color operands as required by a color space. This
-% is used primarily to verify the color operands, as this is most
-% conveniently done in PostScript.
-%
-% cs_complete_setcolor
-% This method is invoked immediately after a (successful) invocation
-% of setcolor. Ii is provided as a separate method for compatibility
-% with Adobe implementations. These implementations invoke the lookup
-% (Indexed) or tint procedure each time setcolor is invoked (only if
-% the alternative color space is used in the case of the tint
-% transform). Because Ghostscript may convert these procedures to
-% functions (or pre-sample them), the procedures may not always be
-% called when expected. There are applications that depend on this
-% behavior (e.g.: Adobe PhotoShop 5+), so this method provides a way
-% to emulate it.
-%
-% In principle, a cs_complete_setcolor procedure for an Indexed color
-% space whose base space should invoke cs_complete_setcolor on its
-% base space. Currently we don't do this, because it has not been
-% shown to be necessary. It would be simple to add if it is every
-% needed.
-%
-% All of these methods are procedures.
-%
-% For each of these methods, there is a procedure in .cspace_util with
-% a dot ('.') prefix that will invoke the appropriate procedure for the
-% operand array.
-%
-
-.currentglobal true .setglobal
-userdict /.cspace_util 80 dict put
-.cspace_util begin
-
-
-% Global, read-only, unpacked, array-form device color spaces
-%
-/DeviceGray_array /DeviceGray 1 array astore readonly def
-/DeviceRGB_array /DeviceRGB 1 array astore readonly def
-/DeviceCMYK_array /DeviceCMYK 1 array astore readonly def
-
-%
-% Colorspacedict is initially in .cspace_util; it is copied to level2dict
-% in the Level 2 initialization code to retain compatibility with
-% earlier implementations.
-%
-/colorspacedict 20 dict def
-
-
-%
-% <obj> make_array1 <array>
-%
-% procedure for conditionally converting a named color space to a
-% 1-element array. Since names are always global, the array will be
-% as well.
-%
-/make_array1
- {
- dup type /nametype eq
- { currentglobal true setglobal exch 1 array astore exch setglobal }
- if
- }
-bind def
-
-%
-% <name|array> .get_cspace_type name
-%
-% Provide generic routine for retrieving the color space type.
-%
-/.get_cspace_type
- {
- dup type dup /arraytype eq exch /packedarraytype eq or
- { 0 get }
- if
- }
-bind def
-
-%
-% <name|array> .get_method_dict <dict>
-%
-% Get the method dictionary for a specific color space. Note that the
-% color space is left on the stack.
-%
-/.get_method_dict
- { //colorspacedict exch //.get_cspace_type exec get }
-bind def
-
-%
-% <name|array> <proc_name> .get_method <name|array> <proc | bool>
-%
-% Get the named method for the operand color space.
-%
-/.get_method
- { exch //.get_method_dict exec exch get }
-bind def
-
-
-%
-% <name_array> .cs_potential_indexed_base <bool>
-% <name_array> .cs_potential_pattern_base <bool>
-% <name_array> .cs_potential_alternate <bool>
-% <name_array> .cs_potential_icc_alternate <bool>
-% <name | array> .cs_get_ncomps <int>
-% <name | array> .cs_get_range <range_array>
-% <name | array> .cs_get_default_color <c1> ... <cn>
-% <c1> ... <cn> <name | array> .cs_get_currentgray <gray>
-% <c1> ... <cn> <name | array> .cs_get_currentrgb <r> <g> <b>
-% <c1> ... <cn> <name | array> .cs_get_currentcmyk <c> <m> <y> <k>
-% <name | array> .cs_validate <name | array>
-% <name1 | array1> .cs_substitute <name1 | array1> <array2>
-% <name1 | array1> <array2> .cs_prepare <name1 | array1> <array2>
-% <name | array> .cs_install -
-% <c1> ... <cn> <array> .cs_prepare_color <c1> ... <cn>
-% <array> .cs_complete_setcolor -
-%
-% These procedures provide access to the corresponding methods of the
-% operand color space.
-%
-/.cs_potential_indexed_base
- { /cs_potential_indexed_base //.get_method exec }
-bind def
-
-/.cs_potential_pattern_base
- { /cs_potential_pattern_base //.get_method exec }
-bind def
-
-/.cs_potential_alternate
- { /cs_potential_alternate //.get_method exec }
-bind def
-
-/.cs_potential_icc_alternate
- { /cs_potential_icc_alternate //.get_method exec }
-bind def
-
-/.cs_get_ncomps
- { dup /cs_get_ncomps //.get_method exec exec }
-bind def
-
-/.cs_get_range
- { dup /cs_get_range //.get_method exec exec }
-bind def
-
-/.cs_get_default_color
- { dup /cs_get_default_color //.get_method exec exec }
-bind def
-
-/.cs_get_currentgray
- { dup /cs_get_currentgray //.get_method exec exec }
-bind def
-
-/.cs_get_currentrgb
- { dup /cs_get_currentrgb //.get_method exec exec }
-bind def
-
-/.cs_get_currentcmyk
- { dup /cs_get_currentcmyk //.get_method exec exec }
-bind def
-
-/.cs_validate
- { dup /cs_validate //.get_method exec exec }
-bind def
-
-/.cs_substitute
- { dup /cs_substitute //.get_method exec exec }
-bind def
-
-/.cs_prepare
- { dup /cs_prepare //.get_method exec exec }
-bind def
-
-/.cs_install
- { dup /cs_install //.get_method exec exec }
-bind def
-
-/.cs_prepare_color
- { dup /cs_prepare_color //.get_method exec exec }
-bind def
-
-/.cs_complete_setcolor
- { dup /cs_complete_setcolor //.get_method exec exec }
-bind def
-
-
-%
-% Make sure we have an interpreter color space before redefining
-% setcolorspace. The interpreter internal code only sets the effective
-% color space; the interpreters color spaces begins as a null object.
-%
-% NB: This should come prior to the redefinition of setcolorspace, and
-% must use an array operand.
-%
-//DeviceGray_array setcolorspace
-
-%
-% <c1> ... <cn> setcolor -
-%
-% As with setcolorspace, setcolor is initially placed in .cspace_util,
-% and is copied to level2dict by the Level 2 initialization code. The
-% internal definition of setcolor is removed from systemdict as soon
-% as this procedure is defined.
-%
-/setcolor
- {
- {
- currentcolorspace //.cs_prepare_color exec //setcolor
- currentcolorspace //.cs_complete_setcolor exec
- }
- stopped
- { //.cspace_util /setcolor get $error /errorname get signalerror }
- if
- }
-bind odef
-
-systemdict /setcolor .undef
-
-
-%
-% <name|array> <bool> _setcolorspace -
-% <name|array> _setcolorspace_nosub -
-%
-% <name|array> setcolorspace -
-% <name|array> forcesetcolorspace -
-%
-% setcolorspace is initially placed in .cspace_util. It is copied to
-% level2dict by the Level 2 initialization code. The internal
-% setcolorspace operator is removed from systemdict as soon as this
-% procedure is defined.
-%
-% Because some jobs, in particular PDF jobs, repeatedly set the same
-% color space, this procedure will check if the operand and current
-% color spaces are the same. The check is absolute for parameterless
-% color spaces, conservative for others. For PostScript, this
-% optimization can only be employed if color space substitution is
-% disabled, as otherwise there is no way to account for possible changes
-% in the /Default* instances of the ColorSpace resource category. For PDF
-% jobs, resource category instances can only be changed at very specific
-% times (typically page boundaries), so the "operand color space is the
-% same as current color space" optimization may be used even if color
-% space substitution is in effect. The optimization is also highly
-% desirable in such cases, as it greatly improves performance.
-%
-% In certain situations, it is critical that a color space be set,
-% even if it is the same as the current color space. This is the case
-% when a CIEBased color space is used as a base or alternative color
-% space, due to some long-standing problems with the graphics libraries
-% handling of sampled information from the procedures in CIE color
-% spaces and the color rendering dictionary. The forcesetcolorspace
-% operator is provided for those situations.
-%
-% Note also that, if the current color space is not reset, at least
-% the current color must be reset to its default value.
-%
-% Another problem arises in the case of ICCBased color spaces. These
-% color spaces may be used to substitute for a DeviceGray/DeviceRGB/
-% DeviceCMYK color space, and may themselves require such a color
-% space as an alternate. Obviously, when this is the case the normal
-% setcolorspace mechanism would encounter and infinite loop if the
-% alternate colro space needed to be used. For this particular case,
-% the special _setcolorspace_nosub is provided, which suppresses
-% color space substitution. This routine does not bother to check if
-% the operand and current color space are the same.
-%
-/_setcolorspace
- {
- { % Early validation the argument. The code below fails in unpredictable ways
- % when it is exposed to the garbage.
- 1 index
- dup type dup /arraytype eq exch /packedarraytype eq or { 0 get } if
- dup type /nametype ne {
- //.cspace_util /setcolorspace get /typecheck signalerror
- } if
- //colorspacedict exch known not {
- //.cspace_util /setcolorspace get /undefined signalerror
- } if
-
- % See if the operand space is the same as the current space.
- % The test is intentionaly conservative to meet CET 09-06.
- 1 index % [/new] bool [/new]
- type /nametype eq
- { currentcolorspace 0 get % [/new] bool /old
- 2 index eq % [/new] bool bool
- }
- { currentcolorspace % [/new] bool [/old]
- 2 index eq % [/new] bool eq
- }
- ifelse
- and dup
- {
- %
- % If PDFfile is defined on the dictionary stack, this is a
- % PDF job. No additional check is required in this case (see
- % comment above).
- %
- /PDFfile where
- { pop }
- { .getuseciecolor not and } % check that UseCIEColor is off
- ifelse
- }
- if
- {
- % Some versions of PhotoShop generate documents
- % that place an extra value on the operand stack
- % and tintTransform replaces it - see bug 549307
- % for details. Also see the test case of bug 689263.
- % Here we use mark...cleartomark to restore the stack
- % to its normal state.
- mark
- true % An extra value for bogus Adobe tintTransform
- 3 -1 roll
- //.cs_get_default_color exec setcolor
- cleartomark
- }
- {
- //.cs_validate exec
- //.cs_substitute exec
- //.cs_prepare exec
- //.cs_install exec
- dup //make_array1 exec //setcolorspace
- mark %See comments above
- true
- 3 -1 roll
- //.cs_get_default_color exec setcolor
- cleartomark
- }
- ifelse
- }
- stopped
- { //.cspace_util /setcolorspace get $error /errorname get signalerror }
- if
- }
-bind def
-
-/_setcolorspace_nosub
- {
- {
- //.cs_validate exec
- dup
- //.cs_prepare exec
- //.cs_install exec
- //make_array1 exec //setcolorspace
- }
- stopped
- { //.cspace_util /setcolorspace get $error /errorname get signalerror }
- if
- }
-bind def
-
-/setcolorspace { //true //_setcolorspace exec } bind odef
-/forcesetcolorspace { //false //_setcolorspace exec } bind odef
-
-%
-% - initgraphics -
-%
-% The initgraphics operator must be redefined create a real color space.
-% Previously this was unnecessary, as .currentcolorspace could return
-% an integer.
-%
-%
-/initgraphics
- { initgraphics //DeviceGray_array forcesetcolorspace }
-.bind systemdict begin odef end
-
-systemdict /setcolorspace .undef
-
-
-%
-% <gray> setgray -
-%
-% <r> <g> <b> setrgbcolor -
-%
-% <c> <m> <y> <b> setcmykcolor -
-%
-% The Level 1 color setting operators. setcmykcolor is created only if
-% setcolorscreen is present. These operators are always defined in
-% systemdict.
-%
-/setgray
- {
- { //DeviceGray_array //setcolorspace //setcolor }
- stopped
- { /setgray .systemvar $error /errorname get signalerror }
- if
- }
-bind systemdict begin odef end
-
-/setrgbcolor
- {
- { //DeviceRGB_array //setcolorspace //setcolor }
- stopped
- { /setrgbcolor .systemvar $error /errorname get signalerror }
- if
- }
-bind systemdict begin odef end
-
-/setcolorscreen where
- {
- pop
- /setcmykcolor
- {
- { //DeviceCMYK_array //setcolorspace //setcolor }
- stopped
- { /setcmykcolor .systemvar $error /errorname get signalerror }
- if
- }
- bind systemdict begin odef end
- }
-if
-
-
-%
-% - currentgray <gray>
-%
-% - currentrgbcolor <r> <g> <b>
-%
-% - currentcmykcolor <c> <m> <y> <k>
-%
-% Return the current color, mapped to a DeviceGray, DeviceRGB, or
-% DeviceCMYK color space. The latter is only created if setcolorscreen
-% is present.
-/currentgray
- { currentcolor currentcolorspace //.cs_get_currentgray exec }
-bind systemdict begin odef end
-
-/currentrgbcolor
- { currentcolor currentcolorspace //.cs_get_currentrgb exec }
-bind systemdict begin odef end
-
-/setcolorscreen where
- {
- pop
- /currentcmykcolor
- { currentcolor currentcolorspace //.cs_get_currentcmyk exec }
- bind systemdict begin odef end
- }
-if
-
-
-
-%
-% Add some generically useful structures and procedures to .cspace_util.
-%
-
-%
-% Some common errors. The command for these errors will normally be
-% overwritten by the invoking operator. We cannot "load" the secolorspace
-% or setcolor operators, as they are not present in Level 1 systems.
-%
-/setcspace_typecheck
- { /setcolorspace cvx /typecheck signalerror }
-bind def
-
-/setcspace_rangecheck
- { /setcolorspace cvx /rangecheck signalerror }
-bind def
-
-/setcspace_invalidaccess
- { /setcolorspace cvx /invalidaccess signalerror }
-bind def
-
-/setcspace_undefined
- { /setcolorspace cvx /undefined signalerror }
-bind def
-
-/setcolor_typecheck
- { /setcolor cvx /typecheck signalerror }
-bind def
-
-/setcolor_invalidaccess
- { /setcolor cvx /invalidaccess signalerror }
-bind def
-
-
-%
-% <obj> check_array <obj>
-%
-% Check that an object is an array. Currently we don't check for
-% readability, as a failing get or length operator should generate
-% the appropriate invalidaccess error.
-/check_array
- {
- dup type dup /arraytype ne exch /packedarraytype ne and
- { /setcolorspace cvx /typecheck signalerror }
- if
- }
-bind def
-
-
-% pre-defined procedures for cs_ncomps and cs_get_range
-/ncomps_1 { pop 1 } bind def
-/ncomps_3 { pop 3 } bind def
-/ncomps_4 { pop 4 } bind def
-
-/dflt_range_4 [ 0 1 0 1 0 1 0 1 ] readonly def
-/dflt_range_3 dflt_range_4 0 6 getinterval def
-/dflt_range_1 dflt_range_4 0 2 getinterval def
-
-% <obj> get_range_[1|3|4] <range>
-/get_range_1 { pop //dflt_range_1 } bind def
-/get_range_3 { pop //dflt_range_3 } bind def
-/get_range_4 { pop //dflt_range_4 } bind def
-
-
-%
-% <c1> ... <cn> <name | array> <n>
-% check_num_stack
-% <c1> ... <cn> <array | array>
-%
-% <c1> <array> validate_color_1 <c1>
-% <c1> <c2> <c3> <arraY> validate_color_3 <c1> <c2> <c3>
-% <c1> <c2> <c3> <c4> <arraY> validate_color_4 <c1> <c2> <c3> <c4>
-%
-% check_num_stack verifies that the stack consists of a color space array and
-% n numbers. This is used by most of the cs_prepare_color procedures. The
-% validate_color_[1|3|4] procedures can be used as the cs_prepare_color
-% procedure for Device specific, CIEBased, and Indexed color spaces.
-%
-% Note that the pseudo-operator that (indirectly) invokes this routine will
-% handle resetting the stacks.
-%
-/check_num_stack
- { % c1 .. cn [] n
- 1 1 3 2 roll % c1 .. cn [] 1 1 n
- { index
- type dup /integertype ne exch /realtype ne and
- //setcolor_typecheck
- if
- }
- for
- } bind def
-
-% <c1> <array> validate_1 <c1>
-/validate_1 { 1 //check_num_stack exec pop } bind def
-
-% <c1> <c2> <c3> <array> validate_3 <c1> <c2> <c3>
-/validate_3 { 3 //check_num_stack exec pop } bind def
-
-% <c1> <c2> <c3> <c4> <array> validate_4 <c1> <c2> <c3> <c4>
-/validate_4 { 4 //check_num_stack exec pop } bind def
-
-
-%
-% <obj> pop_1 -
-%
-% This is a procedure form of pop. It may be used where a procedure is
-% expected, but the function of the procedure is the same as the pop
-% operator.
-/pop_1 { pop } bind def
-
-%
-% <obj> dup_1 <obj> <obj>
-%
-% An analog to pop_1, this one for dup.
-%
-/dup_1 { dup } bind def
-
-%
-% <obj1> ... <objn> <n> clear_n_objs -
-%
-% Clear n objects from the operand stack.
-%
-/clear_n_objs { //pop_1 repeat } bind def
-
-%
-% <obj1> ... <objn> <array> clear_setcolor_operands -
-%
-% Clear the setcolor operands for a color space.
-%
-/clear_setcolor_operands
- { //.cs_get_ncomps exec //clear_n_objs exec }
-bind def
-
-%
-% Return 1, 3, or 4 zeros. These routines are used primarily for the
-% CIEBased color spaces, for which currentgray and currentrgb
-% should return 0 for all components, and currentcmyk should return
-% 0 0 0 1.0 (this varies from Adobe's documentation but is consistent
-% with their impelementations).
-%
-/no_currentgray { //.cs_get_ncomps exec //clear_n_objs exec 0. } bind def
-/no_currentrgb { //.cs_get_ncomps exec //clear_n_objs exec 0. 0. 0. } bind def
-/no_currentcmyk { //.cs_get_ncomps exec //clear_n_objs exec 0. 0. 0. 1.} bind def
-
-
-%
-% <num> bound_0_1 <num>
-%
-% Bound a number to the range [0.0, 1.0]
-%
-/bound_0_1
- {
- dup 0 lt
- { pop 0.0 }
- {
- dup 1 gt
- { pop 1.0 }
- if
- }
- ifelse
- }
-bind def
-
-
-%
-% Provide pseudo-operators for sethsbcolor and currenthsbcolor. These are
-% alternate versions of the setrgbcolor and currentrgbcolor operators, which
-% make use of a hue/staturation/brightness color description.
-%
-
-%
-% <num_1> ... <num_n> n max_n <num>
-% <num_1> ... <num_n> n min_n <num>
-%
-% Find the maximum and minum of 3 color component intensities.
-%
-/max_n
- {
- 1 sub
- { 2 copy lt { exch } if pop }
- repeat
- }
-bind def
-
-/min_n
- {
- 1 sub
- { 2 copy gt { exch } if pop }
- repeat
- }
-bind def
-
-
-%
-% <r> <g> <b> .rgb_2_hsb <h> <s> <br>
-% <h> <s> <br> .hsb_2_rgb <r> <g> <b>
-%
-% Convert between RGB and HSB colors, using the hexcone approach (see
-% Rogers, David, "Procedureal Elements For Computer Graphics",
-% (McGraw-Hill, 1985), pp. 402 - 3).
-%
-% The rgb ==> hsb calculation is:
-%
-% br = max(r, g, b)
-%
-% if (br == 0)
-% h = 0, s = 0;
-% else {
-% v = min(r, g, b)
-% diff = br - v;
-% sat = diff / br;
-% if (r == br)
-% h = (g - b) / (6 * diff) + (b > g ? 1 : 0);
-% else if (g == br)
-% h = 1/3 + (b - r) / (6 * diff);
-% else /* b == br */
-% h = 2/3 + (r - g) / (6 * diff);
-% }
-%
-% The hsb ==> rgb conversion is:
-%
-% mn = (1 - s) * br, md = 6 * s * br;
-%
-% switch ((int)floor(6 * h)) {
-% case 0: /* r >= g >= b */
-% r = br;
-% g = mn + h * md;
-% b = mn;
-% break;
-%
-% case 1: /* g >= r >= b */
-% r = mn + md * (1/3 - h);
-% g = br;
-% b = mn;
-% break;
-%
-% case 2: /* g >= b >= r */
-% r = mn;
-% g = br;
-% b = mn + (h - 1/3) * md;
-% break;
-%
-% case 3: /* b >= g >= r */
-% r = mn;
-% g = mn + (2/3 - h) * md;
-% b = br;
-% break;
-%
-% case 4: /* b >= r >= g */
-% r = mn + (h - 2/3) * md;
-% g = mn;
-% b = br;
-% break;
-%
-% case 5: /* r >= b >= g */
-% r = br;
-% g = mn;
-% b = mn + (1 - h) * md;
-% break;
-%
-% case 6: /* We have wrapped around the hexcone. Thus this case is
-% the same as case 0 with h = 0 */
-% h = 0;
-% r = br;
-% g = mn + h * md = mn;
-% b = mn;
-% break;
-% }
-%
-
-
-% Define 1/3 and 2/3 accurately (don't use literals like 0.333333).
-/.f1_3 1.0 3 div def
-/.f2_3 2.0 3 div def
-
-/.rgb_2_hsb
- {
- % find the largest and smallest components
- 3 copy 3 //max_n exec dup 5 1 roll
- dup 0.0 eq
- { pop pop pop pop 0.0 0.0 }
- {
- 4 copy pop 3 //min_n exec 1 index exch sub
- dup 2 index div 7 1 roll
- dup 0.0 eq
- { 5 { pop } repeat 0.0 3 1 roll }
- {
- 6.0 mul 5 1 roll
- 2 copy eq % blue == brightness
- { pop pop sub exch div //.f2_3 add }
- {
- 2 index eq % green == brightness
- { exch pop exch sub exch div //.f1_3 add }
- {
- % red == brightness
- sub exch pop exch div
- dup 0.0 lt
- { 1.0 add }
- if
- }
- ifelse
- }
- ifelse
- 3 1 roll
- }
- ifelse
- }
- ifelse
- }
-bind def
-
-
-/.hsb_2_rgb
- {
- 3 { 0.0 max 1.0 min 3 1 roll } repeat % h s b
- 1.0 2 index sub 1 index mul % h s b (1-s)*b
- 3 -1 roll 2 index mul 6.0 mul % h b (1-s)*b 6*s*b
- 4 -1 roll % b (1-s)*b=nm 6*s*b=md h
-
- % array of procedures for the 7 hue cases
- {
- % 0 ==> r >= g >= b % b nm md h
- { mul 1 index add exch }
-
- % 1 ==> g >= r >= b
- { //.f1_3 exch sub mul 1 index add 3 1 roll }
-
- % 2 ==> g >= b >= r
- { //.f1_3 sub mul 1 index add 3 1 roll exch 3 -1 roll }
-
- % 3 ==> b >= g >= r
- { //.f2_3 exch sub mul 1 index add 3 -1 roll }
-
- % 4 ==> b >= r >= g
- { //.f2_3 sub mul 1 index add 3 1 roll exch }
-
- % 5 ==> r >= b >= g
- { 1.0 exch sub mul 1 index add }
-
- % 6 ==> r = br, g = b = mn
- % Case 6 is the same as case 0 with h = 0. This also simplifies
- % the calculations.
- { pop pop dup }
- }
- 1 index 6.0 mul cvi % b (1-s)*b 6*s*b h {} int(6*h)
- get exec
- }
-bind def
-
-
-%
-% <hue> <saturation> <brightness sethsbcolor -
-%
-% - currenthsbcolor <hue> <saturation> <brightness>
-%
-/sethsbcolor
- {
- { //.hsb_2_rgb exec setrgbcolor }
- stopped
- { /sethsbcolor .systemvar $error /errorname get signalerror }
- if
- }
-bind systemdict begin odef end
-
-/currenthsbcolor
- {
- { currentrgbcolor //.rgb_2_hsb exec }
- stopped
- { /currenthsbcolor .systemvar $error /errorname get signalerror }
- if
- }
-bind systemdict begin odef end
-
-currentdict /DeviceGray_array .undef
-currentdict /DeviceRGB_array .undef
-currentdict /DeviceCMYK_array .undef
-
-end % .cspace_util
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_css_e.ps b/Master/tlpkg/tlgs/lib/gs_css_e.ps deleted file mode 100644 index 7537aa25590..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_css_e.ps +++ /dev/null @@ -1,114 +0,0 @@ -% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_css_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the CFF StandardStrings that represent characters.
-% This is a pseudo-encoding.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/CFFStandardStrings mark
-
-% 0
- /.notdef /space /exclam /quotedbl /numbersign
- /dollar /percent /ampersand /quoteright /parenleft
- /parenright /asterisk /plus /comma /hyphen
- /period /slash /zero /one /two
- /three /four /five /six /seven
- /eight /nine /colon /semicolon /less
- /equal /greater /question /at /A
- /B /C /D /E /F
- /G /H /I /J /K
- /L /M /N /O /P
-% 50
- /Q /R /S /T /U
- /V /W /X /Y /Z
- /bracketleft /backslash /bracketright /asciicircum /underscore
- /quoteleft /a /b /c /d
- /e /f /g /h /i
- /j /k /l /m /n
- /o /p /q /r /s
- /t /u /v /w /x
- /y /z /braceleft /bar /braceright
- /asciitilde /exclamdown /cent /sterling /fraction
-% 100
- /yen /florin /section /currency /quotesingle
- /quotedblleft /guillemotleft /guilsinglleft /guilsinglright /fi
- /fl /endash /dagger /daggerdbl /periodcentered
- /paragraph /bullet /quotesinglbase /quotedblbase /quotedblright
- /guillemotright /ellipsis /perthousand /questiondown /grave
- /acute /circumflex /tilde /macron /breve
- /dotaccent /dieresis /ring /cedilla /hungarumlaut
- /ogonek /caron /emdash /AE /ordfeminine
- /Lslash /Oslash /OE /ordmasculine /ae
- /dotlessi /lslash /oslash /oe /germandbls
-% 150
- /onesuperior /logicalnot /mu /trademark /Eth
- /onehalf /plusminus /Thorn /onequarter /divide
- /brokenbar /degree /thorn /threequarters /twosuperior
- /registered /minus /eth /multiply /threesuperior
- /copyright /Aacute /Acircumflex /Adieresis /Agrave
- /Aring /Atilde /Ccedilla /Eacute /Ecircumflex
- /Edieresis /Egrave /Iacute /Icircumflex /Idieresis
- /Igrave /Ntilde /Oacute /Ocircumflex /Odieresis
- /Ograve /Otilde /Scaron /Uacute /Ucircumflex
- /Udieresis /Ugrave /Yacute /Ydieresis /Zcaron
-% 200
- /aacute /acircumflex /adieresis /agrave /aring
- /atilde /ccedilla /eacute /ecircumflex /edieresis
- /egrave /iacute /icircumflex /idieresis /igrave
- /ntilde /oacute /ocircumflex /odieresis /ograve
- /otilde /scaron /uacute /ucircumflex /udieresis
- /ugrave /yacute /ydieresis /zcaron /exclamsmall
- /Hungarumlautsmall /dollaroldstyle /dollarsuperior /ampersandsmall /Acutesmall
- /parenleftsuperior /parenrightsuperior /twodotenleader /onedotenleader /zerooldstyle
- /oneoldstyle /twooldstyle /threeoldstyle /fouroldstyle /fiveoldstyle
- /sixoldstyle /sevenoldstyle /eightoldstyle /nineoldstyle /commasuperior
-% 250
- /threequartersemdash /periodsuperior /questionsmall /asuperior /bsuperior
- /centsuperior /dsuperior /esuperior /isuperior /lsuperior
- /msuperior /nsuperior /osuperior /rsuperior /ssuperior
- /tsuperior /ff /ffi /ffl /parenleftinferior
- /parenrightinferior /Circumflexsmall /hyphensuperior /Gravesmall /Asmall
- /Bsmall /Csmall /Dsmall /Esmall /Fsmall
- /Gsmall /Hsmall /Ismall /Jsmall /Ksmall
- /Lsmall /Msmall /Nsmall /Osmall /Psmall
- /Qsmall /Rsmall /Ssmall /Tsmall /Usmall
- /Vsmall /Wsmall /Xsmall /Ysmall /Zsmall
-% 300
- /colonmonetary /onefitted /rupiah /Tildesmall /exclamdownsmall
- /centoldstyle /Lslashsmall /Scaronsmall /Zcaronsmall /Dieresissmall
- /Brevesmall /Caronsmall /Dotaccentsmall /Macronsmall /figuredash
- /hypheninferior /Ogoneksmall /Ringsmall /Cedillasmall /questiondownsmall
- /oneeighth /threeeighths /fiveeighths /seveneighths /onethird
- /twothirds /zerosuperior /foursuperior /fivesuperior /sixsuperior
- /sevensuperior /eightsuperior /ninesuperior /zeroinferior /oneinferior
- /twoinferior /threeinferior /fourinferior /fiveinferior /sixinferior
- /seveninferior /eightinferior /nineinferior /centinferior /dollarinferior
- /periodinferior /commainferior /Agravesmall /Aacutesmall /Acircumflexsmall
-% 350
- /Atildesmall /Adieresissmall /Aringsmall /AEsmall /Ccedillasmall
- /Egravesmall /Eacutesmall /Ecircumflexsmall /Edieresissmall /Igravesmall
- /Iacutesmall /Icircumflexsmall /Idieresissmall /Ethsmall /Ntildesmall
- /Ogravesmall /Oacutesmall /Ocircumflexsmall /Otildesmall /Odieresissmall
- /OEsmall /Oslashsmall /Ugravesmall /Uacutesmall /Ucircumflexsmall
- /Udieresissmall /Yacutesmall /Thornsmall /Ydieresissmall
-% 379 = end
-
-counttomark packedarray exch pop
-10 1 index .registerencoding
-.defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_dbt_e.ps b/Master/tlpkg/tlgs/lib/gs_dbt_e.ps deleted file mode 100644 index 656669a38a3..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_dbt_e.ps +++ /dev/null @@ -1,59 +0,0 @@ -% Copyright (C) 1993, 1994 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_dbt_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Dingbats encoding vector.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/DingbatsEncoding
-% \000
- StandardEncoding 0 32 getinterval aload pop % /.notdef
-% \040
- /space /a1 /a2 /a202 /a3 /a4 /a5 /a119
- /a118 /a117 /a11 /a12 /a13 /a14 /a15 /a16
- /a105 /a17 /a18 /a19 /a20 /a21 /a22 /a23
- /a24 /a25 /a26 /a27 /a28 /a6 /a7 /a8
-% \100
- /a9 /a10 /a29 /a30 /a31 /a32 /a33 /a34
- /a35 /a36 /a37 /a38 /a39 /a40 /a41 /a42
- /a43 /a44 /a45 /a46 /a47 /a48 /a49 /a50
- /a51 /a52 /a53 /a54 /a55 /a56 /a57 /a58
-% \140
- /a59 /a60 /a61 /a62 /a63 /a64 /a65 /a66
- /a67 /a68 /a69 /a70 /a71 /a72 /a73 /a74
- /a203 /a75 /a204 /a76 /a77 /a78 /a79 /a81
- /a82 /a83 /a84 /a97 /a98 /a99 /a100 /.notdef
-% \200
- StandardEncoding 0 32 getinterval aload pop % /.notdef
-% \240
- /.notdef /a101 /a102 /a103 /a104 /a106 /a107 /a108
- /a112 /a111 /a110 /a109 /a120 /a121 /a122 /a123
- /a124 /a125 /a126 /a127 /a128 /a129 /a130 /a131
- /a132 /a133 /a134 /a135 /a136 /a137 /a138 /a139
-% \300
- /a140 /a141 /a142 /a143 /a144 /a145 /a146 /a147
- /a148 /a149 /a150 /a151 /a152 /a153 /a154 /a155
- /a156 /a157 /a158 /a159 /a160 /a161 /a163 /a164
- /a196 /a165 /a192 /a166 /a167 /a168 /a169 /a170
-% \340
- /a171 /a172 /a173 /a162 /a174 /a175 /a176 /a177
- /a178 /a179 /a193 /a180 /a199 /a181 /a200 /a182
- /.notdef /a201 /a183 /a184 /a197 /a185 /a194 /a198
- /a186 /a195 /a187 /a188 /a189 /a190 /a191 /.notdef
-256 packedarray .defineencoding
-3 DingbatsEncoding .registerencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_devcs.ps b/Master/tlpkg/tlgs/lib/gs_devcs.ps deleted file mode 100644 index 08ad3591978..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_devcs.ps +++ /dev/null @@ -1,250 +0,0 @@ -% Copyright (C) 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_devcs.ps 7216 2006-11-22 01:26:37Z ray $
-% Device-specific color space method dictionaries.
-
-%
-% This file implements the method dictionaries for the Device-specific
-% color spaces. See gs_cspace.ps for information.
-%
-% Note that, because these color spaces are parameter-less, no color
-% space validation is required: if we can get to the color space methods,
-% we know the color space is legitimate.
-%
-% The colorspace substitution routines for these color spaces
-% (cs_substitute) will fail in a Level 1 system, but this is not a
-% problem as .getuseciecolor will always return false for such systems.
-%
-.currentglobal true .setglobal
-.cspace_util begin
-
-%
-% <r> <g> <b> rgb_2_gray <gray>
-%
-% Convert RGB colors to gray. This includes a special check for
-% r == g == b, and avoids roundoff error if this is the case.
-%
-/rgb_2_gray
- {
- 3 copy 1 index eq 3 1 roll eq and
- { pop pop }
- { .11 mul exch .59 mul add exch .3 mul add }
- ifelse
- }
-bind def
-
-systemdict /..page_default_spaces 3 dict put
-
-% <color_space_name> ..includecolorspace -
-/..includecolorspace
-{ % Only includes ones explicitly defined by the document.
- systemdict /..page_default_spaces get 1 index known {
- pop
- } {
- mark exch
- { dup /ColorSpace resourcestatus {
- pop 0 eq {
- systemdict /..page_default_spaces get 1 index //true put
- gsave
- { dup /ColorSpace findresource //_setcolorspace_nosub exec .includecolorspace
- } stopped pop
- grestore
- } if
- } if
- } stopped pop
- cleartomark
- } ifelse
-} bind def
-
-% <color_space> <color_space_name> cs_substitute_generic <color_space1> <color_space2>
-/cs_substitute_generic
-{ .getuseciecolor
- { NOSUBSTDEVICECOLORS
- { //..includecolorspace exec dup }
- { /ColorSpace findresource }
- ifelse
- }
- { pop dup }
- ifelse
-}
-bind def
-
-% <color_space> <color_space_name> cs_substitute_DeviceRGB_for_PDFX_or_PDFA <color_space1> <color_space2>
-/cs_substitute_DeviceRGB_for_PDFX_or_PDFA
-{ systemdict /PDFX .knownget not { false } if
- systemdict /PDFA .knownget not { false } if
- or {
- dup /ColorSpace resourcestatus {
- pop pop
- } {
- (Error: Need a /DefaultRGB /ColorSpace resource for generating a PDF/X or PDF/A document.) =
- /cs_substitute_DeviceRGB_for_PDFX_or_PDFA cvx /undefined signalerror
- } ifelse
- /ColorSpace findresource
- } {
- //cs_substitute_generic exec
- } ifelse
-} bind def
-
-colorspacedict
-
-dup
-/DeviceGray
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate true
- /cs_get_ncomps //ncomps_1
- /cs_get_range //get_range_1
- /cs_get_default_color { pop 0.0 } bind
- /cs_get_currentgray //pop_1
- /cs_get_currentrgb { pop dup dup } bind
- /cs_get_currentcmyk { pop 1.0 exch sub 0.0 0.0 0.0 4 -1 roll } bind
- /cs_validate {}
-
- /cs_substitute
- { /DefaultGray //cs_substitute_generic exec
- }
- bind
-
- /cs_prepare {}
- /cs_install { pop 0 .setdevcspace } bind
- /cs_prepare_color //validate_1
- /cs_complete_setcolor //pop_1
- .dicttomark
-put
-
-
-/DeviceRGB
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate true
- /cs_get_ncomps //ncomps_3
- /cs_get_range //get_range_3
- /cs_get_default_color { pop 0.0 0.0 0.0 } bind
- /cs_get_currentgray { pop //rgb_2_gray exec } bind
- /cs_get_currentrgb //pop_1
-
- % to convert to cmyk use blackgeneration and undercolorremoval
- /cs_get_currentcmyk
- {
- pop
-
- % convert to subtractive (CMY) color space
- 3
- { 1.0 exch sub 3 1 roll }
- repeat
-
- % find the minimum (initial k component)
- 3 copy
- 2
- {
- 2 copy gt
- { exch }
- if
- pop
- }
- repeat
-
- % apply undercolorremoval
- dup 5 1 roll currentundercolorremoval exec cvr 4 1 roll
- 3
- { 3 index sub //bound_0_1 exec 3 1 roll }
- repeat
-
- % apply blackgeneration
- 5 3 roll pop currentblackgeneration exec cvr //bound_0_1 exec
- }
- bind
-
- /cs_validate {}
-
- /cs_substitute
- { /DefaultRGB //cs_substitute_DeviceRGB_for_PDFX_or_PDFA exec
- }
- bind
-
- /cs_prepare {}
- /cs_install { pop 1 .setdevcspace } bind
- /cs_prepare_color //validate_3
- /cs_complete_setcolor //pop_1
- .dicttomark
-put
-
-end % .cspace_util
-.setglobal
-
-
-% Only create the DeviceCMYK color space if setcolorscreen is present
-/setcolorscreen where
- { pop }
- { currentfile closefile }
-ifelse
-
-
-.currentglobal true .setglobal
-.cspace_util begin
-
-colorspacedict
-/DeviceCMYK
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate true
- /cs_get_ncomps //ncomps_4
- /cs_get_range //get_range_4
- /cs_get_default_color { pop 0.0 0.0 0.0 1.0 } bind
-
- /cs_get_currentgray
- { pop 4 1 roll //rgb_2_gray exec add 1.0 exch sub //bound_0_1 exec }
- bind
-
- /cs_get_currentrgb
- {
- pop
- 4 1 roll 3
- { 3 index add 1.0 exch sub //bound_0_1 exec 3 1 roll }
- repeat
- 4 -1 roll pop
- }
- bind
-
- /cs_get_currentcmyk //pop_1
-
- /cs_validate {}
-
- /cs_substitute
- { /DefaultCMYK //cs_substitute_generic exec
- }
- bind
-
- /cs_prepare {}
- /cs_install { pop 2 .setdevcspace } bind
- /cs_prepare_color //validate_4
- /cs_complete_setcolor //pop_1
- .dicttomark
-put
-
-currentdict /..includecolorspace .undef
-currentdict /cs_substitute_generic .undef
-
-end % .cspace_util
-.setglobal
-
diff --git a/Master/tlpkg/tlgs/lib/gs_devn.ps b/Master/tlpkg/tlgs/lib/gs_devn.ps deleted file mode 100644 index 7b717123816..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_devn.ps +++ /dev/null @@ -1,218 +0,0 @@ -% Copyright (C) 2001, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_devn.ps 8048 2007-06-13 16:27:33Z tim $
-% DeviceN color space method dictionary; this depends on gs_sepr.ps
-
-
-% verify that DeviceN and Separation color spaces are supported
-/.setdevicenspace where
- {
- pop
- /.setseparationspace where
- { pop //false }
- { //true }
- ifelse
- }
- { //true }
-ifelse
- { currentfile closefile }
-if
-
-.currentglobal true .setglobal
-.cspace_util begin
-
-
-%
-% <c1> ... <cm> <array> apply_devn_tint_xform <c1>' ... <cn>' <array>
-%
-% Apply the tint transformation for the DeviceN color intensity values.
-/apply_devn_tint_xform
- {
- dup 1 get length 1 add exch
- mark 2 index 2 add 2 roll
- index 3 get exec
- counttomark 2 add -2 roll pop
- }
-bind def
-
-
-
-colorspacedict
-/DeviceN
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate false
- /cs_potential_icc_alternate false
- /cs_get_ncomps { 1 get length } bind
- /cs_get_range { 1 get length [ exch { 0 1 } repeat ] } bind
- /cs_get_default_color { 1 get length { 1 } repeat } bind
-
- /cs_get_currentgray
- { //apply_devn_tint_xform exec 2 get //.cs_get_currentgray exec }
- bind
- /cs_get_currentrgb
- { //apply_devn_tint_xform exec 2 get //.cs_get_currentrgb exec }
- bind
- /cs_get_currentcmyk
- { //apply_devn_tint_xform exec 2 get //.cs_get_currentcmyk exec }
- bind
-
- % a lot of validation is done by the cs_validate method
- /cs_validate
- {
- //check_array exec
- dup 1 get //check_array exec
- {
- type dup /nametype ne exch /stringtype ne and
- //setcspace_typecheck
- if
- }
- forall
- dup 2 get //.cs_validate exec //.cs_potential_alternate exec not
- //setcspace_rangecheck
- if
- dup 3 get //check_array exec xcheck not
- //setcspace_typecheck
- if
- }
- bind
-
- % substitute the base space if appropriate
- /cs_substitute
- {
- dup 2 get //.cs_substitute exec 2 copy eq
- { pop pop dup }
- {
- % retain only the new alternate space
- exch pop
-
- % build all new structures in local VM
- .currentglobal 3 1 roll //false .setglobal
-
- % construct a new array and insert the new base color space
- 1 index dup length array copy dup 2 4 -1 roll put
-
- % restore VM mode
- 3 -1 roll .setglobal
- }
- ifelse
- }
- bind
-
- %
- % The Ghostscript interpreter works better when tinttransform procedures
- % are translated into functions. Attempt to do that here.
- %
- /cs_prepare //converttinttransform
-
- %
- % Install the current color space.
- %
- % The current Ghostscript color space implementation requires that
- % color spaces that provide a base or alternative color space set
- % that base/alternative color space to be the current color space
- % before attempting to set the original color space.
- %
- % Beginning with Acrobat 5, PDF apparently supports 1-component
- % DeviceN color spaces with the single component "All" (the "PDF
- % Reference", 3rd ed., p. 206 still describes this as illegal).
- % We translate such calls to Separation color spaces.
- %
- /cs_install
- {
- % save the current color space
- currentcolorspace
-
- % set the base color space as the current color space
- 1 index 2 get //forcesetcolorspace
-
- % set the indexed color space; restore the earlier space on error
- mark 2 index
- dup 1 get dup length 1 eq exch 0 get /All eq and
- {
- dup length array copy
- dup 0 /Separation put
- dup 1 /All put
- { .setseparationspace }
- } {
- {
- dup .setdevicenspace
- % Check if the DeviceN color space includes an 'attributes'
- % dict with a Colorants dict. If present then we want to
- % attach the separation colorspace in the Colorants dict to
- % the DeviceN color space description within the graphics
- % library. To do this we are creating a temp gstate, building
- % each of the Colorants color spaces in the temp gstate and
- % then attaching the temp color space to the DeviceN color
- % space. This round about procedure is done to create
- % descriptions of the Colorants color spaces which are
- % equivalent to any other color space (i.e. with color space
- % substitution performed on the alternate color space and the
- % tint transform function sampled).
- dup length 4 gt {
- dup 4 get /Colorants .knownget {
- { gsave
- { % Ignore any problems with the Colorants color spaces
- //forcesetcolorspace .attachdevicenattributespace
- } stopped pop
- grestore
- } forall
- } if
- } if
- pop
- }
- }
- ifelse
- stopped
- { cleartomark setcolorspace stop }
- { pop pop pop }
- ifelse
- }
- bind
-
- /cs_prepare_color { dup 1 get length //check_num_stack exec pop } bind
-
- %
- % If a DeviceN color space is not supported in native mode by
- % the current process color model, Adobe implementations will always
- % execute the tint transform procedure when setcolor is invoked.
- % Ghostscript may have turned this transform into a sampled function,
- % and even if this is not the case, will have sampled the transform
- % when the color space is first set. Some applications depend on
- % the Adobe behavior, so we implement it via the cs_complete_setcolor
- % method.
- %
- /cs_complete_setcolor
- {
- .usealternate
- {
- pop
- currentcolor
- currentcolorspace 3 get exec
- currentcolorspace 2 get
- //clear_setcolor_operands exec
- }
- { pop }
- ifelse
- }
- bind
-
- .dicttomark
-put
-
-end % .cspace_util
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_devpxl.ps b/Master/tlpkg/tlgs/lib/gs_devpxl.ps deleted file mode 100644 index 4f604f5d711..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_devpxl.ps +++ /dev/null @@ -1,78 +0,0 @@ -% Copyright (C) 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_devpxl.ps 6300 2005-12-28 19:56:24Z giles $
-% DevicePixel color space method dictionaries.
-
-%
-% This file implements the DevicePixel color space. See gs_cspace.ps
-% for information.
-%
-% The DevicePixel color space includes a single parameter, the bit
-% depth of the device color representation. Color is expressed as
-% single integers in an opaque, device-specific format.
-%
-
-% verify that the DevicePixel color space is supported
-/.setdevicepixelspace where
- { pop }
- { currentfile closefile }
-ifelse
-
-
-.currentglobal true .setglobal
-
-.cspace_util begin
-
-
-colorspacedict
-/DevicePixel
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate true
- /cs_get_ncomps //ncomps_1
- /cs_get_range { [ exch 1 get 1 exch bitshift 1 sub ] } bind
- /cs_get_default_color { pop 0 } bind % no good default
- /cs_get_currentgray //no_currentgray
- /cs_get_currentrgb //no_currentrgb
- /cs_get_currentcmyk //no_currentcmyk
-
- /cs_validate
- {
- //check_array exec
- dup 1 get dup type /integertype ne
- //setcspace_typecheck
- if
- dup 0 lt
- //setcspace_rangecheck
- if
- 31 gt % 31 bits is an implementation limit
- { /setcolorspace .systemvar /limitcheck signalerror }
- if
- }
- bind
-
- /cs_substitute //dup_1
- /cs_prepare {}
- /cs_install { .setdevicepixelspace } bind
- /cs_prepare_color //validate_1
- /cs_complete_setcolor //pop_1
- .dicttomark
-put
-
-end % .cspace_util
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_diskf.ps b/Master/tlpkg/tlgs/lib/gs_diskf.ps deleted file mode 100644 index ee8f473facf..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_diskf.ps +++ /dev/null @@ -1,224 +0,0 @@ -% Copyright (C) 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_diskf.ps 6300 2005-12-28 19:56:24Z giles $
-% Support for converting Type 1 fonts without eexec encryption to
-% Type 4 fonts that load individual character outlines on demand.
-
-% If DISKFONTS is true, we load individual CharStrings as they are needed.
-% (This is intended primarily for machines with very small memories.)
-% Initially, the character definition is the file position of the definition;
-% this gets replaced with the actual CharString.
-% Note that if we are loading characters lazily, CharStrings is writable.
-
-% _Cstring must be long enough to hold the longest CharString for
-% a character defined using seac. This is lenIV + 4 * 5 (for the operands
-% of sbw, assuming div is not used) + 2 (for sbw) + 3 * 5 (for the operands
-% of seac other than the character codes) + 2 * 2 (for the character codes)
-% + 2 (for seac), i.e., lenIV + 43.
-
-/_Cstring 60 string def
-
-% When we initially load the font, we call
-% <index|charname> <length> <readproc> cskip_C
-% to skip over each character definition and return the file position instead.
-% This substitutes for the procedure
-% <index|charname> <length> string currentfile exch read[hex]string pop
-% [encrypt]
-% What we actually store in the CharString is fileposition * 1000 + length,
-% negated if the string is stored in binary form.
-
-/cskip_C
- { exch dup 1000 ge 3 index type /nametype ne or
- { % This is a Subrs string, or the string is so long we can't represent
- % its length. Load it now.
- exch exec
- }
- { % Record the position and length, and skip the string.
- dup currentfile fileposition 1000 mul add
- 2 index 3 get /readstring cvx eq { neg } if
- 3 1 roll
- dup _Cstring length idiv
- { currentfile _Cstring 3 index 3 get exec pop pop
- } repeat
- _Cstring length mod _Cstring exch 0 exch getinterval
- currentfile exch 3 -1 roll 3 get exec pop pop
- }
- ifelse
- } bind def
-
-% Load a CharString from the file. The font is the top entry
-% on the dictionary stack.
-/load_C % <charname> <fileposandlength> load_C -
- { dup abs 1000 idiv FontFile exch setfileposition
- CharStrings 3 1 roll
- .currentglobal CharStrings .gcheck .setglobal exch
- dup 0 lt
- { neg 1000 mod string FontFile exch readstring }
- { 1000 mod string FontFile exch readhexstring }
- ifelse pop
- exch .setglobal
-% If the CharStrings aren't encrypted on the file, encrypt now.
- Private /-| get 0 get
- dup type /nametype ne
- { dup length 5 sub 5 exch getinterval exec }
- { pop }
- ifelse dup 4 1 roll put
-% If the character is defined with seac, load its components now.
- mark exch seac_C
- counttomark
- { StandardEncoding exch get dup CharStrings exch get
- dup type /integertype eq { load_C } { pop pop } ifelse
- } repeat
- pop % the mark
- } bind def
-
-/seac_C % <charstring> seac_C <achar> <bchar> ..or nothing..
- { dup length _Cstring length le
- { 4330 exch _Cstring .type1decrypt exch pop
- dup dup length 2 sub 2 getinterval <0c06> eq % seac
- { dup length
- Private /lenIV known { Private /lenIV get } { 4 } ifelse
- exch 1 index sub getinterval
-% Parse the string just enough to extract the seac information.
-% We assume that the only possible operators are hsbw, sbw, and seac,
-% and that there are no 5-byte numbers.
- mark 0 3 -1 roll
- { exch
- { { dup 32 lt
- { pop 0 }
- { dup 247 lt
- { 139 sub 0 }
- { dup 251 lt
- { 247 sub 256 mul 108 add 1 1 }
- { 251 sub -256 mul -108 add -1 1 }
- ifelse
- }
- ifelse
- }
- ifelse
- } % 0
- { mul add 0 } % 1
- }
- exch get exec
- }
- forall pop
- counttomark 1 add 2 roll cleartomark % pop all but achar bchar
- }
- { pop % not seac
- }
- ifelse
- }
- { pop % punt
- }
- ifelse
- } bind def
-
-% Define replacement procedures for loading fonts.
-% If DISKFONTS is true and the body of the font is not encrypted with eexec:
-% - Prevent the CharStrings from being made read-only.
-% - Substitute a different CharString-reading procedure.
-% (eexec disables this because the implicit 'systemdict begin' hides
-% the redefinitions that make the scheme work.)
-% We assume that:
-% - The magic procedures (-|, -!, |-, and |) are defined with
-% executeonly or readonly;
-% - The contents of the reading procedures are as defined in bdftops.ps;
-% - The font includes the code
-% <font> /CharStrings <CharStrings> readonly put
-/.loadfontdict 6 dict def mark
- /begin % push this dict after systemdict
- { dup begin
- //systemdict eq { //.loadfontdict begin } if
- } bind
- /end % match begin
- { currentdict end
- //.loadfontdict eq currentdict //systemdict eq and { end } if
- } bind
- /dict % leave room for FontFile, BuildChar, BuildGlyph
- { 3 add dict
- } bind
- /executeonly % for reading procedures
- { readonly
- }
- /noaccess % for Subrs strings and Private dictionary
- { readonly
- }
- /readonly % for procedures and CharStrings dictionary
- { % We want to take the following non-standard actions here:
- % - If the operand is the CharStrings dictionary, do nothing;
- % - If the operand is a number (a file position replacing the
- % actual CharString), do nothing;
- % - If the operand is either of the reading procedures (-| or -!),
- % substitute a different one.
- dup type /dicttype eq % CharStrings or Private
- count 2 gt and
- { 1 index /CharStrings ne { readonly } if }
- { dup type /arraytype eq % procedure or data array
- { dup length 5 ge 1 index xcheck and
- { dup 0 get /string eq
- 1 index 1 get /currentfile eq and
- 1 index 2 get /exch eq and
- 1 index 3 get dup /readstring eq exch /readhexstring eq or and
- 1 index 4 get /pop eq and
- { /cskip_C cvx 2 packedarray cvx
- }
- { readonly
- }
- ifelse
- }
- { readonly
- }
- ifelse
- }
- { dup type /stringtype eq % must be a Subr string
- { readonly }
- if
- }
- ifelse
- }
- ifelse
- } bind
- /definefont % to insert BuildChar/Glyph and change FontType
- { dup /FontType get 1 eq
- { dup /FontType 4 put
- dup /BuildChar /build_C load put
- dup /BuildGlyph /build_C load put
- }
- if definefont
- } bind
-counttomark 2 idiv { .loadfontdict 3 1 roll put } repeat pop
-.loadfontdict readonly pop
-
-% Define the BuildChar and BuildGlyph procedures for modified fonts.
-% A single procedure serves for both.
-/build_C % <font> <code|name> build_C -
- { 1 index begin
- dup dup type /integertype eq { Encoding exch get } if
- % Stack: font code|name name
- dup CharStrings exch .knownget not
- { 2 copy eq { exch pop /.notdef exch } if
- QUIET not
- { (Substituting .notdef for ) print = flush }
- { pop }
- ifelse
- /.notdef CharStrings /.notdef get
- } if
- % Stack: font code|name name charstring
- dup type /integertype eq
- { load_C end build_C }
- { end .type1execchar }
- ifelse
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/gs_diskn.ps b/Master/tlpkg/tlgs/lib/gs_diskn.ps deleted file mode 100644 index 6ff64c86f88..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_diskn.ps +++ /dev/null @@ -1,214 +0,0 @@ -% Copyright (C) 1990, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_diskn.ps 6300 2005-12-28 19:56:24Z giles $
-% Initialization file for %disk device modifications
-% When this is run, systemdict is still writable,
-
-systemdict begin
-
-% Collect the list of searchable IODevices in SearchOrder
-% Efficiency here doesn't matter since we run this at the end
-% of gs_init and convert it to a static array.
-/.getsearchabledevs { % - .getsearchabledevs [ list_of_strings ]
- //systemdict /.searchabledevs .knownget not {
- .currentglobal true .setglobal
- mark (*) {
- dup length string copy dup currentdevparams /Searchable
- .knownget { not { pop } if } { pop } ifelse
- } 8192 string /IODevice resourceforall
- ]
- % now process the array into correct SearchOrder
- 0 1 2 {
- mark exch 2 index {
- dup currentdevparams /SearchOrder get 2 index eq
- { exch } { pop } ifelse
- } forall % devices on the old list
- pop
- % make the array and sort it by name
- ] { lt } bind .sort
- exch
- } for
- % collect all devices with SearchOrder > 2
- mark 2 index {
- dup currentdevparams /SearchOrder get 2 gt
- { exch } { pop } ifelse
- } forall
- ] exch pop
- % We now have 4 arrays on the stack, SO=0 SO=1 SO=2 SO>2
- % make them into a single array
- mark 5 1 roll ] mark exch { { } forall } forall ]
- //systemdict /.searchabledevs 2 index .forceput
- exch .setglobal
- }
- if
-} .bind executeonly def % must be bound and hidden for .forceput
-
-% Modify .putdevparams to force regeneration of .searchabledevs list
-/.putdevparams {
- % We could be smarter and check for %disk* device, but this
- % doesn't get run enough to justify the complication
- //.putdevparams
- //systemdict /.searchabledevs .forceundef
-} .bind odef % must be bound and hidden for .forceundef
-
-% ------ extend filenameforall to handle wildcards in %dev% part of pattern -------%
-/filenameforall {
- count 3 ge {
- 2 index (%) search {
- pop pop
- } {
- % no device specified, so search them all
- pop (*%) 3 index concatstrings
- % we need to suppress the device when we return the string
- % in order to match Adobe's behaviour with %disk devices.
- 4 -2 roll % the callers procedure
- [ { (%) search { pop pop (%) search { pop pop } if } if } /exec load
- 4 -1 roll % the callers procedure
- /exec load
- ] cvx
- 4 2 roll % put the modified procedure where it belongs
- } ifelse
- % extract device portion (up to end of string or next %)
- (%) search { exch pop } if % stack: opat proc scratch npat device
- dup (*) search { pop pop pop true } { pop false } ifelse
- 1 index (?) search { pop pop pop true } { pop false } ifelse
- or not {
- pop pop //filenameforall % device with no wildcard
- } {
- (%) concatstrings (%) exch concatstrings
- .getsearchabledevs
- % find all matching devices and add the rest of the search string
- mark exch {
- dup counttomark 1 add index .stringmatch {
- counttomark 2 add index concatstrings
- } {
- pop
- } ifelse
- } forall
- ]
- 3 1 roll pop pop
- 4 -1 roll pop
- % now we need to invoke filenameforall for each of the strings
- % in the array. We do this by building a procedure that is like
- % an unrolled 'forall' loop. We do this to get the parameters
- % for each filenameforall, since each execution will pop its
- % parameters, but we can't use the operand stack for storage
- % since each invocation must have the same operand stack.
- mark exch {
- counttomark dup 3 add index exch
- 2 add index
- /filenameforall load
- } forall
- ] cvx
- 3 1 roll pop pop
- exec % run our unrolled loop
- }
- ifelse
- } {
- //filenameforall % not enough parameters -- just let it fail
- }
- ifelse
-} odef
-
-% redefine file to search all devices in order
-/file {
- dup 0 get (r) 0 get eq dup {
- pop false % success code
- 2 index 0 get 37 eq { [ () ] } { .getsearchabledevs } ifelse
- { 3 index concatstrings % prepend the device
- {
- 2 index //file } .internalstopped not {
- 4 1 roll pop pop pop true
- exit % exit with success
- } {
- pop pop
- }
- ifelse
- }
- forall
- }
- if
- not { % just let standard file operator handle things
- //file
- }
- if
-} bind odef
-
-% redefine deletefile to search all devices in order
-/deletefile {
- false % success code
- 1 index 0 get 37 eq { [ () ] } { .getsearchabledevs } ifelse
- { 2 index concatstrings % prepend the device
- { //deletefile } .internalstopped exch pop not {
- pop true exit % exit with success
- }
- if
- }
- forall
- not { $error /errorname get /deletefile .systemvar exch signalerror } if
-} bind odef
-
-% redefine status to search all devices in order
-/status {
- dup type /stringtype eq {
- false % success code
- 1 index 0 get 37 eq { [ () ] } { .getsearchabledevs } ifelse
- { 2 index concatstrings % prepend the device
- { //status } .internalstopped not {
- { true 7 -2 roll pop pop true exit } % exit with success
- if
- }
- if
- }
- forall
- % If we made it this far, no devices were found to status the file
- % clean up to return 'false'
- exch pop
- } {
- //status
- }
- ifelse
-} bind odef
-
-% Also redefine renamefile to search all devices in order
-/renamefile {
- false % success code
- 2 index 0 get 37 eq { [ () ] } { .getsearchabledevs } ifelse
- { dup 4 index concatstrings % prepend the device
- { (r) //file } .internalstopped
- not {
- closefile exch pop true exit % exit with success
- } {
- pop pop
- } ifelse
- }
- forall
- not { $error /errorname get /renamefile .systemvar exch signalerror } if
- 3 -1 roll concatstrings exch
- //renamefile
-} bind odef
-
-% redefine devforall to process devices in numeric order
-% Spec's for 'devforall' are unclear, but font downloaders may expect this
-/devforall { % <proc> <scratch> devforall -
- [ { dup length string copy } 2 index //devforall ]
- % stack: proc scratch array_of_device_names
- { lt } .sort
- % We don't really invoke the procedure with the scratch string
- % but rather with the strings from our array
- exch pop exch forall
-} odef
-end % systemdict
diff --git a/Master/tlpkg/tlgs/lib/gs_dpnxt.ps b/Master/tlpkg/tlgs/lib/gs_dpnxt.ps deleted file mode 100644 index 2c0b5cdc1d6..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_dpnxt.ps +++ /dev/null @@ -1,134 +0,0 @@ -% Copyright (C) 1997, 1998 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_dpnxt.ps 6699 2006-04-03 13:43:22Z alexcher $
-% gs_dpnxt.ps
-% NeXT Display PostScript extensions
-
-% Define the operation values for compositing. These must match the values
-% in gsdpnext.h, which also are the ones from the NeXT documentation.
-% We put them in systemdict, which seems like as good a place as any.
-mark
- /Clear /Copy /Sover /Sin /Sout /Satop /Dover /Din /Dout /Datop /Xor
- /PlusD /PlusL /Highlight % not sure about Highlight
-counttomark { counttomark 1 sub def } repeat pop
-
-% We implement readimage and sizeimage using the following 3 otherwise
-% undocumented lower-level operators:
-%
-% <x> <y> <width> <height> <matrix> .sizeimagebox
-% <dev_x> <dev_y> <dev_width> <dev_height> <matrix>
-%
-% - .sizeimageparams <bits/sample> <multiproc> <ncolors>
-%
-% <device> <x> <y> <width> <max_height> <alpha?> <std_depth|null>
-% <string> .getbitsrect <height> <substring>
-%
-% NOTE: These operators are subject to change without notice!
-
-% Implement readimage using .getbitsrect. Experimentation on a NeXT system
-% shows that the data is always returned in order of increasing device Y,
-% regardless of the CTM.
-%
-% Note that we can't make stack protection work for this operator,
-% because it must remove its operands from the stack before calling
-% the supplied procedure(s).
-
-/readimage { % <x> <y> <width> <height> <proc> [... <procN-1>]
- % <string> <alpha?> readimage -
- .sizeimageparams exch {
- % multiproc = true. If N > 1, store the procedures in an array.
- exch pop 1 index { 1 add } if
- % Stack: ... string alpha? nprocs
- dup 1 eq {
- pop false % only 1 procedure, multiproc is irrelevant
- } {
- dup array 4 1 roll 3 add 2 roll astore 3 1 roll true
- } ifelse
- } {
- % multiproc = false.
- pop pop false
- } ifelse
- % Map the rectangle to device coordinates.
- % Stack: x y w h proc(s) str alpha? multi?
- 8 -4 roll matrix .sizeimagebox pop 8 4 roll
- % Make sure we allocate the operand array in local VM
- % to avoid a possible invalidaccess.
- .currentglobal false .setglobal 9 1 roll
- exch { 1 } { 0 } ifelse exch % alpha is last, if present
- exch 4 1 roll 8 array astore exch .setglobal
- { % Read out a block of scan lines and pass them to the procedure.
- % Stack: [x y w h alpha? proc(s) str multi?] -- we must consume this.
- dup 3 get 0 eq { pop exit } if
- aload 9 1 roll pop exch pop currentdevice 7 1 roll
- % Always read out the data as standard (not native) pixels.
- .sizeimageparams pop pop exch .getbitsrect
- % Stack: [x y w h alpha? proc(s) str multi?] hread substr
- 3 -1 roll
- % Stack: hread substr [x y w h alpha? proc(s) str multi?]
- dup 1 2 copy get 5 index add put
- % Stack: hread substr [x y' w h alpha? proc(s) str multi?]
- dup 3 2 copy get 6 -1 roll sub put
- % Stack: substr [x y' w h' alpha? proc(s) str multi?]
- dup 5 get exch 7 get {
- % multiproc = true, pass each plane to a different procedure.
- % Stack: substr procs
- 0 1 2 index length 1 sub {
- % Push 1 plane and its procedure under the top 2 elements.
- % Stack: ... substr procs plane#
- 2 index length 2 index length idiv % bytes per plane
- dup 2 index mul exch
- % Stack: ... substr procs plane# start length
- 4 index 3 1 roll getinterval 4 1 roll
- 2 copy get 4 1 roll pop
- } for
- exch pop length 2 mul .execn
- } {
- % multiproc = false, just call the procedure.
- exec
- } ifelse
- } //systemdict /exec get 3 packedarray cvx loop
-} bind odef
-
-%
-% <w> <h> <bpc> <mtx> <dsrc0> ... <multi> <ncomp> alphaimage -
-%
-img_utils_dict begin
-/.alphaimage where
- {
- pop
- currentglobal true setglobal
- /alphaimage
- {
- //true
- //.colorimage
- stopped
- { /alphaimage .systemvar $error /errorname get signalerror }
- if
- }
- .bind systemdict begin odef end
- setglobal
- }
-if
-end
-
-% Implement sizeimage using lower-level operators.
-
-/sizeimage { % <x> <y> <width> <height> <matrix> sizeimage
- % <devwidth> <devheight> <bits/sample> <matrix>
- % <multiproc> <ncolors>
- .sizeimagebox 5 -2 roll pop pop
- .sizeimageparams 3 -1 roll 4 1 roll
-} bind odef
diff --git a/Master/tlpkg/tlgs/lib/gs_dps.ps b/Master/tlpkg/tlgs/lib/gs_dps.ps deleted file mode 100644 index 6685e5fbd6e..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_dps.ps +++ /dev/null @@ -1,224 +0,0 @@ -% Copyright (C) 1997, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_dps.ps 6970 2006-08-05 04:33:11Z lpd $
-% Initialization file for Display PostScript functions.
-
-% ------ Errors ------ %
-
-% These errors are only defined in DPS.
-{ /invalidcontext /invalidid } { .registererror } forall
-
-% ------ Contexts ------ %
-
-% To create a context with private local VM, we use the .localfork
-% operator to actually create the context, the new VM, and an empty
-% userdict, and then we call the .initlocaldicts procedure to make
-% local copies of the initial contents of the dictionaries in local VM.
-% savedlocaldicts in systemdict is a global read-only dictionary whose
-% elements are global read-only copies of these initial contents;
-% we just copy its elements into local VM and install them in systemdict.
-% userdict and internaldict require special handling.
-
-% Switching between contexts with different local VMs requires
-% changing the bindings in systemdict that reference local objects.
-% For this purpose, each userdict has an entry called localdicts
-% which holds the local copies of the elements of savedlocaldicts,
-% plus internaldict. The context switching code in the interpreter
-% effectively copies this dictionary into systemdict.
-% NOTE: the name localdicts is known to the interpreter.
-
-% Switching between contexts also requires resetting the user parameters.
-% The interpreter records the value of userparams (a local dictionary
-% referenced from systemdict) for each context, and uses it for this.
-% See gs_lev2.ps for more details.
-% NOTE: the name userparams is known to the interpreter.
-
-% Save copies of local dictionaries at the end of system initialization.
-% Also save the initial gstate.
-/.savelocalstate {
- .currentglobal true .setglobal
- //systemdict /savedlocaldicts mark //systemdict {
- dup gcheck {
- pop pop
- } {
- dup type /dicttype eq {
- % Save a copy of this dictionary in global VM.
- dup maxlength dict .copydict readonly
- } {
- pop pop
- } ifelse
- } ifelse
- } forall .dicttomark readonly put
- % Create localdicts for the current context.
- false .setglobal
- userdict /localdicts mark savedlocaldicts {
- pop dup load
- } forall /internaldict dup load
- .dicttomark readonly put
- % Save a copy of the initial gstate.
- true .setglobal
- //systemdict /savedinitialgstate gstate readonly put
- .setglobal
-} .bind def
-
-% Initialize local dictionaries and gstate when creating a new context.
-% Note that until this completes, we are in the anomalous situation of
-% having systemdict point to dictionaries that are in a non-current
-% local VM. Because of this, we turn off garbage collection temporarily.
-/.copylocal { % <name> <dict> .copylocal <name> <dict'>
- % Copy a dictionary to the current (local) VM,
- % and make it read-only if its current definition is.
- dup maxlength dict .copydict
- 1 index load wcheck not { readonly } if
-} .bind def
-% When this is called, the dictionary stack is in its initial state,
-% and there is (anomalously) only one gstate on the gstate stack.
-/.initlocaldicts { % - .initlocaldicts -
- -2 vmreclaim
- .currentglobal //systemdict begin
- false .setglobal
- % Since localdicts doesn't exist yet, references from
- % systemdict to local objects won't get restored if
- % a context switch happens in this code. Therefore,
- % until localdicts is defined, we have to keep all our
- % state on the operand stack.
-
- % Acquire userdict.
- %****** WRONG IF NON-STANDARD INITIAL DSTACK ******
- countdictstack array dictstack
- { dup gcheck not { exit } if pop } forall
- % Create localdicts with a local copy of each dictionary,
- % except for userdict and userparams, which just need
- % to be filled in.
- mark savedlocaldicts {
- 1 index /userdict eq {
- % Stack: userdict mark ... /userdict inituserdict
- counttomark 1 add index .copydict
- } {
- 1 index /userparams eq {
- % Stack: userdict mark ... /userparams inituserparams
- userparams .copydict
- } {
- .copylocal
- } ifelse
- } ifelse
- } forall /internaldict dup .makeinternaldict .makeoperator
- .dicttomark readonly /localdicts exch put
- % localdicts is now defined in userdict.
- % Copy the definitions into systemdict.
- localdicts { .forcedef } forall
- % Set the user parameters.
- userparams readonly .setuserparams
- % Establish the initial gstate(s).
- /savedinitialgstate .systemvar setgstate gsave
- % Wrap up.
- end .setglobal
-} odef
-
-% Check whether an object is a procedure.
-/.proccheck { % <obj> .proccheck <bool>
- dup xcheck
- exch type dup /arraytype eq exch /packedarraytype eq or and
-} bind def
-
-% Create a context with private local VM.
-% The .localfork operator does all the work, but we must ensure that
-% .initlocaldicts gets called when the new context starts up.
-/localfork { % <mark> <obj1> ... <objN> <proc>
- % <stdin|null> <stdout|null>
- % localfork <context>
- .currentglobal true .setglobal 3 index
- dup .proccheck not {
- pop .setglobal /localfork .systemvar /typecheck signalerror
- } if
- {exec .initlocaldicts} aload pop
- 3 1 roll 3 packedarray cvx
- 4 1 roll 5 -1 roll pop .setglobal .localfork
-} odef
-
-% Fork a context that shares VM. The .fork operator creates an empty
-% userparams dictionary for the context, but we still need to initialize
-% this dictionary when the new context starts up.
-/.postfork { % - .postfork -
- % Initialize the user parameters.
- savedlocaldicts /userparams get userparams .copydict readonly pop
-} odef
-/fork { % <mark> <obj1> ... <objN> <proc> fork <context>
- .currentglobal false .setglobal 1 index
- dup .proccheck not {
- pop .setglobal /fork .systemvar /typecheck signalerror
- } if
- {exec .postfork} aload pop
- 3 1 roll 3 packedarray cvx
- 3 1 roll exch pop .setglobal .fork
-} odef
-
-% ------ Halftone phase ------ %
-
-/sethalftonephase { % <x> <y> sethalftonephase -
- -1 2 index 2 index .setscreenphase pop pop
-} odef
-/currenthalftonephase { % - currenthalftonephase <x> <y>
- 0 .currentscreenphase
-} odef
-
-% ------ Device-source images ------ */
-
-.imagetypes 2 /.image2 load put
-
-% ------ Device information ------ %
-
-/.deviceinfodict mark
- /Colors null /GrayValues null /RedValues null /GreenValues null
- /BlueValues null /ColorValues null
-.dicttomark readonly def
-/deviceinfo { % - deviceinfo <dict>
- currentdevice //.deviceinfodict .getdeviceparams .dicttomark
- dup begin
- /ColorValues .knownget {
- 0 le
- { currentdict /ColorValues undef }
- {
- % hack around devices that incorrect set GrayValues
- Colors 3 eq { 1 } { GrayValues } ifelse
- RedValues mul GreenValues mul BlueValues mul ColorValues ne
- { currentdict /GrayValues undef
- currentdict /RedValues undef
- currentdict /GreenValues undef
- currentdict /BlueValues undef
- } if
- }
- ifelse
- } if
- currentdict end readonly
-} odef
-
-% The current implementation allocates a 2-element array each time.
-% Perhaps we should change this to 2 separate parameters for X and Y?
-/.wtdict mark
- /wtranslation null
-.dicttomark readonly def
-/wtranslation { % - wtranslation <x> <y>
- currentdevice //.wtdict .getdeviceparams exch pop exch pop aload pop
-} odef
-currentdict /.wtdict .undef
-
-% ------ View clipping ------ %
-
-/rectviewclip { % <x> <y> <width> <height> rectviewclip -
- % <numarray|numstring> rectviewclip -
- newpath .rectappend viewclip
-} odef
diff --git a/Master/tlpkg/tlgs/lib/gs_dps1.ps b/Master/tlpkg/tlgs/lib/gs_dps1.ps deleted file mode 100644 index 6a0e3a30fbc..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_dps1.ps +++ /dev/null @@ -1,139 +0,0 @@ -% Copyright (C) 1997, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_dps1.ps 7648 2007-01-27 13:53:57Z alexcher $
-% Initialization file for most of the Display PostScript functions
-% that are also included in Level 2.
-
-level2dict begin
-
-% ------ Virtual memory ------ %
-
-/currentshared /.currentglobal load def
-/scheck /.gcheck load def
-%****** FOLLOWING IS WRONG ******
-/shareddict currentdict /globaldict .knownget not { 20 dict } if def
-
-% Global and LocalFontDirectory must remain in systemdict
-% even if we temporarily exit Level 2 mode.
-
-end % level2dict
-systemdict begin
-
-/SharedFontDirectory .FontDirectory .gcheck
- { .currentglobal false .setglobal
- /LocalFontDirectory .FontDirectory dup maxlength dict copy
- .forcedef % LocalFontDirectory is local, systemdict is global
- .setglobal .FontDirectory
- }
- { /LocalFontDirectory .FontDirectory
- .forcedef % LocalFontDirectory is local, systemdict is global
- 50 dict
- }
-ifelse def
-
-end % systemdict
-level2dict begin
-
-% setshared must rebind FontDirectory to the appropriate one of
-% Local or SharedFontDirectory.
-
-/.setglobal % <bool> .setglobal -
- { dup .setglobal
- //systemdict /FontDirectory .currentglobal
- { //SharedFontDirectory }
- { /LocalFontDirectory .systemvar } % can't embed ref to local VM
- ifelse .forceput pop % LocalFontDirectory is local, systemdict is global
- } .bind odef % must bind .forceput and .setglobal
- % even if NOBIND in effect
-% Don't just copy (load) the definition of .setglobal:
-% it gets redefined for LL3.
-/setshared { /.setglobal .systemvar exec } odef
-.currentglobal setshared
-
-% See below for changes in save and restore.
-
-% ------ Fonts ------ %
-
-/selectfont % <fontname> <size> selectfont -
- {
- { 1 .argindex findfont
- 1 index dup type /arraytype eq { makefont } { scalefont } ifelse
- setfont pop pop
- } stopped { /selectfont .systemvar $error /errorname get signalerror } if
- } odef
-% undefinefont has to take local/global VM into account.
-/undefinefont % <fontname> undefinefont -
- { .FontDirectory 1 .argindex .forceundef % FontDirectory is readonly
- .currentglobal
- { % Current mode is global; delete from local directory too.
- //systemdict /LocalFontDirectory .knownget
- { 1 index .forceundef } % LocalFontDirectory is readonly
- if
- }
- { % Current mode is local; if there was a shadowed global
- % definition, copy it into the local directory.
- //systemdict /SharedFontDirectory .knownget
- { 1 index .knownget
- { .FontDirectory 2 index 3 -1 roll { put } //superexec } % readonly
- if
- }
- if
- }
- ifelse pop
- } odef
-
-% If we load a font into global VM within an inner save, the restore
-% will delete it from FontDirectory but not from SharedFontDirectory.
-% We have to handle this by making restore copy missing entries from
-% SharedFontDirectory to FontDirectory. Since this could slow down restore
-% considerably, we define a new operator .forcecopynew for this purpose.
-% Furthermore, if FAKEFONTS is in effect, we want global real fonts to
-% override fake local ones. We handle this by brute force.
-/restore % <save> restore -
- { dup //restore % bind even if NOBIND
- /LocalFontDirectory .systemvar
- FAKEFONTS
- { mark
- % We want to delete a fake font from the local directory
- % iff the global directory now has no definition for it,
- % or a non-fake definition.
- 1 index dup
- { % Stack: lfd mark lfd key ... lfd key value
- length 1 gt
- { % This is a real local definition; don't do anything.
- pop
- }
- { % This is a fake local definition, check for global.
- //SharedFontDirectory 1 index .knownget
- { % A global definition exists, check for fake.
- length 1 eq { pop } { 1 index } ifelse
- }
- { % No global definition, delete the local one.
- 1 index
- }
- ifelse
- }
- ifelse
- } forall
- pop counttomark 2 idiv { .forceundef } repeat pop % readonly
- }
- if
- //SharedFontDirectory exch .forcecopynew pop
- .currentglobal .setglobal % Rebind FontDirectory according to current VM.
- pop
- } .bind odef
-
-end % level2dict
diff --git a/Master/tlpkg/tlgs/lib/gs_dps2.ps b/Master/tlpkg/tlgs/lib/gs_dps2.ps deleted file mode 100644 index 45a016b0850..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_dps2.ps +++ /dev/null @@ -1,247 +0,0 @@ -% Copyright (C) 1990, 1996, 1997, 1998, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_dps2.ps 8111 2007-07-06 16:42:18Z alexcher $
-% Initialization file for basic Display PostScript functions
-% that are also included in Level 2.
-
-level2dict begin
-
-% ------ Errors ------ %
-
-% These errors are only defined in Level 2 and DPS.
-{ /configurationerror /undefinedresource /unregistered }
-{ .registererror } forall
-
-% ------ Halftones ------ %
-
-/.makestackdict
- { { counttomark -1 roll } forall .dicttomark
- } bind def
-/currenthalftone % - currenthalftone <dict>
- { mark .currenthalftone
- { { exch pop } % halftone
- { /HalftoneType 1 % screen
- { /Frequency /Angle /SpotFunction }
- .makestackdict readonly
- }
- { /HalftoneType 2 % colorscreen
- { /RedFrequency /RedAngle /RedSpotFunction
- /GreenFrequency /GreenAngle /GreenSpotFunction
- /BlueFrequency /BlueAngle /BlueSpotFunction
- /GrayFrequency /GrayAngle /GraySpotFunction
- }
- .makestackdict readonly
- }
- }
- exch get exec
- } odef
-% Define sethalftone so it converts types 1-4 to type 5.
-/.makehalftoneRGBV { % <dict> <type> <keys> <keysRGBV>
- 4 -1 roll exch { 1 index exch get exch } forall 15 1 roll
- 14 -2 roll mark 15 1 roll { /Gray /Blue /Green /Red } {
- % stack: v0 v1 v2 type keys comp
- mark
- 2 index 0 get 8 -1 roll
- 4 index 1 get 9 -1 roll
- 6 index 2 get 10 -1 roll
- % stack: type keys comp mark k0 v0 k1 v1 k2 v2
- /HalftoneType 10 index .dicttomark
- counttomark 2 roll
- } forall pop pop
- /Default 1 index .dicttomark exch pop { .sethalftone5 }
-} bind def
-
-% The value of each entry in .halftonetypes is a procedure:
-% <setdict> <htdict> <<proc>> <setdict'> <htdict'> <sethalftoneproc>
-% This allows us to use these procedures both for actually implementing
-% sethalftone and for converting subsidiary dictionaries of HalftoneType 5
-% halftones.
-systemdict begin
-15 dict /.halftonetypes 1 index def begin
- 1 {
- mark exch /Default exch .dicttomark { .sethalftone5 }
- } bind def
- 2 {
- 1 { /Frequency /Angle /SpotFunction } {
- /RedFrequency /RedAngle /RedSpotFunction
- /GreenFrequency /GreenAngle /GreenSpotFunction
- /BlueFrequency /BlueAngle /BlueSpotFunction
- /GrayFrequency /GrayAngle /GraySpotFunction
- } .makehalftoneRGBV
- } bind def
- 3 {
- mark exch /Default exch .dicttomark { .sethalftone5 }
- } bind def
- 4 {
- 3 { /Width /Height /Thresholds } {
- /RedWidth /RedHeight /RedThresholds
- /GreenWidth /GreenHeight /GreenThresholds
- /BlueWidth /BlueHeight /BlueThresholds
- /GrayWidth /GrayHeight /GrayThresholds
- } .makehalftoneRGBV
- } bind def
- 5 {
- pop dup length dict copy
- mark 1 index {
- % Even HalftoneType 5 dictionaries have entries other than
- % subsidiary halftone dictionaries.
- dup type /dicttype ne {
- 0
- } {
- dup /HalftoneType .knownget not { 0 } if
- } ifelse dup 5 gt {
- % Stack: dict mark ... keyN dictN httypeN
- % Assume that all HalftoneTypes > 5 convert to 5.
- 1 index 3 1 roll
- //.halftonetypes exch get exec pop /Default get
- % Stack: dict mark ... keyN setdict'N htdict'N
- counttomark 1 add index 3 index 4 -1 roll put
- } {
- pop
- } ifelse
- } forall .dicttomark { .sethalftone5 }
- } bind def
-end
-end
-/sethalftone { % <dict> sethalftone -
- % We must create the new dictionary in the same VM as the
- % operand; otherwise, invalidaccess errors may occur.
- .currentglobal 1 .argindex dup gcheck .setglobal
- dup //.halftonetypes 1 index /HalftoneType get
- dup type /integertype ne {
- /sethalftone .systemvar /typecheck signalerror
- } if
- .knownget not {
- /sethalftone .systemvar /rangecheck signalerror
- } if
- exec exec
- .setglobal pop
-} .bind odef
-% Redefine setscreen and setcolorscreen to recognize halftone dictionaries,
-% and to insert the Frequency and Angle into Type 1 halftones, per
-% Adobe TN 5085.
-/.fixsethalftonescreen % <freq> <angle> <dict> .fix...screen
- % <freq> <angle> <dict> <dict'>
- { dup dup /HalftoneType get 1 eq
- { dup wcheck not { dup length .copydict } if
- dup /Frequency 5 index put
- dup /Angle 4 index put
- languagelevel 3 ge { dup /AccurateScreens dup getuserparam put } if
- }
- if
- } bind def
-/setscreen % <ignore*2> <dict> setscreen -
- { dup type /dicttype eq
- { .fixsethalftonescreen sethalftone pop pop pop }
- { //setscreen }
- ifelse
- } .bind odef
-/setcolorscreen % <ignore*11> <dict> setcolorscreen -
- { dup type /dicttype eq
- { .fixsethalftonescreen sethalftone 12 { pop } repeat }
- { //setcolorscreen }
- ifelse
- } .bind odef
-% Redefine currentscreen and currentcolorscreen to extract the Frequency
-% and Angle from Type 1 halftones, per Adobe TN 5085.
-/.fixcurrenthalftonescreen % <dict> .fix... <freq> <angle> <proc>
- { dup /HalftoneType get 1 eq
- { dup /Frequency get 1 index /Angle get }
- { 60.0 0.0 } % Adobe returns these as reals
- ifelse 3 2 roll
- } bind def
-/currentscreen % - currentscreen 60 0 <dict>
- { .currenthalftone
- { { .fixcurrenthalftonescreen } % halftone
- { } % screen
- { 12 3 roll 9 { pop } repeat % colorscreen
- dup type /dicttype eq { .fixcurrenthalftonescreen } if
- }
- }
- exch get exec
- } odef
-/currentcolorscreen % - currentcolorscreen (60 0 <dict>)*4
-{ .currenthalftone
- { { .fixcurrenthalftonescreen 3 copy 6 copy } % halftone
- { % screen
- % The procedure might not be readable....
- dup rcheck { dup length array copy cvx } if
- 3 copy 6 copy
- }
- { } % colorscreen
- }
- exch get exec
-} odef
-
-% ------ User objects ------ %
-
-/.UserObjects {
- .userdict /UserObjects
-} odef
-% In order to get proper error recovery behavior, we need to be careful
-% not to pop any operands from the stack until we're done.
-% The code below faithfully duplicates the apparent array-growing
-% behavior of Adobe interpreters.
-/defineuserobject { % <index> <value> defineuserobject -
- 1 index 65535 gt {
- % .localvmarray throws limitcheck but CET 31-02 wants rangecheck
- /defineuserobject .systemvar /rangecheck signalerror
- } if
- .UserObjects .knownget {
- length dup 3 .argindex le {
- % Stack: index value len
- 2 index eq { 1 index 2 mul } { 1 index 1 add } ifelse
- .localvmarray .UserObjects get
- 1 index copy pop
- .UserObjects 3 -1 roll put
- } {
- pop
- } ifelse
- } {
- .UserObjects 3 .argindex 1 add 10 .max .localvmarray put
- } ifelse
- .UserObjects get 2 .argindex 2 index put pop pop
-} odef
-/execuserobject { % <index> execuserobject -
- dup type /integertype ne {
- % Adobe validates the argument before accessing UserObjects - CET 31-03
- /execuserobject .systemvar /typecheck signalerror
- } if
- .UserObjects get 1 .argindex get exch pop exec
-} odef
-/undefineuserobject { % <index> undefineuserobject -
- dup type /integertype ne {
- % Adobe validates the argument before accessing UserObjects - CET 31-11
- /undefineuserobject .systemvar /typecheck signalerror
- } if
- .UserObjects get 1 .argindex //null put pop
-} odef
-
-% ------ Cache control ------ %
-
-% Dummy definitions for cache control operators
-
-/ucachestatus { % - ucachestatus -mark- ? ? ? ? <size>
- mark 0 0 0 0 /MaxUPathItem getuserparam
-} odef
-/setucacheparams { % -mark- ... <size> setucacheparams -
- % Provoke an appropriate error if needed.
- counttomark 1 lt { () 0 get } if
- dup 0 or /MaxUPathItem getuserparam .max
- 1 dict dup /MaxUPathItem 4 -1 roll put setuserparams cleartomark
-} odef
-
-end % level2dict
diff --git a/Master/tlpkg/tlgs/lib/gs_dscp.ps b/Master/tlpkg/tlgs/lib/gs_dscp.ps deleted file mode 100644 index 10a39aa3be4..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_dscp.ps +++ /dev/null @@ -1,118 +0,0 @@ -% Copyright (C) 2000 Artifex Software Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_dscp.ps 6300 2005-12-28 19:56:24Z giles $
-% Postscript interface routines to DSC parser
-
-/send_orientation { % <orientation> send_orientation -
- % .parse_dsc_comments returns -1 for an Orientation key with an
- % unrecognized value.
- dup 0 ge {
- << /Orientation 2 index >> setpagedevice
- } if pop
-} bind def
-
-% This dictionary contains local handlers for DSC comments.
-% See header in zdscpars.c for more information.
-% <dsc_dict> handler <dsc_dict>
-/DSCparseprocs mark
- /Orientation { dup /Orientation get send_orientation } bind
- /PageOrientation { dup /PageOrientation .knownget { send_orientation }
- { dup /Orientation .knownget { send_orientation } if }
- ifelse } bind
- /Page { dup /Orientation .knownget { send_orientation } if } bind
- /NOP { } bind
-.dicttomark readonly def
-
-% This procedure is called whenever a DSC comment is found by the interpreter
-/do_parse_dsc false def
-/parse_dsc { % <file> <DSC string> [<prev proc>]
- % parse_dsc -
- % Run any previously installed parser.
- 0 get dup null eq { pop } { 3 copy exec pop } ifelse
-
- do_parse_dsc { % Check if this parser is enabled
- currentglobal true setglobal % Go to global VM, save old state
- 3 1 roll % Put old VM state under <file> <string>
- dsc_dict exch % <VM state> <file> <dict> <string>
- .parse_dsc_comments % <VM state> <file> <dict> <DSC name>
- 4 -1 roll % Get old VM state from under <file> <dict> <DSC name>
- setglobal % restore previous VM state
- //DSCparseprocs exch .knownget { % Check DSC name against local handler list
- exec % execute any local handler
- } if
- } if
- pop pop % remove file, dict
-} bind def
-
-
-% Check whether the currently installed parser is the one defined in this file.
-/.using_parse_dsc { % - .using_parse_dsc <proc> <using?>
- currentuserparams /ProcessDSCComment get
- dup null eq { pop {{//null} //parse_dsc exec} } if
- dup length 3 eq {
- dup dup length 1 sub get /parse_dsc load eq
- } {
- false
- } ifelse
-} bind def
-
-% Establish a binding for dsc_dict.
-userdict /dsc_dict null put
-
-% - dsc_init -
-/dsc_init { % Initialize DSC parser
- currentglobal true setglobal
- /dsc_dict 50 dict store % Size must be large enough for all DSC values
- dsc_dict .initialize_dsc_parser
- .using_parse_dsc {
- % Already using this parser.
- pop
- } {
- % Encapsulate the previous parser. We know it is in global VM:
- % allocate the new one in global VM as well.
- 1 array astore
- /parse_dsc load /exec load 3 array astore cvx readonly
- << /ProcessDSCComment 3 -1 roll >>
- setuserparams
- } ifelse
- setglobal
- /do_parse_dsc true def
-} bind def
-
-
-% Enable the DSC parser defined in this file.
-% - enable_dsc -
-/enable_dsc {
- dsc_init
-} bind def
-
-% Disable the DSC parser defined in this file.
-% - disable_dsc -
-/disable_dsc {
- % There might be another parser installed: if so, restore it.
- % (If it has encapsulated our parser, we can't.)
- .using_parse_dsc {
- % Restore the parser we encapsulated.
- 0 get 0 get
- currentglobal true setglobal exch
- << /ProcessDSCComment 3 -1 roll >>
- exch setglobal setuserparams
- } {
- pop
- } ifelse
- % If we couldn't restore the old parser, at least disable ours.
- /do_parse_dsc false def
-} bind def
diff --git a/Master/tlpkg/tlgs/lib/gs_epsf.ps b/Master/tlpkg/tlgs/lib/gs_epsf.ps deleted file mode 100644 index b12f2f0e83f..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_epsf.ps +++ /dev/null @@ -1,243 +0,0 @@ -% Copyright (C) 1989, 1996, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_epsf.ps 6300 2005-12-28 19:56:24Z giles $
-% Allow the interpreter to encapsulate EPS files, to recognize MS-DOS
-% EPSF file headers, and skip to the PostScript section of the file.
-
-% Encapsulate EPS files and optionally resize page or rescale image.
-% To display an EPS file cropped to the bounding box:
-% gs -dEPSCrop file.eps
-% To display an EPS file scaled to fit the page:
-% gs -dEPSFitPage file.eps
-% To display a file without EPS encapsulation:
-% gs -dNOEPS file.ps
-
-% When starting to process an EPS file, state is 0.
-% After %%BoundingBox processed, state is 1 if OK or 2 if cropped.
-% After %%HiResBoundingBox processed, state is 3 if OK or 4 if cropped.
-% After %%EndComments processed, state is 5.
-/EPSBoundingBoxState 5 def
-/EPSBoundingBoxSetState {
- //systemdict /EPSBoundingBoxState 3 -1 roll .forceput
-} .bind odef % .forceput must be bound and hidden
-
-% Parse 4 numbers for a bounding box
-/EPSBoundingBoxParse { % (llx lly urx ury) -- llx lly urx ury true OR false
- mark exch
- token {exch token {exch token {exch token {exch pop} if} if} if} if
- counttomark
- 4 eq {
- 5 -1 roll pop % remove mark
- true
- } {
- cleartomark false
- } ifelse
-} bind def
-
-% Rescale and translate to fit the BoundingBox on the page
-/EPSBoundingBoxFitPage { % llx lly urx ury --
- EPSDEBUG { (gs_epsf.ps: Rescaling EPS to fit page\n) print flush } if
- clippath pathbbox newpath
- % translate to new origin at lower left of clippath
- 3 index 3 index translate
- % calculate scale to fit smaller of width or height
- exch 4 -1 roll sub 3 1 roll exch sub
- 4 2 roll 5 index 5 index 4 2 roll
- exch 4 -1 roll sub 3 1 roll exch sub
- 4 2 roll
- exch 4 -1 roll div 3 1 roll exch div
- 1 index 1 index lt {pop}{exch pop} ifelse
- dup scale
- % translate to EPS -llx,-lly
- exch neg exch neg translate
-} bind def
-
-% Crop the page to the BoundingBox
-/EPSBoundingBoxCrop { % llx lly urx ury --
- EPSDEBUG {
- (gs_epsf.ps: Setting pagesize from EPS bounding box\n) print flush
- } if
- exch 3 index sub exch 2 index sub % stack: llx lly urx-llx ury-lly
- << /PageSize [ 5 -2 roll ] >> setpagedevice
- neg exch neg exch translate
-} bind def
-
-
-/EPSBoundingBoxProcess { % (llx lly urx ury) state --
- //systemdict /EPSBoundingBoxState get 1 index lt {
- exch EPSBoundingBoxParse
- {
- //systemdict /EPSCrop known {
- EPSBoundingBoxCrop
- } {
- //systemdict /EPSFitPage known {
- EPSBoundingBoxFitPage
- } {
- % Warn if some of the EPS file will be clipped
- clippath pathbbox newpath
- { % context for exit
- 5 -1 roll lt { 6 { pop } repeat true exit } if
- 4 -1 roll lt { 4 { pop } repeat true exit } if
- 3 -1 roll gt { 2 { pop } repeat true exit } if
- exch gt { true exit } if
- false exit
- } loop
- QUIET not and /EPSBoundingBoxState .systemvar 1 and 1 eq and {
- (\n **** Warning: Some of the BoundingBox for the EPS file will be clipped.) =
- ( Use -dEPSCrop or -dEPSFitPage to avoid clipping.\n) =
- flush
- 1 add
- } if
- } ifelse
- } ifelse
- EPSBoundingBoxSetState
- } {
- pop % state
- } ifelse
- } {
- pop pop
- } ifelse
-} bind def
-
-/ProcessEPSComment { % file comment -- file comment
- //systemdict /EPSBoundingBoxState get 3 lt {
- dup
- (%%EndComments) anchorsearch {
- pop pop
- % ignore any following bounding boxes
- 5 EPSBoundingBoxSetState
- } {
- (%%BoundingBox:) anchorsearch {
- pop
- EPSDEBUG { (gs_epsf.ps: found %%BoundingBox\n) print flush } if
- 1 EPSBoundingBoxProcess
- } {
- (%%HiResBoundingBox:) anchorsearch {
- pop
- EPSDEBUG { (gs_epsf.ps: found %%HiResBoundingBox\n) print flush } if
- 3 EPSBoundingBoxProcess
- } {
- pop % Not interested in this DSC comment
- } ifelse
- } ifelse
- } ifelse
- } if
-} bind def
-
-% Install EPS handler for DSC comments, which we do later
-/EPSBoundingBoxInit {
- systemdict /NOEPS known not {
- % Merge ProcessEPSComment with existing handler
- /ProcessEPSComment load /exec load
- currentuserparams /ProcessDSCComment get
- dup null eq {pop {pop pop}} if /exec load
- 4 array astore cvx readonly
- << /ProcessDSCComment 3 -1 roll >> setuserparams
- } if
-} bind def
-
-/.runNoEPS /run load def
-
-/.runEPS { % file OR string --
- /runEPS_save save def
- /runEPS_dict_count countdictstack def
- /runEPS_op_count count 2 sub def
- /runEPS_page_count currentpagedevice /PageCount get def
- 0 EPSBoundingBoxSetState
- .runNoEPS
- currentpagedevice /PageCount get runEPS_page_count sub 0 eq
- { /showpage load exec } if
- count runEPS_op_count sub {pop} repeat
- countdictstack runEPS_dict_count sub {end} repeat
- runEPS_save restore
-} bind def
-
-/run { % file OR string --
- dup type /filetype ne { (r) file } if
- dup (%!PS-Adobe-) .peekstring {
- (%!PS-Adobe-) eq {
- dup (%!PS-Adobe-X.X EPSF-X.X) .peekstring {
- (EPSF) search {
- pop pop pop
- EPSDEBUG {(runEPS: Found EPS\n) print flush} if
- systemdict /NOEPS known {
- cvx .runNoEPS
- } {
- cvx .runEPS
- } ifelse
- } {
- EPSDEBUG {(runEPS: Normal DSC\n) print flush} if
- pop
- cvx .runNoEPS
-
- } ifelse
- } {
- EPSDEBUG {(runEPS: Short DSC\n) print flush} if
- pop
- cvx .runNoEPS
- } ifelse
- } {
- EPSDEBUG {(runEPS: Not DSC\n) print flush} if
- cvx .runNoEPS
- } ifelse
- } {
- EPSDEBUG {(runEPS: Short non-DSC\n) print flush} if
- pop
- cvx .runNoEPS
- } ifelse
-} bind odef
-
-
-% Handle DOS EPS files.
-
-/.runnoepsf /run load def
-/.epsfheader <C5D0D3C6> def
-/run
- { dup type /filetype ne { (r) file } if
- % Check for MS-DOS EPSF file (see Red Book p. 729).
- dup ( ) .peekstring
- { .epsfheader eq { dup ( ) readstring exch pop } { false } ifelse }
- { pop false }
- ifelse
- % Stack: file true/false
- { % This block is executed if the file is MS-DOS EPSF.
- % Build up the little-endian byte offset and length.
- 2
- { 1 0 4
- { 2 index read not { pop exit } if % if EOF, let error happen
- 2 index mul add exch 256 mul exch
- }
- repeat exch pop exch
- }
- repeat
- % Stack: offset length file
- % Use flushfile to skip quickly to the start of the
- % PostScript section.
- dup 4 -1 roll 12 sub () /SubFileDecode filter flushfile
- % Now interpret the PostScript.
- exch () /SubFileDecode filter cvx run
- }
- { .runnoepsf
- }
- ifelse
- } odef
-
-% rebind .runstdin to use redefined run
-userdict begin
-/.runstdin {
- { (%stdin) run } execute0
-} bind def
-end
diff --git a/Master/tlpkg/tlgs/lib/gs_fapi.ps b/Master/tlpkg/tlgs/lib/gs_fapi.ps deleted file mode 100644 index 8a4566b2506..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_fapi.ps +++ /dev/null @@ -1,344 +0,0 @@ -% Copyright (C) 2000 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_fapi.ps 8022 2007-06-05 22:23:38Z giles $
-% Redefine Font and CIDFont categories with FAPI-handeled fonts.
-
-systemdict /.FAPIavailable known { .FAPIavailable } { false } ifelse not {
- (%END FAPI) .skipeof
-} if
-
-languagelevel 2 .setlanguagelevel
-
-%====================================================================
-% Redefine Font category with FAPIfontmap and CIDFont with FAPIfontmap :
-15 dict begin % a temporary dictionary for local binding.
-
-/EmbedFontObjectsQuery mark
- /.EmbedFontObjects 0
-.dicttomark def
-
-/is_device_compatible_to_FAPI % - is_device_compatible_to_FAPI <bool>
-{ currentdevice //EmbedFontObjectsQuery .getdeviceparams % <mark> <name> <value> ...
- dup mark eq {
- pop true
- } {
- exch pop exch pop 0 eq
- } ifelse
- % The code above assumes that only the requested parameter is rendered.
- % The commented-out code below may be useful for general case.
- % Keeping it for a while.
- % counttomark 2 idiv {
- % exch /.EmbedFontObjects eq {
- % counttomark 1 add 1 roll cleartomark
- % 0 eq exit
- % } if
- % } repeat
- % dup mark eq {
- % pop true
- % } if
-} bind def
-
-%----------------------------- Process FAPIconfig -----------------------
-
-/Config
-<<
- systemdict /FAPIconfig known {/FAPIconfig .systemvar} {(FAPIconfig)} ifelse .runlibfile
- /ServerOptions 2 dict
->> def
-systemdict /.FAPIconfig //Config put
-
-()
-systemdict /UFST_SSdir .knownget {
- (UFST_SSdir=) exch concatstrings concatstrings
-} if
-systemdict /UFST_PlugIn .knownget {
- 1 index length 0 ne {
- exch .filenamelistseparator concatstrings exch
- } if
- (UFST_PlugIn=) exch concatstrings concatstrings
-} if
-dup length 0 ne {
- //Config /ServerOptions get exch /UFST exch put
-} {
- pop
-} ifelse
-
-%------------------Copy the FontEmulationProcs here : -------------------
-
-/FontEmulationProcs /ProcSet findresource {
- def
-} forall
-
-currentdict /super.complete_instance currentdict /complete_instance get put
-
-%-----------FAPI-specific methods for category redefinition : -----------
-
-/RefinePath % <FontDict> /key RefinePath <FontDict>
-{ exch begin
- //Config exch get
- /Path exch
- Path false .file_name_combine not {
- exch
- (Can't combine paths ) print print ( and ) print =
- /RefinePath cvx /configurationerror signalerror
- } if
- def
- currentdict end
-} bind def
-
-/complete_instance % <font_name> <FontDict> <Options> complete_FAPI_Font <font_name> <FontDict>
-{ //super.complete_instance exec
- dup /CIDFontName known { /CIDFontPath } { /FontPath } ifelse //RefinePath exec
-} bind def
-
-/IsMyRecord % <raw_record> -> <raw_record> bool
-{ dup type /dicttype eq { dup /FAPI known } { false } ifelse
-} bind def
-
-/IsActive % <record> IsActive <bool>
-{ pop //is_device_compatible_to_FAPI exec
-} bind def
-
-/FontRecordVirtualMethods //RecordVirtualMethodsStub dup length 2 add dict copy begin
- /IsActive //IsActive def
- /MakeInstance % <Name> <record> MakeInstance <Name> <Instance> <size>
- { currentglobal 3 1 roll true setglobal
- //FontOptions //complete_instance exec
- 2 copy //GetSize exec
- 4 3 roll setglobal
- } bind def
-currentdict end def
-
-/CIDFontRecordVirtualMethods //RecordVirtualMethodsStub dup length 3 add dict copy begin
- /GetCSI //TranslateCSI def
- /IsActive //IsActive def
- /MakeInstance % <Name> <record> MakeInstance <Name> <Instance> <size>
- { currentglobal 3 1 roll true setglobal
- //CIDFontOptions //complete_instance exec
- 2 copy //GetSize exec
- 4 3 roll setglobal
- } bind def
-currentdict end def
-
-/ReadFCOfontmap: % <path> ReadFCOfontmap: name dict ...
-{ /fontfile exch def
- {
- currentfile =string readline not {
- pop exit
- } if
- dup length 0 ne {
- 0 () /SubFileDecode filter
- dup token not {
- % A comment line
- closefile
- } {
- dup /EndFCOfontmap cvx eq {
- pop closefile exit
- } if
- exch dup token not {
- /ReadFCOfontmap: cvx /rangecheck signalerror
- } if
- exch dup token not {
- /StandardEncoding
- } {
- dup type /nametype ne {
- /ReadFCOfontmap: cvx /rangecheck signalerror
- } if
- } ifelse
- findencoding
- exch dup token not {
- null
- } {
- dup type /nametype ne {
- /ReadFCOfontmap: cvx /rangecheck signalerror
- } if
- /Decoding findresource
- } ifelse
- exch closefile % index name enc dec|null
- 4 3 roll % name enc dec|null index
- << /Path fontfile
- /FontType 1
- /FAPI /UFST
- /SubfontId counttomark 2 add -1 roll
- /Decoding counttomark 2 add -1 roll
- dup null eq {
- pop pop
- } if
- /Encoding counttomark 2 add -1 roll
- >> % dup { exch == = } forall
- } ifelse
- } {
- pop
- } ifelse
- } loop
- currentdict /fontfile undef
-} bind def
-
-
-%----------------------------------The Redefintion---------------------
-
-/MappedCategoryRedefiner /ProcSet findresource /Redefine get /Redefine exch def
-
-% Redefine the /Font category :
-4 dict begin
- /CategoryName /Font def
- /MapFileName systemdict /FAPIfontmap known {/FAPIfontmap .systemvar} {(FAPIfontmap)} ifelse def
- /VerifyMap { pop } bind def
- /PreprocessRecord % <map> <Name> <raw_record> PreprocessRecord <map> <Name> <record> <bool>
- { //IsMyRecord exec dup {
- pop dup /RecordVirtualMethods //FontRecordVirtualMethods put
- true
- } if
- } bind def
-currentdict end Redefine
-
-% Redefine the /CIDFont category :
-4 dict begin
- /CategoryName /CIDFont def
- /MapFileName systemdict /FAPIcidfmap known {/FAPIcidfmap .systemvar} {(FAPIcidfmap)} ifelse def
- /VerifyMap { pop } bind def
- /PreprocessRecord % <map> <Name> <raw_record> PreprocessRecord <map> <Name> <record> <bool>
- { //IsMyRecord exec dup {
- pop dup /RecordVirtualMethods //CIDFontRecordVirtualMethods put
- true
- } if
- } bind def
-currentdict end Redefine
-
-%==================== A hook for buildfont* operators ====================
-
-% The procedure .FAPIhook redirects PS fonts to FAPI on necessity.
-% This depends on the following conditions :
-%
-% 1. If font dictionary has /FAPI entry, it is a font listed in FAPIconfig.FontPath,
-% and must be build with .FAPIrebuildfont, or a copy of a font, which was
-% built with .FAPIrebuildfont .
-%
-% 2. If the font dictionary has /PathLoad entry, and has no /FAPI entry,
-% it is an installed PS font, which is described in lib/fontmap or
-% in GS_FONTPATH. .loadfont inserts /PathLoad entry for this case
-% (see gs_fonts.ps).
-%
-% Installed fonts are being loaded with GS font loader,
-% the they are passed to FAPI is same way as embedded fonts are.
-% We do so because UFST cannot read fonts, which don't
-% follow Type 1/42 file format strongly.
-%
-% 3. Executing .loadfont, we place /FAPI_hook_disable in the 0th
-% element of some procedure on the execution stack - see gs_fonts.ps .
-% If FAPI_hook finds /FAPI_hook_disable in there,
-% it knows that it is called for a disk font during
-% its internal definefont.
-%
-% 4. If font dictionary has no /FAPI entry, and has no /Path entry,
-% and if we are not in .loadfont context, it is an embedded font.
-%
-% 5. Two entries to be defined in lib/FAPIconfig to control the hooking of PS fonts :
-% HookDiskFonts and HookEmbeddedFonts .
-% They specify arrays of font types (integers) to be redirected with FAPI.
-% HookDiskFonts controls disk PS fonts (which fall into (2) and (3) ).
-% HookEmbeddedFonts controls fonts being embedded into documents.
-%
-% 7. We apply the operator .passtoFAPI for checking whether FAPI can handle a font.
-% If so, we insert /FAPI entry into the font dictionary and convert it
-% with .FAPIrebuildfont . Otherwise the font is handled with the native GS font renderer.
-
-/FAPI_hook_debug % <proc> FAPI_hook_debug -
-FAPIDEBUG { {exec} } { {pop} } ifelse
-bind def
-
-/FAPI_hook_warn % <proc> FAPI_hook_debug -
-QUIET { {pop} } { {exec} } ifelse
-bind def
-
-/FAPI_is_hook_disabled % - FAPI_is_hook_disabled <bool>
-{ % checks whether execution stack contains packedarray started with /FAPI_hook_disable .
- /FAPI_hook_disable /MappedCategoryRedefiner /ProcSet findresource /execstack_lookup get exec
- null ne
-} bind def
-
-/FAPIhook_aux % <string|name> <font_dict> .FAPIhook <string|name> <font>
-{ % name <<font>>
- { (FAPIhook ) print 1 index = } //FAPI_hook_debug exec
- dup /FAPI known {
- { //PrintFontRef exec ( is mapped to FAPI=) print dup /FAPI get = } //FAPI_hook_warn exec
- true //.FAPIrebuildfont //ChooseDecoding exec
- } {
- dup /PathLoad known dup {
- { (PathLoad known for the font ) print //PrintFontRef exec (.) = } //FAPI_hook_debug exec
- } {
- pop //FAPI_is_hook_disabled exec dup
- { pop
- { (FAPIhook is in .loadfont context for the font ) print //PrintFontRef exec (.) = } //FAPI_hook_debug exec
- true
- } if
- } ifelse
- { /HookDiskFonts } { /HookEmbeddedFonts } ifelse
- //Config exch get % name <<font>> [types]
- 1 index //GetFontType exec //FindInArray exec % name <<font>> bHook
- { { (Trying to render the font ) print //PrintFontRef exec ( with FAPI...) = } //FAPI_hook_debug exec
- //.FAPIpassfont {
- { //PrintFontRef exec ( is being rendered with FAPI=) print dup /FAPI get = } //FAPI_hook_warn exec
- false //.FAPIrebuildfont //ChooseDecoding exec
- } {
- { (Can't render ) print //PrintFontRef exec ( with FAPI, will do with native GS renderer.) = } //FAPI_hook_warn exec
- } ifelse
- } {
- { (The font ) print //PrintFontRef exec ( doesn't need to render with FAPI.) = } //FAPI_hook_debug exec
- } ifelse
- } ifelse
-} bind def
-
-/FAPIhook % <string|name> <font_dict> .FAPIhook <string|name> <font>
-{ //is_device_compatible_to_FAPI exec
- { //FAPIhook_aux exec
- } {
- { (FAPIhook is disabled for the current device.) = } //FAPI_hook_debug exec
- } ifelse
-} bind def
-
-% ------------------ Redefine .buildfont* with FAPI : -----------------------
-
-/.buildfont1
-{ //.buildfont1 exec //FAPIhook exec
-} bind % 'odef' is below.
-
-/.buildfont2
-{ //.buildfont2 exec //FAPIhook exec
-} bind % 'odef' is below.
-
-/.buildfont42
-{ //.buildfont42 exec //FAPIhook exec
-} bind % 'odef' is below.
-
-/.buildfont9
-{ //.buildfont9 exec //FAPIhook exec
-} bind % 'odef' is below.
-
-/.buildfont10
-{ //.buildfont10 exec //FAPIhook exec
-} bind % 'odef' is below.
-
-/.buildfont11
-{ //.buildfont11 exec //FAPIhook exec
-} bind % 'odef' is below.
-
-end % the temporary dictionary for local binding.
-odef odef odef odef odef odef
-
-.setlanguagelevel
-
-%END FAPI
diff --git a/Master/tlpkg/tlgs/lib/gs_fform.ps b/Master/tlpkg/tlgs/lib/gs_fform.ps deleted file mode 100644 index 93f69d627ff..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_fform.ps +++ /dev/null @@ -1,92 +0,0 @@ -% Copyright (C) 1995, 1996, 1998, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_fform.ps 6300 2005-12-28 19:56:24Z giles $
-% Form caching implemented in PostScript.
-
-% This implementation doesn't do the right thing about halftone or
-% Pattern phase, but the Pattern cache doesn't either....
-
-% The Form cache key is the Form dictionary; the value is an array
-% of 2 elements [CTM pattern_instance].
-%
-% In order to prevent restore from clearing the cache, we explicitly
-% push the cache entries on the stack before a restore and reinstall them.
-currentglobal false setglobal
-/.formcachedict 20 dict def % must be local
-true setglobal
-/restore {
- mark .formcachedict { } forall
- counttomark 1 add index { //restore } .internalstopped
- { cleartomark //restore }
- { counttomark 2 idiv { .formcachedict 3 1 roll put } repeat pop pop }
- ifelse
-} bind odef
-
-/.execform1 {
- dup /Implementation known not {
- dup /FormType get 1 ne { /rangecheck signalerror } if
- % The Implementation is a Pattern that will draw the form.
- currentglobal 1 index gcheck setglobal
- % Stack: form global
- 10 dict begin
- /PatternType 1 def
- /PaintType 1 def % colored
- /TilingType 1 def % irrelevant
- % Copy the BBox to the correct VM.
- /BBox 2 index /BBox get 4 array copy exch 1 index def
- % Set XStep and YStep to very large numbers,
- % so we won't get multiple copies of the form.
- /XStep 1 index dup 2 get exch 0 get sub 100 mul def
- /YStep exch dup 3 get exch 1 get sub 100 mul def
- /PaintProc 2 index /PaintProc get def
- currentdict end readonly
- % Stack: form global impl
- exch setglobal
- 1 index /Implementation 3 -1 roll .forceput
- } if
- .formcachedict 1 index .knownget {
- % Check whether we can use the cached value.
- % Stack: form cachevalue
- matrix currentmatrix true 0 1 3 {
- % Stack: form cachevalue curmat true index
- 3 index 0 get 1 index get exch 3 index exch get ne {
- pop pop false exit
- } if
- } for exch pop
- } {
- false
- } ifelse not
- { % Make a new cache entry.
- gsave
- matrix currentmatrix dup 4 0 put dup 5 0 put dup setmatrix
- % Stack: form mat
- 1 index /Implementation get
- 2 index /Matrix get
- makepattern 2 array astore
- .formcachedict 2 index 2 index put
- grestore
- } if
- % Stack: form cachevalue
- -1 0 0 transform
- 2 { exch round cvi } repeat .setscreenphase
- 1 get setpattern
- /BBox get aload pop
- exch 3 index sub exch 2 index sub rectfill
-} .bind odef % must bind .forceput
-
-.formtypes 1 /.execform1 load put
-
-setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_fntem.ps b/Master/tlpkg/tlgs/lib/gs_fntem.ps deleted file mode 100644 index 8472d9c4afa..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_fntem.ps +++ /dev/null @@ -1,432 +0,0 @@ -% Copyright (C) 2000 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_fntem.ps 8274 2007-10-09 00:06:24Z leonardo $
-% A procset for Postscript font emulation
-
-% The procedures must not depend on the presence of the
-% procset dictionary on the dictionary stack.
-
-languagelevel 2 .setlanguagelevel
-
-%========================= Process xlatmap ====================
-mark
-%% Replace 1 (xlatmap)
-(xlatmap) .runlibfile
-.dicttomark dup systemdict exch /.xlatmap_dict exch put
-
-% Convert it into a plain text to simplify the processing in C :
-% *(fontkind\0\0\ *(charmap\0decoding\0) ) \0
-
-() exch {
- 3 1 roll =string cvs concatstrings (\0\0) concatstrings
- exch
- { =string cvs concatstrings (\0) concatstrings
- } forall
-} forall
-(\0) concatstrings
-systemdict exch /.xlatmap exch put
-
-/FontEmulationProcs 10 dict begin
-
-%-------------------------------Font--------------------------------
-
-
-/FontCommon % - font_common -
-{ currentdict /PaintType known not {
- /PaintType 0 def
- } if
- currentdict /Encoding .knownget not {
- //StandardEncoding
- } if
- dup type /nametype eq {
- /Encoding findresource
- } if
- /Encoding exch def
-} bind def
-
-/FontOptions 5 dict begin
- /make_procs currentdict def
- /NameKey /FontName def
- /TypeKey /FontType def
-
- 1
- { /FontMatrix [0.001 0 0 0.001 0 0] def
- /FontBBox [-128 -128 1024 1024] def % zfapi.ps refines it.
- /Private 0 dict def
- /CharStrings << /.notdef () >> def
- //FontCommon exec
- } bind def
-
- 42
- { /FontMatrix [1 0 0 1 0 0] def
- /FontBBox [0 0 1 1] def % zfapi.ps refines it.
- /CharStrings <<>> def
- /sfnts [<00010000 0000 0000 0000 0000 0000>] def
- /GlyphDirectory [] def
- //FontCommon exec
- } bind def
-
- %fixme : more font types.
-
-currentdict end def
-
-%---------------------------CIDFont---------------------------
-
-/TranslateCSI % <record> TranslateCSI <CSI>
-{ RESMPDEBUG { (fntem TranslateCSI beg ) = } if
- begin
- CSI length 2 eq {
- << /Registry (Adobe)
- /Ordering CSI aload pop
- /Supplement exch
- >>
- } {
- << /Registry CSI 0 get
- /Ordering CSI 1 get
- /Supplement CSI 2 get
- >>
- } ifelse
- end
- RESMPDEBUG { (fntem TranslateCSI end ) = } if
-} bind def
-
-/CIDFontCommon
-{ /CIDSystemInfo currentdict //TranslateCSI exec def
- currentdict /CSI undef
- /FontBBox [-128 -128 1024 1024] def % zfapi.ps refines it.
- /CIDCount 1 def % ChooseDecoding will set a reasonable value.
-} bind def
-
-% GFlyph substitution table for narrow, wide, proportional glyphs -
-% used with TrueTypes.
-
-currentpacking false setpacking
-/SubstNWP <<
-
- % Array format : orig_type, beg_CID, end_CID, subst_beg_CID, subst_type
- % type = (n==narrow, w==wide, p==proportional).
-
- /Japan1
- { p 1 94 231 n
-
- p 17 26 780 w
- p 34 59 790 w
- p 66 91 816 w
- w 842 842 7918 w % fixme: These substitutions require to shift the glyph origin.
- w 844 844 7919 w
- w 846 846 7920 w
- w 848 848 7921 w
- w 850 850 7922 w
- w 876 876 7923 w
- w 908 908 7924 w
- w 910 910 7925 w
- w 912 912 7926 w
- w 914 914 7927 w
- w 925 925 7928 w
- w 927 927 7929 w
- w 929 929 7930 w
- w 931 931 7931 w
- w 933 933 7932 w
- w 959 959 7933 w
- w 991 991 7934 w
- w 993 993 7935 w
- w 995 995 7936 w
- w 1002 1002 7937 w
- w 1009 1009 7938 w
- w 1010 1010 7939 w
- } cvlit
-
- /Japan2 1 index
-
- /CNS1
- { p 1 94 13648 n
-
- p 17 26 333 w
- p 34 59 365 w
- p 66 91 391 w
- } cvlit
-
- /GB1
- { p 2 94 814 n
-
- p 2 94 262 w
-
- p 1 1 7716 n
- } cvlit
-
- /Korea1
- { p 1 60 8094 n
- p 62 94 8155 n
-
- p 2 59 264 w
- p 63 94 325 w
- } cvlit
-
- /Identity []
-
- /Unicode []
-
->> def
-setpacking
-
-/CIDFontOptions 5 dict begin
- /make_procs currentdict def
- /NameKey /CIDFontName def
- /TypeKey /CIDFontType def
-
- 0
- { //CIDFontCommon exec
- /FDArray [
- 14 dict begin
- /FontName CIDFontName =string cvs (%) concatstrings cvn def
- /FontType 1 def
- /FontMatrix [0.001 0 0 0.001 0 0 ] def
- /PaintType 0 def
- /Private 0 dict def
- currentdict
- end
- ] def
- /GlyphDirectory [] def
- /GDBytes 1 def
- /FDBytes 0 def
- } bind def
-
- 1
- { //CIDFontCommon exec
- /FontMatrix [1 0 0 1 0 0] def
- /BuildGlyph {} def
- } bind def
-
- 2
- { //CIDFontCommon exec
- /FontMatrix [1 0 0 1 0 0] def
- /GDBytes 2 def
- /CIDMap <0000> def
- /sfnts [<00010000 0000 0000 0000 0000 0000>] def
- /Encoding [] def
- /CharStrings << /.notdef 0 >> def
- } bind def
-
-currentdict end def
-
-/complete_instance % <font_name> <FontDict> <Options> complete_FAPI_Font <font_name> <FontDict>
-{ begin
- dup length dict copy
- begin
- dup type /nametype ne { cvn } if
- dup NameKey exch def
- currentglobal true setglobal
- make_procs TypeKey load .knownget {
- exec
- } { setglobal
- /complete_instance cvx /invalidfont signalerror
- } ifelse
- setglobal
- currentdict end
- end
-} bind def
-
-/GetFilePath % <scratch> <Name> <record> GetFilePath <filepath>
-{ exch pop % (scratch) <record>
- /Path get % (scratch) (path)
- exch copy
- % What we make here it is not a complete PS resource.
- % Unable to provide full conformity :
- % the attempt to run this file may fail.
-} bind def
-
-/GetSize % <Name> <record> GetSize <size>
-{ pop pop -1 % Unknown size.
- % fixme: probably we could provide an estimation size for some fonts.
-} bind def
-
-/RecordVirtualMethodsStub 3 dict begin
- /GetFilePath //GetFilePath def
- /GetSize //GetSize def
-currentdict end def
-
-% ---------------------- Decoding helpers ----------------------------
-
-/encodingnames mark
- StandardEncoding /StandardEncoding
- ISOLatin1Encoding /ISOLatin1Encoding
- SymbolEncoding /SymbolEncoding
- DingbatsEncoding /DingbatsEncoding
- /resourceforall where {
- pop (*) { dup cvn
- EncodingDirectory exch .knownget not {
- % A work around bug 688710 on Linux :
- % findencoding can't load resource files until gs_init.ps executes .fixresources .
- % It will happen after gs_init.ps runs INITFILES,
- % from which the current file runs.
- % Windows build has no such problem.
- (.svn) anchorsearch {
- % HACK : skip .svn or */* names, which are subdirectories.
- pop pop
- } {
- (/) search {
- pop pop pop
- } {
- cvn dup /Encoding findresource
- } ifelse
- } ifelse
- } {
- exch cvn exch
- } ifelse
- exch
- } 1024 string /Encoding resourceforall
- } if
-.dicttomark def
-
-/ChooseDecoding % <font> ChooseDecoding <font>
-{ { % A loop for 'exit' context.
- dup /Decoding .knownget {
- dup type /nametype eq {
- 1 index /CIDFontType known { /CIDDecoding } { /Decoding } ifelse
- findresource 1 index exch /Decoding exch put
- } {
- pop
- } ifelse
- dup /CIDFontType known {
- dup dup /Decoding get /CIDCount get /CIDCount exch put
- } if
- exit
- } if
- dup /CIDFontType known {
- % This is a hooked CID font, no need for Decoding.
- exit
- } if
- % This works when the renderer can't choose character by name,
- % and we cannot determine the charset.
- % Probably this branch is to be removed after UFST problem is fixed.
- dup /Encoding get % <<font>> encoding
- dup type /nametype eq {
- /Decoding findresource 1 index exch /Decoding exch put
- } {
- dup //encodingnames
- exch .knownget {
- exch pop
- /Decoding findresource 1 index exch /Decoding exch put
- } {
- % unknown encoding, convert it to decoding :
- dup length dict begin
- /.notdef 0 def
- 0 1 currentdict length 1 sub
- { dup 2 index exch get
- dup /.notdef ne {
- exch def
- } {
- pop pop
- } ifelse
- } for
- pop
- currentdict end
- 1 index exch /Decoding exch put
- } ifelse
- } ifelse
- exit
- } loop
- dup /CIDFontType known {
- dup /SubstNWP .knownget not {
- dup /CIDSystemInfo get /Ordering get cvn
- } if
- dup type /nametype eq {
- //SubstNWP exch .knownget not {
- []
- } if % <<font>> [SubstNWP]
- } if
- 1 index exch /SubstNWP exch put
- } if
-} bind def
-
-/PrintFontRef % <string|name> <font> PrintFontRef <string|name> <font>
-{ dup /FontName known { (Font ) } { (CIDFont ) } ifelse print
- 1 index =string cvs print
- dup /FontName .knownget not {
- dup /CIDFontName get
- } if % <string|name> <font> <fontname>
- dup 3 index ne {
- ( \( aliased from ) print
- =string cvs print ( \)) print
- } {
- pop
- } ifelse
-} bind def
-
-/GetFontType % <font> GetFontType int
-{ dup /CIDFontType .knownget {
- exch pop 9 add
- } {
- /FontType get
- } ifelse
-} bind def
-
-/FindInArray % <array> <elem> .array_find <bool>
-{ false 3 1 roll
- exch { % false elem elem_i
- 1 index eq { % false elem
- pop true exch
- } if
- } forall
- pop
-} bind def
-
-/ProvideUnicodeDecoding % <font> ProvideUnicodeDecoding <font>
-{
- % If the font is maintained by FAPI, or if it is TT-emulated CID font,
- % it already has /Decoding. But its value isn't guaranteeed to
- % be an Unicode decoding. Since we can't determine whether
- % it is an Unicode decoding, we unconditionally load an appropriate Unicode decoding
- % and attach it with /GlyphNames2Unicode entry.
- %
- % Another interesting case is when the font already has /GlyphNames2Unicode.
- % The latter to be used instead. Note that /GlyphNames2Unicode
- % appears only when type 32 fonts are disable (see .pdf_hook_DSC_Creator),
- % but an automatic disabling is not implemented yet.
-
- currentglobal true setglobal exch
- dup /FontInfo known not {
- dup /FontInfo 1 dict put
- } if
- { % A loop just for 'exit' context.
- dup /FontInfo get /GlyphNames2Unicode known {
- exit
- } if
- dup /CIDFontType known {
- dup mark exch % bool <font> [ <font>
- dup /CIDSystemInfo get /Ordering get (.Unicode) % bool <font> [ <font> () ()
- concatstrings cvn % bool <font> [ <font> /Name
- /CIDDecoding { findresource } stopped {
- % Can't provide a decoding, giving up without creating /GlyphNames2Unicode.
- cleartomark exit
- } if % bool <font> [ <font> <D>
- exch /FontInfo get exch % bool <font> [ <FI> <D>
- /GlyphNames2Unicode exch
- .forceput % FontInfo can be read-only.
- pop % bool <font>
- exit
- } if
- dup /FontInfo get % bool <font> <FI>
- /GlyphNames2Unicode /Unicode /Decoding findresource
- .forceput % FontInfo can be read-only.
- exit
- } loop
- exch setglobal
-} bind def
-
-currentdict end /ProcSet defineresource pop
-
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_fonts.ps b/Master/tlpkg/tlgs/lib/gs_fonts.ps deleted file mode 100644 index 781619f72ab..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_fonts.ps +++ /dev/null @@ -1,1223 +0,0 @@ -% Copyright (C) 1990-2003 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_fonts.ps 8022 2007-06-05 22:23:38Z giles $
-% Font initialization and management code.
-
-% Define the default font.
-/defaultfontname /Courier def
-
-% Define the name of the font map file.
-% Note that the "%%Replace " comment below provides the font map file name
-% for compiling initialization files into executable. Most likely it should be
-% consistent with the one specified here.
-/defaultfontmap (Fontmap) def
-
-/defaultfontmap_content 50 dict
-1 dict begin
-/; { 2 index 3 1 roll .growput } bind def
-%% Replace 0 (Fontmap)
-end def
-
-% ------ End of editable parameters ------ %
-
-% Define the UniqueIDs and organization XUID assigned to Aladdin.
-% UniqueIDs 5,066,501 - 5,066,580 are assigned as follows:
-% 01 and 02 for shareware Cyrillic
-% 33 through 67 for Type 1 versions of the Hershey fonts
-% UniqueIDs 5,115,501 - 5,115,600 are currently unassigned.
-/AladdinEnterprisesXUID 107 def
-
-% If SUBSTFONT is defined, make it the default font.
-/SUBSTFONT where { pop /defaultfontname /SUBSTFONT load def } if
-
-% Define a reliable way of accessing FontDirectory in systemdict.
-/.FontDirectory
-{ /FontDirectory .systemvar
-} .bind odef
-
-% If DISKFONTS is true, we load individual CharStrings as they are needed.
-% (This is intended primarily for machines with very small memories.)
-% In this case, we define another dictionary, parallel to FontDirectory,
-% that retains an open file for every font loaded.
-/FontFileDirectory 10 dict def
-
-% Define a temporary string for local use, since using =string
-% interferes with some PostScript programs.
-/.fonttempstring 8192 string def
-
-% Split up a search path into individual directories or files.
-/.pathlist % <path> .pathlist <dir1|file1> ...
- { { dup length 0 eq { pop exit } if
- .filenamelistseparator search not { exit } if
- exch pop exch
- }
- loop
- } bind def
-
-% Load a font name -> font file name map.
-userdict /Fontmap .FontDirectory maxlength dict put
-/.loadFontmap { % <file> .loadFontmap -
- % We would like to simply execute .definefontmap as we read,
- % but we have to maintain backward compatibility with an older
- % specification that makes later entries override earlier
- % ones within the same file.
- 50 dict exch .readFontmap
- { .definefontmap } forall
-} bind def
-/.readFontmap { % <dict> <file> .readFontmap <dict>
- { dup token not { closefile exit } if
- % stack: dict file fontname
- % This is a hack to get around the absurd habit of MS-DOS editors
- % of adding an EOF character at the end of the file.
- dup (\032) eq { pop closefile exit } if
- 1 index token not
- { (Fontmap entry for ) print dup =only
- ( has no associated file or alias name! Giving up.) = flush
- {.readFontmap} 0 get 1 .quit
- } if
- dup type dup /stringtype eq exch /nametype eq or not
- { (Fontmap entry for ) print 1 index =only
- ( has an invalid file or alias name! Giving up.) = flush
- {.readFontmap} 0 get 1 .quit
- } if
- % stack: dict file fontname filename|aliasname
- 1 index type /stringtype eq
- 1 index type /nametype eq and 1 index xcheck and
- 1 index /run eq 2 index /.runlibfile eq or and {
- % This is an inclusion entry.
- pop findlibfile { exch pop } { file } ifelse
- 2 index exch .readFontmap pop
- } {
- % This is a real entry.
- % Read and pop tokens until a semicolon.
- { 2 index token not
- { (Fontmap entry for ) print 1 index =only
- ( ends prematurely! Giving up.) = flush
- {.loadFontmap} 0 get 1 .quit
- } if
- dup /; eq { pop 3 index 3 1 roll .growput exit } if
- pop
- } loop
- } ifelse
- } loop
-} bind def
-% Add an entry in Fontmap. We redefine this if the Level 2
-% resource machinery is loaded.
-/.definefontmap % <fontname> <file|alias> .definefontmap -
- { % Since Fontmap is global, make sure the values are storable.
- % If the fontname contains Unicode (first byte == \000) and
- % this is not an alias definition, define an alias using ASCII
- % (stripping out the high \000 bytes). Observed with some TT fonts.
- 1 index 100 string cvs
- dup length 0 gt {
- 0 get 0 eq 1 index type /nametype ne and {
- 1 index 100 string cvs dup length 2 div cvi string true exch
- 0 1 2 index length 1 sub {
- % stack: fontname filename fontnamestring addflag newstring index
- dup 4 index exch 2 mul get 0 ne {
- % High byte of pair is not \000
- pop pop false exch
- exit
- } if
- dup 4 index exch 2 mul 1 add get 2 index 3 1 roll put
- } for
- exch {
- DEBUG { (\nAdding alias for: ) print 1 index ==only ( as: ) print dup == flush } if
- cvn exch cvn .definefontmap % recurse with an alias
- } {
- pop pop % discard the name
- } ifelse
- } if
- } {
- pop
- } ifelse
- .currentglobal 3 1 roll true .setglobal
- dup type /stringtype eq
- { dup .gcheck not { dup length string copy } if
- }
- if
- Fontmap 3 -1 roll 2 copy .knownget
- { % Add an element to the end of the existing value,
- % unless it's the same as the current last element.
- mark exch aload pop counttomark 4 add -1 roll
- 2 copy eq { cleartomark pop pop } { ] readonly .growput } ifelse
- }
- { % Make a new entry.
- mark 4 -1 roll ] readonly .growput
- }
- ifelse .setglobal
- } bind def
-
-% Parse a font file just enough to find the FontName or FontType.
-/.findfontvalue { % <file> <key> .findfontvalue <value> true
- % <file> <key> .findfontvalue false
- % Closes the file in either case.
- exch dup read {
- 2 copy unread 16#80 eq {
- dup (xxxxxx) readstring pop pop % skip .PFB header
- } if
- { % Stack: key file
- % Protect ourselves against syntax errors here.
- dup { token } stopped { pop false exit } if
- not { false exit } if % end of file
- dup /eexec eq { pop false exit } if % reached eexec section
- dup /Subrs eq { pop false exit } if % Subrs without eexec
- dup /CharStrings eq { pop false exit } if % CharStrings without eexec
- dup 3 index eq
- { xcheck not { dup token exit } if } % found key
- { pop }
- ifelse
- } loop
- % Stack: key file value true (or)
- % Stack: key file false
- dup { 4 } { 3 } ifelse -2 roll closefile pop
- } { closefile pop false } ifelse
-} bind def
-/.findfontname
- { /FontName .findfontvalue
- } bind def
-
-% If there is no FONTPATH, try to get one from the environment.
-NOFONTPATH { /FONTPATH () def } if
-/FONTPATH where
- { pop }
- { /FONTPATH (GS_FONTPATH) getenv not { () } if def }
-ifelse
-FONTPATH length 0 eq { (%END FONTPATH) .skipeof } if
-/FONTPATH [ FONTPATH .pathlist ] def
-
-% Scan directories looking for plausible fonts. "Plausible" means that
-% the file begins with %!PS-AdobeFont or %!FontType1, or with \200\001
-% followed by four arbitrary bytes and then either of these strings.
-% To speed up the search, we skip any file whose name appears in
-% the Fontmap (with any extension and upper/lower case variation) already,
-% and any file whose extension definitely indicates it is not a font.
-%
-% NOTE: The current implementation of this procedure is somewhat Unix/DOS-
-% specific. It assumes that '/' and '\' are directory separators, and that
-% the part of a file name following the last '.' is the extension.
-%
-/.lowerstring % <string> .lowerstring <lowerstring>
- { 0 1 2 index length 1 sub
- { 2 copy get dup 65 ge exch 90 le and
- { 2 copy 2 copy get 32 add put }
- if pop
- }
- for
- } bind def
-/.splitfilename { % <dir.../base.extn> .basename <base> <extn>
- % Make the file name read-only to detect aliasing bugs.
- % We really don't like doing this, but we've had one
- % such bug already.
- readonly {
- (/) search { true } { (\\) search } ifelse { pop pop } { exit } ifelse
- } loop
- dup { (.) search { pop pop } { exit } ifelse } loop
- 2 copy eq {
- pop ()
- } {
- exch dup length 2 index length 1 add sub 0 exch getinterval exch
- } ifelse
-} bind def
-/.scanfontdict 1 dict def % establish a binding
-/.scanfontbegin
- { % Construct the table of all file names already in Fontmap.
- currentglobal true setglobal
- .scanfontdict dup maxlength Fontmap length 2 add .max .setmaxlength
- Fontmap
- { exch pop
- { dup type /stringtype eq
- { .splitfilename pop .fonttempstring copy .lowerstring cvn
- .scanfontdict exch true put
- }
- { pop
- }
- ifelse
- }
- forall
- }
- forall
- setglobal
- } bind def
-/.scanfontskip mark
- % Strings are converted to names anyway, so....
- /afm true
- /bat true
- /c true
- /cmd true
- /com true
- /dir true
- /dll true
- /doc true
- /drv true
- /exe true
- /fon true
- /fot true
- /h true
- /o true
- /obj true
- /pfm true
- /pss true % Adobe Multiple Master font instances
- /txt true
-.dicttomark def
-/.scan1fontstring 8192 string def
-% %%BeginFont: is not per Adobe documentation, but a few fonts have it.
-/.scanfontheaders [(%!PS-Adobe*) (%!FontType*) (%%BeginFont:*)] def
-0 .scanfontheaders { length .max } forall 6 add % extra for PFB header
-/.scan1fontfirst exch string def
-/.scanfontdir % <dirname> .scanfontdir -
- { currentglobal exch true setglobal
- QUIET not { (Scanning ) print dup print ( for fonts...) print flush } if
- [ 1 index ] (*) .generate_dir_list_templates
- 0 0 0 4 -1 roll % found scanned files
- { % stack: <fontcount> <scancount> <filecount> <filename>
- exch 1 add exch % increment filecount
- dup .splitfilename .fonttempstring copy .lowerstring
- % stack: <fontcount> <scancount> <filecount+1> <filename>
- % <BASE> <ext>
- .scanfontskip exch known exch .scanfontdict exch known or
- { pop
- % stack: <fontcount> <scancount> <filecount+1>
- }
- { 3 -1 roll 1 add 3 1 roll
- % stack: <fontcount> <scancount+1> <filecount+1> <filename>
- dup (r) { file } .internalstopped
- { pop pop null ()
- % stack: <fontcount> <scancount+1> <filecount+1> <filename>
- % null ()
- }
- {
- % On some platforms, the file operator will open directories,
- % but an error will occur if we try to read from one.
- % Handle this possibility here.
- dup .scan1fontfirst { readstring } .internalstopped
- { pop pop () }
- { pop }
- ifelse
- % stack: <fontcount> <scancount+1> <filecount+1>
- % <filename> <file> <header>
- }
- ifelse
- % Check for PFB file header.
- dup (\200\001????*) .stringmatch
- { dup length 6 sub 6 exch getinterval }
- if
- % Check for font file headers.
- false .scanfontheaders
- { 2 index exch .stringmatch or
- }
- forall exch pop
- { % stack: <fontcount> <scancount+1> <filecount+1> <filename>
- % <file>
- dup 0 setfileposition .findfontname
- { dup Fontmap exch known
- { pop pop
- }
- { exch copystring exch
- DEBUG { ( ) print dup =only flush } if
- 1 index .definefontmap
- .splitfilename pop true .scanfontdict 3 1 roll .growput
- % Increment fontcount.
- 3 -1 roll 1 add 3 1 roll
- }
- ifelse
- }
- { pop
- }
- ifelse
- }
- % .findfontname will have done a closefile in the above case.
- { dup null eq { pop } { closefile } ifelse pop
- }
- ifelse
- }
- ifelse
- }
- .scan1fontstring filenameforall
- QUIET
- { pop pop pop }
- { ( ) print =only ( files, ) print =only ( scanned, ) print
- =only ( new fonts.) = flush
- }
- ifelse
- pop
- setglobal
- } bind def
-
-%END FONTPATH
-
-% Try to enumerate native fonts registered with the os
-% and add them to the fontmap. This relies on a custom
-% operator which calls platform-specific C code. It
-% returns an array of arrays, each containing a pair
-% of strings: what the system thinks is the ps name,
-% and the access path.
-/.setnativefontmapbuilt { % set whether we've been run
- systemdict exch /.nativefontmapbuilt exch .forceput
-} .bind executeonly def
-false .setnativefontmapbuilt
-/.buildnativefontmap { % - .buildnativefontmap <bool>
- QUIET not {
- (Querying operating system for font files...\n)
- print flush
- } if
- .getnativefonts dup
- {
- exch
- {
- % stack: [ (name) (path) ]
- % verify the font name ourselves
- dup 1 get (r) { file } stopped
- {
- % skip the entry if we can't open the returned path
- pop pop pop
- }{
- % we could open the font file
- .findfontname
- not { dup 0 get } if % stack: (newname) [ (name) (path) ]
- % DEBUG { ( found ) print dup print (\n) print flush } if
- % add entry to the fontmap
- 1 index exch 0 exch dup type /nametype ne {cvn} if put
- aload pop .definefontmap
- } ifelse
- } forall
- } if
- % record that we've been run
- true .setnativefontmapbuilt
-} bind def
-
-% Create the dictionary that registers the .buildfont procedure
-% (called by definefont) for each FontType.
-/buildfontdict 20 dict def
-
-% Register Type 3 fonts, which are always supported, for definefont.
-buildfontdict 3 /.buildfont3 cvx put
-
-% Register Type 0 fonts if they are supported. Strictly speaking,
-% we should do this in its own file (gs_type0.ps), but since this is
-% the only thing that would be in that file, it's simpler to put it here.
-/.buildfont0 where { pop buildfontdict 0 /.buildfont0 cvx put } if
-
-% Define definefont. This is a procedure built on a set of operators
-% that do all the error checking and key insertion.
-/.growfontdict
- { % Grow the font dictionary, if necessary, to ensure room for an
- % added entry, making sure there is at least one slot left for FID.
- dup maxlength 1 index length sub 2 lt
- { dup dup wcheck
- { .growdict }
- { .growdictlength dict .copydict }
- ifelse
- }
- { dup wcheck not { dup maxlength dict .copydict } if
- }
- ifelse
- } bind def
-/.completefont {
- { % Check for disabled platform fonts.
- NOPLATFONTS
- { % Make sure we leave room for FID.
- .growfontdict dup /ExactSize 0 put
- }
- { % Hack: if the Encoding looks like it might be the
- % Symbol or Dingbats encoding, load those now (for the
- % benefit of platform font matching) just in case
- % the font didn't actually reference them.
- % Note that some types of font don't have an Encoding.
- dup /Encoding .knownget {
- dup length 65 ge {
- 64 get
- dup /congruent eq { SymbolEncoding pop } if
- /a9 eq { DingbatsEncoding pop } if
- } {
- pop
- } ifelse
- } if
- }
- ifelse
- dup /OrigFont known not {
- dup dup /OrigFont exch .growput
- } if
- true exch
- % If this is a CIDFont, CIDFontType takes precedence
- % over FontType.
- dup /CIDFontType known {
- /.buildcidfont where {
- pop exch not exch % true => false
- } if
- } if
- exch {
- dup /FontType get //buildfontdict exch get
- } {
- {.buildcidfont} % so it gets bound
- } ifelse
- } stopped { $error /command get /invalidfont signalerror } if
-
- % Execute the .buildxxxfontx outside the 'stopped', because we don't
- % want its errors converted to invalidfont.
- exec
-
- {
-
- DISKFONTS {
- FontFileDirectory 2 index known {
- dup /FontFile FontFileDirectory 4 index get .growput
- } if
- } if
- systemdict /ProvideUnicode .knownget not { false } if {
- /FontEmulationProcs /ProcSet findresource
- /ProvideUnicodeDecoding get exec
- } if
- readonly % stack: name fontdict
- } stopped { $error /command get /invalidfont signalerror } if
-} bind def
-/definefont
- { dup rcheck not {
- /definefont cvx /invalidaccess signalerror
- } if
- /definefont cvx {.completefont} .errorexec
- % If the current allocation mode is global, also enter
- % the font in LocalFontDirectory.
- .currentglobal
- { //systemdict /LocalFontDirectory .knownget
- { 2 index 2 index { .growput } //superexec } % readonly
- if
- }
- if
- dup .FontDirectory 4 -2 roll { .growput } //superexec % readonly
- % If the font originated as a resource, register it.
- currentfile .currentresourcefile eq { dup .registerfont } if
- readonly
- } odef
-
-% Define a procedure for defining aliased fonts.
-% We use this only for explicitly aliased fonts, not substituted fonts:
-% we think this matches the observed behavior of Adobe interpreters.
-/.aliasfont % <name> <font> .aliasfont <newFont>
- { .currentglobal 3 1 roll dup .gcheck .setglobal
- % <bool> <name> <font>
- dup length 2 add dict % <bool> <name> <font> <dict>
- dup 3 -1 roll % <bool> <name> <dict> <dict> <font>
- { 1 index /FID eq { pop pop } { put dup } ifelse } forall
- % <bool> <name> <dict> <dict>
- % Stack: global fontname newfont newfont.
- % We might be defining a global font whose FontName
- % is a local string. This is weird, but legal,
- % and doesn't cause problems anywhere else:
- % to avoid any possible problems in this case, do a cvn.
- % We might also be defining (as an alias) a global font
- % whose FontName is a local non-string, if someone passed a
- % garbage value to findfont. In this case, just don't
- % call definefont at all.
- 2 index dup type /stringtype eq exch .gcheck or 1 index .gcheck not or
- { pop % <bool> <name> <dict>
- 1 index dup type /stringtype eq { cvn } if
- % <bool> <name> <dict> <name1>
- % HACK:
- % We want to know whether we alias a font,
- % because in this case its FontName to be replaced with the alias.
- % There is no simple way to know that at this point.
- % But if the original font has defaultfontname,
- % we probably substitute it rather than alias.
- % Using such condition as an approximation to the strong condition.
- %
- % Note it works wrongly if Fontmap maps something to defaultfontname like this :
- % /Courier /NimbusMonL-Regu ;
- % /Something /Courier ;
- % The FontName of Something will not be /Something. It will be /Courier .
- %
- 1 index /FontName get defaultfontname ne {
- 2 copy /FontName exch put
- } if
- 1 index exch /.Alias exch put % <bool> <name> <dict>
- dup dup /OrigFont exch .growput
- % Don't bind in definefont, since Level 2 redefines it.
- /definefont .systemvar exec
- }
- { /findfont cvx {.completefont} .errorexec pop exch pop
- }
- ifelse
- exch .setglobal
- } odef % so findfont will bind it
-
-% Define .loadfontfile for loading a font. If we recognize Type 1 and/or
-% TrueType fonts, gs_type1.ps and/or gs_ttf.ps will redefine this.
-/.loadfontfile {
- % According to Ed Taft, Adobe interpreters push userdict
- % before loading a font, and pop it afterwards.
- userdict begin
- cvx exec
- end
-} bind def
-/.setloadingfont {
- //systemdict /.loadingfont 3 -1 roll .forceput
-} .bind odef % .forceput must be bound and hidden
-/.loadfont
- { % Some buggy fonts leave extra junk on the stack,
- % so we have to make a closure that records the stack depth
- % in a fail-safe way.
- true .setloadingfont
- { /FAPI_hook_disable pop % gs_fapi accesses this with execstack_lookup - don't remove !
- {{.loadfontfile} .execasresource} count 1 sub 2 .execn
- count exch sub { pop } repeat
- exit
- } loop % this loop is a pattern for execstack_lookup, don't remove !
- false .setloadingfont
- } bind def
-
-% Find an alternate font to substitute for an unknown one.
-% We go to some trouble to parse the font name and extract
-% properties from it. Later entries take priority over earlier.
-/.substitutefaces [
- % Guess at suitable substitutions for random unknown fonts.
- [(Book) /NewCenturySchlbk 0]
- [(Grot) /Helvetica 0]
- [(Roman) /Times 0]
- [(Chancery) /ZapfChancery-MediumItalic 0]
- % If the family name appears in the font name,
- % use a font from that family.
- [(Arial) /Helvetica 0]
- [(Avant) /AvantGarde 0]
- [(Bookman) /Bookman 0]
- [(Century) /NewCenturySchlbk 0]
- [(Cour) /Courier 0]
- [(Frut) /Helvetica 0]
- [(Garamond) /Palatino 0]
- [(Geneva) /Helvetica 0]
- [(Helv) /Helvetica 0]
- [(NewYork) /Bookman 0]
- [(Pala) /Palatino 0]
- [(Schlbk) /NewCenturySchlbk 0]
- [(Swiss) /Helvetica 0]
- [(Symbol) /Symbol 0]
- [(Times) /Times 0]
- % Substitute for Adobe Multiple Master fonts.
- [(Minion) /Times 0]
- [(Myriad) /Helvetica 0]
- % If the font wants to be monospace, use Courier.
- [(Monospace) /Courier 0]
- [(Typewriter) /Courier 0]
- % Define substitutes for the other Adobe PostScript 3 fonts.
- % For some of them, the substitution is pretty bad!
- [(Albertus) /Palatino 0]
- [(AntiqueOlive) /Helvetica 0]
- [(Bodoni) /NewCenturySchlbk 0]
- [(Chicago) /Helvetica 2]
- [(Clarendon) /Bookman 0]
- [(Cooper) /NewCenturySchlbk 0]
- [(Copperplate) /AvantGarde 0] % inappropriate, small-cap font
- [(Coronet) /ZapfChancery-MediumItalic 0]
- [(Eurostile) /Helvetica 0]
- [(Geneva) /Courier 2] % should be fixed-pitch sans demi
- [(GillSans) /Helvetica 2]
- [(GillSans-Light) /Helvetica 0]
- [(Goudy) /Palatino 0]
- [(Hoefler) /NewCenturySchlbk 0]
- [(Joanna) /Times 0]
- [(LetterGothic) /Courier 0] % should be fixed-pitch sans
- [(LubalinGraph-Book) /Bookman 2]
- [(LubalinGraph-Demi) /Bookman 0]
- [(Marigold) /ZapfChancery-MediumItalic 0]
- [(MonaLisa-Recut) /Palatino 0] % inappropriate
- [(Monaco) /Courier 2] % should be fixed-pitch sans demi
- [(Optima) /Helvetica 0]
- [(Oxford) /ZapfChancery-MediumItalic 0]
- [(Tekton) /Helvetica 0]
- [(Univers) /Helvetica 0]
-] readonly def
-/.substituteproperties [
- [(It) 9] [(Oblique) 1]
- [(Black) 2] [(Bd) 2] [(Bold) 2] [(bold) 2] [(Demi) 2] [(Heavy) 2] [(Sb) 2]
- [(Cn) 4] [(Cond) 4] [(Narrow) 4] [(Pkg) 4] [(Compr) 4]
- [(Serif) 8] [(Sans) -8]
-] readonly def
-/.fontnameproperties { % <int> <string|name> .fontnameproperties
- % <int'>
- .fontnamestring
- .substituteproperties {
- 2 copy 0 get search {
- pop pop pop dup length 1 sub 1 exch getinterval 3 -1 roll exch {
- dup 0 ge { or } { neg not and } ifelse
- } forall exch
- } {
- pop pop
- } ifelse
- } forall pop
-} bind def
-/.substitutefamilies mark
- /AvantGarde
- {/AvantGarde-Book /AvantGarde-BookOblique
- /AvantGarde-Demi /AvantGarde-DemiOblique}
- /Bookman
- {/Bookman-Demi /Bookman-DemiItalic /Bookman-Light /Bookman-LightItalic}
- /Courier
- {/Courier /Courier-Oblique /Courier-Bold /Courier-BoldOblique}
- /Helvetica
- {/Helvetica /Helvetica-Oblique /Helvetica-Bold /Helvetica-BoldOblique
- /Helvetica-Narrow /Helvetica-Narrow-Oblique
- /Helvetica-Narrow-Bold /Helvetica-Narrow-BoldOblique}
- /NewCenturySchlbk
- {/NewCenturySchlbk-Roman /NewCenturySchlbk-Italic
- /NewCenturySchlbk-Bold /NewCenturySchlbk-BoldItalic}
- /Palatino
- {/Palatino-Roman /Palatino-Italic /Palatino-Bold /Palatino-BoldItalic}
- /Symbol
- {/Symbol /Symbol /Symbol /Symbol}
- /Times
- {/Times-Roman /Times-Italic /Times-Bold /Times-BoldItalic}
- /ZapfChancery-MediumItalic
- {/ZapfChancery-MediumItalic}
-.dicttomark readonly def
-/.nametostring { % <name> .nametostring <string>
- % <other> .nametostring <other>
- dup type /nametype eq { .namestring } if
-} bind def
-/.fontnamestring { % <fontname> .fontnamestring <string|name>
- dup type dup /nametype eq {
- pop .namestring
- } {
- /stringtype ne { pop () } if
- } ifelse
-} bind def
-/.substitutefontname { % <fontname> <properties> .substitutefontname
- % <altname|null>
- % Look for properties and/or a face name in the font name.
- % If we find any, use Times (serif) or Helvetica (sans) as the
- % base font; otherwise, use the default font.
- % Note that the "substituted" font name may be the same as
- % the requested one; the caller must check this.
- exch .fontnamestring {
- defaultfontname /Helvetica-Oblique /Helvetica-Bold /Helvetica-BoldOblique
- /Helvetica-Narrow /Helvetica-Narrow-Oblique
- /Helvetica-Narrow-Bold /Helvetica-Narrow-BoldOblique
- /Times-Roman /Times-Italic /Times-Bold /Times-BoldItalic
- /Helvetica-Narrow /Helvetica-Narrow-Oblique
- /Helvetica-Narrow-Bold /Helvetica-Narrow-BoldOblique
- } 3 1 roll
- % Stack: facelist properties fontname
- % Look for a face name.
- .substitutefaces {
- 2 copy 0 get search {
- pop pop pop
- % Stack: facelist properties fontname [(pattern) family properties]
- dup 2 get 4 -1 roll or 3 1 roll
- 1 get .substitutefamilies exch get
- 4 -1 roll pop 3 1 roll
- } {
- pop pop
- } ifelse
- } forall pop
- 1 index length mod get exec
-} bind def
-/.substitutefont { % <fontname> .substitutefont <altname>
- dup 0 exch .fontnameproperties .substitutefontname
- % Only accept fonts known in the Fontmap.
- Fontmap 1 index known not { pop defaultfontname } if
-} bind def
-
-% If requested, make (and recognize) fake entries in FontDirectory for fonts
-% present in Fontmap but not actually loaded. Thanks to Ray Johnston for
-% the idea behind this code.
-FAKEFONTS not { (%END FAKEFONTS) .skipeof } if
-
-% We use the presence or absence of the FontMatrix key to indicate whether
-% a font is real or fake. We must pop the arguments at the very end,
-% so that stack protection will be effective.
-
-/definefont { % <name> <font> definefont <font>
- dup /FontMatrix known {
- //definefont
- } {
- 2 copy /FontName get findfont //definefont exch pop exch pop
- } ifelse
-} bind odef
-
-/scalefont { % <font> <scale> scalefont <font>
- 1 index /FontMatrix known {
- //scalefont
- } {
- 1 index /FontName get findfont 1 index //scalefont
- exch pop exch pop
- } ifelse
-} bind odef
-
-/makefont { % <font> <matrix> makefont <font>
- 1 index /FontMatrix known {
- //makefont
- } {
- 1 index /FontName get findfont 1 index //makefont
- exch pop exch pop
- } ifelse
-} bind odef
-
-/setfont { % <font> setfont -
- dup /FontMatrix known {
- //setfont
- } {
- dup /FontName get findfont //setfont pop
- } ifelse
-} bind odef
-
-%END FAKEFONTS
-
-% Define findfont so it tries to load a font if it's not found.
-% The Red Book requires that findfont be a procedure, not an operator,
-% but it still needs to restore the stacks reliably if it fails,
-% so we do all the work in an operator.
-/.findfont { % <fontname> .findfont <font>
- mark 1 index % <fontname> mark <fontname>
- //systemdict begin .dofindfont
- % <fontname> mark <alias> ... <font>
- % Define any needed aliases.
- counttomark 1 sub { .aliasfont } repeat end
- % <fontname> mark <font>
- exch pop exch pop
-} odef
-/findfont {
- .findfont
-} bind def
-% Check whether the font name we are about to look for is already on the list
-% of aliases we're accumulating; if so, cause an error.
-/.checkalias % -mark- <alias1> ... <name> .checkalias <<same>>
- { counttomark 1 sub -1 1
- { index 1 index eq
- { pop QUIET not
- { (Unable to substitute for font.) = flush
- } if
- /findfont cvx /invalidfont signalerror
- }
- if
- }
- for
- } bind def
-% Get a (non-fake) font if present in a FontDirectory.
-/.fontknownget % <fontdir> <fontname> .fontknownget <font> true
- % <fontdir> <fontname> .fontknownget false
- { .knownget
- { FAKEFONTS
- { dup /FontMatrix known { true } { pop false } ifelse }
- { true }
- ifelse
- }
- { false
- }
- ifelse
- } bind def
-% This is the standard procedure for handling font substitution.
-% Its location is per an Adobe newsgroup posting.
-% It is called with the font name on the stack, standing in for findfont.
-/.stdsubstfont { % mark <alias1> ... <fontname> .stdsubstfont mark <alias1> ... <aliasN> <font>
- /SUBSTFONT where {
- pop QUIET not {
- (Substituting for font ) print dup =only
- (.) = flush
- } if
- % No aliasing.
- % This mode is incompatible with high level devices.
- cleartomark mark defaultfontname
- } {
- dup .substitutefont
- 2 copy eq { pop defaultfontname } if
- .checkalias
- QUIET not {
- SHORTERRORS {
- (%%[) print 1 index =only
- ( not found, substituting ) print dup =only (]%%)
- } {
- (Substituting font ) print dup =only
- ( for ) print 1 index =only (.)
- } ifelse = flush
- } if
- } ifelse
- /Font findresource
-} bind def
-
-% Default font substitution does {pop /Courier} om many implementations.
-% GS post-process font substitution in .stdsubstfont and uses {} for
-% backward compatibility
-$error /SubstituteFont { } put
-
-% Scan the next directory on FONTPATH.
-/.scannextfontdir { % - .scannextfontdir <bool>
- % If we haven't scanned all the directories in
- % FONTPATH, scan the next one.
- null 0 1 FONTPATH length 1 sub {
- FONTPATH 1 index get null ne { exch pop exit } if pop
- } for dup null ne {
- dup 0 eq { .scanfontbegin } if
- FONTPATH 1 index get .scanfontdir
- FONTPATH exch null put true
- } {
- pop false
- } ifelse
-} bind def
-% Do the work of findfont, including substitution, defaulting, and
-% scanning of FONTPATH.
-/.dofindfont { % mark <fontname> .dofindfont % mark <alias> ... <font>
- .tryfindfont not {
- % We didn't find the font. If we haven't scanned
- % all the directories in FONTPATH, scan the next one
- % now and look for the font again.
- .scannextfontdir {
- % Start over with an empty alias list.
- counttomark 1 sub { pop } repeat % mark <fontname>
- .dofindfont
- } {
- % No more directories to scan. Try building the native
- % font map entries if we haven't already done so.
- systemdict /.nativefontmapbuilt get not { .buildnativefontmap } { false } ifelse {
- % Same stack as at the beginning of .dofindfont.
- .dofindfont % start over
- } {
- % No luck. Make sure we're not already
- % looking for the default font.
- QUIET not {
- (Didn't find this font on the system!\n)
- print
- } if
- dup defaultfontname eq {
- QUIET not {
- (Unable to load default font ) print
- dup =only (! Giving up.) = flush
- } if
- /findfont cvx /invalidfont signalerror
- } if
- % Substitute for the font. Don't alias.
- % Same stack as at the beginning of .dofindfont.
- $error /SubstituteFont get exec
- %
- % igorm: I guess the surrounding code assumes that .stdsubstfont
- % must ADD an alias to allow .checkalias and .findfont to work properly.
- % Also I guess that a trailing recursion is
- % used in .dofindfont and through .stdsubstfont
- % just to represent a simple iteration,
- % which accumulates the aliases after the mark.
- .stdsubstfont
- } ifelse
- } ifelse
- } if
-} bind def
-% Try to find a font using only the present contents of Fontmap.
-/.tryfindfont { % <fontname> .tryfindfont <font> true
- % <fontname> .tryfindfont false
- .FontDirectory 1 index .fontknownget
- { % Already loaded
- exch pop true
- }
- { dup Fontmap exch .knownget not
- { % Unknown font name. Look for a file with the
- % same name as the requested font.
- .tryloadfont
- }
- { % Try each element of the Fontmap in turn.
- false exch % (in case we exhaust the list)
- % Stack: fontname false fontmaplist
- { exch pop
- dup type /nametype eq
- { % Font alias
- .checkalias .tryfindfont exit
- }
- { dup dup type dup /arraytype eq exch /packedarraytype eq or exch xcheck and
- { % Font with a procedural definition
- exec % The procedure will load the font.
- % Check to make sure this really happened.
- .FontDirectory 1 index .knownget
- { exch pop true exit }
- if
- }
- { % Font file name
- .loadfontloop { true exit } if
- }
- ifelse
- }
- ifelse false
- }
- forall
- % Stack: font true -or- fontname false
- { true
- }
- { % None of the Fontmap entries worked.
- % Try loading a file with the same name
- % as the requested font.
- .tryloadfont
- }
- ifelse
- }
- ifelse
- }
- ifelse
- } bind def
-
-% any user of .putgstringcopy must use bind and executeonly
-/.putgstringcopy % <dict> <name> <string> .putgstringcopy -
-{ 2 index gcheck currentglobal
- 2 copy eq {
- pop pop .forceput
- } {
- 5 1 roll setglobal
- dup length string copy
- .forceput setglobal
- } ifelse
-} .bind odef % must be bound and hidden for .forceput
-
-
-% Attempt to load a font from a file.
-/.tryloadfont { % <fontname> .tryloadfont <font> true
- % <fontname> .tryloadfont false
- dup .nametostring
- % Hack: check for the presence of the resource machinery.
- /.genericrfn where {
- pop
- pop dup .fonttempstring /FontResourceDir getsystemparam .genericrfn
- .loadfontloop {
- //true
- } {
- dup .nametostring .loadfontloop
- } ifelse
- } {
- .loadfontloop
- } ifelse
-} bind def
-/.loadfontloop { % <fontname> <filename> .loadfontloop
- % <font> true
- % -or-
- % <fontname> false
- % See above regarding the use of 'loop'.
- { % Is the font name a string?
- dup type /stringtype ne
- { QUIET not
- { (Can't find font with non-string name: ) print dup =only (.) = flush
- }
- if pop false exit
- }
- if
- % Can we open the file?
- findlibfile not
- { QUIET not
- { (Can't find \(or can't open\) font file ) print dup print
- (.) = flush
- }
- if pop false exit
- }
- if
-
- % Stack: fontname fontfilename fontfile
- DISKFONTS
- { .currentglobal true .setglobal
- 2 index (r) file
- FontFileDirectory exch 5 index exch .growput
- .setglobal
- }
- if
- QUIET not
- { (Loading ) print 2 index =only
- ( font from ) print 1 index print (... ) print flush
- }
- if
- % If LOCALFONTS isn't set, load the font into local or global
- % VM according to FontType; if LOCALFONTS is set, load the font
- % into the current VM, which is what Adobe printers (but not
- % DPS or CPSI) do.
- LOCALFONTS { false } { /setglobal where } ifelse
- { pop /FontType .findfontvalue { 1 eq } { false } ifelse
- % .setglobal, like setglobal, aliases FontDirectory to
- % GlobalFontDirectory if appropriate. However, we mustn't
- % allow the current version of .setglobal to be bound in,
- % because it's different depending on language level.
- .currentglobal exch /.setglobal .systemvar exec
- % Remove the fake definition, if any.
- .FontDirectory 3 index .forceundef % readonly
- 1 index (r) file .loadfont .FontDirectory exch
- /.setglobal .systemvar exec
- }
- { .loadfont .FontDirectory
- }
- ifelse
- % Stack: fontname fontfilename fontdirectory
- QUIET not
- { //systemdict /level2dict known
- { .currentglobal false .setglobal vmstatus
- true .setglobal vmstatus 3 -1 roll pop
- 6 -1 roll .setglobal 5
- }
- { vmstatus 3
- }
- ifelse { =only ( ) print } repeat
- (done.) = flush
- } if
-
- % Check to make sure the font was actually loaded.
- dup 3 index .fontknownget
- { dup /PathLoad 4 index //.putgstringcopy exec
- 4 1 roll pop pop pop true exit
- } if
-
- % Maybe the file had a different FontName.
- % See if we can get a FontName from the file, and if so,
- % whether a font by that name exists now.
- exch dup % Stack: origfontname fontdirectory path path
- (r) file .findfontname
- { % Stack: origfontname fontdirectory path filefontname
- 2 index 1 index .fontknownget
- { % Yes. Stack: origfontname fontdirectory path filefontname fontdict
- dup 4 -1 roll /PathLoad exch //.putgstringcopy exec
- % Stack: origfontname fontdirectory filefontname fontdict
- 3 -1 roll pop exch
- % Stack: origfontname fontdict filefontname
- QUIET
- { pop
- }
- { (Using ) print =only
- ( font for ) print 1 index =only
- (.) = flush
- }
- ifelse % Stack: origfontname fontdict
- exch pop true exit
- % Stack: fontdict
- }
- if pop % Stack: origfontname fontdirectory path
- }
- if pop pop % Stack: origfontname
-
- % The font definitely did not load correctly.
- QUIET not
- { (Loading ) print dup =only
- ( font failed.) = flush
- } if
- false exit
-
- } loop % end of loop
-
- } bind executeonly def % must be bound and hidden for .putgstringcopy
-
-currentdict /.putgstringcopy .undef
-
-% Define a procedure to load all known fonts.
-% This isn't likely to be very useful.
-/loadallfonts
- { Fontmap { pop findfont pop } forall
- } bind def
-
-% If requested, load all the fonts defined in the Fontmap into FontDirectory
-% as "fake" fonts i.e., font dicts with only FontName and FontType defined.
-% (We define FontType only for the sake of some questionable code in the
-% Apple Printer Utility 2.0 font inquiry code.)
-%
-% Note that this procedure only creates fake fonts in the FontDirectory
-% associated with the current VM. This is because in multi-context systems,
-% creating the fake fonts in local VM leads to undesirable complications.
-/.definefakefonts
- {
- }
- {
- (gs_fonts FAKEFONTS) VMDEBUG
- Fontmap {
- pop dup type /stringtype eq { cvn } if
- .FontDirectory 1 index known not {
- 2 dict dup /FontName 3 index put
- dup /FontType 1 put
- .FontDirectory 3 1 roll { put } //superexec % readonly
- } {
- pop
- } ifelse
- } forall
- }
-FAKEFONTS { exch } if pop def % don't bind, .current/setglobal get redefined
-
-% Install initial fonts from Fontmap.
-/.loadinitialfonts
- { NOFONTMAP not
- { /FONTMAP where
- { pop [ FONTMAP .pathlist ]
- { dup VMDEBUG findlibfile
- { exch pop .loadFontmap }
- { /undefinedfilename signalerror }
- ifelse
- }
- }
- { LIBPATH
- { defaultfontmap
- false .file_name_combine
- {
- dup VMDEBUG
- (r) { file } .internalstopped {
- pop pop
- defaultfontmap_content { .definefontmap } forall
- } {
- .loadFontmap
- } ifelse
- } {
- pop pop
- } ifelse
- }
- }
- ifelse forall
- }
- if
- userdict /defaultfontmap_content .undef
- .definefakefonts % current VM is global
- } def % don't bind, .current/setglobal get redefined
-
-% ---------------- Synthetic font support ---------------- %
-
-% Create a new font by modifying an existing one. paramdict contains
-% entries with the same keys as the ones found in a Type 1 font;
-% it should also contain enough empty entries to allow adding the
-% corresponding non-overridden entries from the original font dictionary,
-% including FID. If paramdict includes a FontInfo entry, this will
-% also override the original font's FontInfo, entry by entry;
-% again, it must contain enough empty entries.
-
-% Note that this procedure does not perform a definefont.
-
-/.makemodifiedfont % <fontdict> <paramdict> .makemodifiedfont <fontdict'>
- { exch
- { % Stack: destdict key value
- 1 index /FID ne
- { 2 index 2 index known
- { % Skip fontdict entry supplied in paramdict, but
- % handle FontInfo specially.
- 1 index /FontInfo eq
- { 2 index 2 index get % new FontInfo
- 1 index % old FontInfo
- { % Stack: destdict key value destinfo key value
- 2 index 2 index known
- { pop pop }
- { 2 index 3 1 roll put }
- ifelse
- }
- forall pop
- }
- if
- }
- { % No override, copy the fontdict entry.
- 2 index 3 1 roll put
- dup dup % to match pop pop below
- }
- ifelse
- }
- if
- pop pop
- } forall
- } bind def
-
-% Make a modified font and define it. Note that unlike definefont,
-% this does not leave the font on the operand stack.
-
-/.definemodifiedfont % <fontdict> <paramdict> .definemodifiedfont -
- { .makemodifiedfont
- dup /FontName get exch definefont pop
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/gs_frsd.ps b/Master/tlpkg/tlgs/lib/gs_frsd.ps deleted file mode 100644 index fea125258f9..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_frsd.ps +++ /dev/null @@ -1,87 +0,0 @@ -% Copyright (C) 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_frsd.ps 7629 2007-01-21 17:53:13Z lpd $
-% Implementation of ReusableStreamDecode filter.
-% This file must be loaded after gs_lev2.ps and gs_res.ps.
-
-level2dict begin
-
-% ------ ReusableStreamDecode filter ------ %
-
-/.reusablestreamdecode { % <source> <dict> .reusablestreamdecode <file>
- % <source> .reusablestreamdecode <file>
- % Collect the filter parameters.
- dup type /dicttype eq { 2 copy } { dup 0 dict } ifelse
- dup .rsdparams
- % Construct the filter pipeline.
- % The very first filter should use the value of CloseSource
- % from the RSD dictionary; all the others should have
- % CloseSource = true.
- % Stack: source dict filters parms
- 2 index /CloseSource .knownget not { false } if 5 -1 roll
- % Stack: dict filters parms CloseSource source
- 0 1 5 index length 1 sub {
- 4 index 1 index get
- % Stack: dict filters parms CloseSource source index filtname
- 4 index null eq {
- 0 dict
- } {
- 4 index 2 index get dup null eq { pop } if
- } ifelse
- 3 -1 roll pop exch filter
- exch pop true exch % set CloseSource for further filters
- } for
- % If AsyncRead is true, try to create the filter directly.
- % Stack: dict filters parms CloseSource source
- 4 index /AsyncRead .knownget not { false } if {
- 1 index { .reusablestream } .internalstopped
- } {
- null true
- } ifelse {
- pop
- % No luck. Read the entire contents of the stream now.
- dup type /filetype ne {
- % Make a stream from a procedure or string data source.
- 0 () .subfiledecode
- } if
- % We must allocate the string in the same VM space as its
- % source, since the reusable stream must be allocated there.
- .currentglobal 1 index gcheck .setglobal exch
- % Stack: dict filters parms CloseSource oldglobal file
- 10 dict exch {
- % Stack: dict filters parms CloseSource oldglobal contdict file
- dup 64000 string readstring
- 3 index dup length 4 -1 roll put not { exit } if
- } loop pop
- % Concatenate the contents into one big string.
- % Stack: dict filters parms CloseSource oldglobal contdict
- 0 1 index { length exch pop add } forall
- dup 65400 gt { .bytestring } { string } ifelse
- 3 -1 roll .setglobal exch {
- % Stack: dict filters parms CloseSource string index substring
- exch 64000 mul exch 2 index 3 1 roll putinterval
- } forall
- % Now create the stream on the string.
- 1 index .reusablestream
- } if
- % We created the stream successfully: clean up.
- 4 { exch pop } repeat
- 1 index type /dicttype eq { exch pop } if exch pop
-} odef
-
-filterdict /ReusableStreamDecode /.reusablestreamdecode load put
-
-end % level2dict
diff --git a/Master/tlpkg/tlgs/lib/gs_icc.ps b/Master/tlpkg/tlgs/lib/gs_icc.ps deleted file mode 100644 index 7068940ed92..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_icc.ps +++ /dev/null @@ -1,340 +0,0 @@ -% Copyright (C) 2001, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_icc.ps 8306 2007-10-20 16:34:38Z alexcher $
-% ICCBased color space method dictionaries.
-% This assumes gs_ciecs2.ps has already been processed.
-
-%
-% Note that the substitution procedure in this routine will dynamically
-% check for support of ICCBased color space. If such support is not
-% provided, the alternative color space will be used.
-%
-% The validation routine in dictionary (cs_validate) performs a more
-% extensive validation than is done for other color spaces, because
-% .seticcspace does less checking than most other color space setting
-% operators.
-%
-
-
-.currentglobal true .setglobal
-.cspace_util begin
-
-%
-% A dictionary for mapping the number of components of an ICCBased color
-% space to the appropriate alternative color space. This is used only
-% if an alternative color space is not specifically provided.
-%
-/icc_comp_map_dict
- mark 1 /DeviceGray 3 /DeviceRGB 4 /DeviceCMYK .dicttomark
-def
-
-%
-% <array1> get_icc_alternative_space <name | array2>
-%
-% Get the alternative color space for an ICCBased color space.
-%
-/get_icc_alternative_space
- {
- 1 get dup /Alternate .knownget
- { exch pop }
- { /N get //icc_comp_map_dict exch get }
- ifelse
- }
-bind def
-
-
-colorspacedict
-/ICCBased
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate true
- /cs_potential_icc_alternate false
- /cs_get_ncomps { 1 get /N get } bind
-
- /cs_get_range
- {
- 1 get dup /Range .knownget
- { exch pop }
- { /N get 2 mul //dflt_range_4 exch 0 exch getinterval }
- ifelse
- }
- bind
-
- /cs_get_default_color { 1 get /N get { 0 } repeat } bind
-
- %
- % For generating a gray, RGB, or CMYK equivalent color, we will
- % assume that the alternative color space provides reasonable
- % mapping.
- /cs_get_currentgray
- { //get_icc_alternative_space exec //.cs_get_currentgray exec }
- bind
- /cs_get_currentrgb
- { //get_icc_alternative_space exec //.cs_get_currentrgb exec }
- bind
- /cs_get_currentcmyk
- { //get_icc_alternative_space exec //.cs_get_currentcmyk exec }
- bind
-
- % a lot of validation is done by the cs_validate method
- /cs_validate
- {
- //check_cie_cspace exec
- dup 1 get
- dup /N get
- dup type /integertype ne
- //setcspace_typecheck
- if
- //icc_comp_map_dict exch known not
- //setcspace_rangecheck
- if
- dup /DataSource get
- dup type dup /stringtype ne exch /filetype ne and
- //setcspace_typecheck
- if
- rcheck not
- //setcspace_invalidaccess
- if
- dup /Range .knownget
- {
- //check_array exec
- {
- type dup /integertype ne exch /realtype ne and
- //setcspace_typecheck
- if
- }
- forall
- }
- if
- /Alternate .knownget
- {
- //.cs_validate exec
- dup //.cs_potential_icc_alternate exec not
- {
- 0 get /ICCBased ne
- //setcspace_rangecheck
- if
- }
- { pop }
- ifelse
- }
- if
- }
- bind
-
- % substitute the Alternate space, if appropriate
- /cs_substitute
- {
- %
- % A design problem in the Ghostscript graphic library color
- % space code prevents an ICCBased color space from having an
- % ICCBased alternative color space. This situation actually
- % arises fairly frequently in PDF, as an ICCBased color space
- % is used as the substitute color for a Device{Gray|RGB|CMYK}
- % color space, which in turn are used as the alternative color
- % space to another (or possibly even the same) ICCBased color
- % space.
- %
- % This situation causes no fundamental problems, as
- % Ghostscript nominally supports ICCBased color spaces, so the
- % Alternate color space is not used. Where this is not true
- % (primarily because the NOCIE option is selected), the code
- % would (except for the design flaw noted above) select the
- % Alternate of the Alternate color space.
- %
- % The code below works around this problem by suprressing
- % color space substitution for alternative color spaces if
- % the substituting space is an ICCBased color space.
- %
- dup //get_icc_alternative_space exec
- //.cs_substitute exec
- 2 copy eq
- 1 index //.cs_potential_icc_alternate exec not
- or
- { pop pop dup }
- {
- % retain just the new Alternate space
- exch pop
-
- % build all new structures in local VM
- .currentglobal 3 1 roll //false .setglobal
-
- % copy the original ICCBased color space array
- 1 index dup length array copy
-
- % copy the ICCBased dictionary
- dup 1 2 copy get dup length dict copy
-
- % insert the new alterante color space
- dup /Alternate 7 -1 roll put
-
- % insert the new dictionary into the arra
- put
-
- % restore the VM mode
- 3 -1 roll .setglobal
- }
- ifelse
- }
- bind
-
- %
- % The current implementation of ICCBased color spaces requires the
- % DataSource to be a file.
- %
- /cs_prepare
- {
- % make DataSource a file
- dup 1 get /DataSource get type /stringtype eq
- {
- % build all new structures in local VM
- .currentglobal exch //false .setglobal
-
- % check if we need to copy the color space and dictionary
- 2 copy eq
- {
- dup length array copy
- dup 1 2 copy get dup length dict copy put
- }
- if
-
- % fetch DataSource, setting up stack for multiple puts
- dup 1 2 copy get dup /DataSource 2 copy get
-
- % convert the string into a file
- /ReusableStreamDecode filter
-
- % put the file into the dictioary, the dictionary into the array
- put put
-
- % restore the VM mode
- exch .setglobal
- }
- if
- }
- bind
-
- %
- % Install the current color space.
- %
- % The current Ghostscript color space implementation requires that
- % color spaces that provide a base or alternative color space set
- % that base/alternative color space to be the current color space
- % before attempting to set the original color space. This can cause
- % difficulty if an ICCBased color space is being used as a substitute
- % color space for a device-specific color space, and uses that same
- % device-specific color space as an alternative space. For this
- % reason, a special _setcolorspace_nosub operator is provided.
- %
- /cs_install
- {
- % set the alternative color space to be the current color space
- dup //get_icc_alternative_space exec //_setcolorspace_nosub exec
-
- % check for native support
- /.seticcspace where
- { pop //false }
- { //true }
- ifelse
- NOCIE or
- //pop_1 % do nothing
- {
- % Acrobat Reader silently ignores errors with ICC profiles
- % and uses the alternate color space -- do the same.
- mark exch 1 get
- { .seticcspace }
- .internalstopped
- cleartomark
- }
- ifelse
- }
- bind
-
- % for now, the alternative spaces for an ICCBased color space do
- % not require special preparation
- /cs_prepare_color { dup 1 get /N get //check_num_stack exec pop } bind
- /cs_complete_setcolor //pop_1
-
- .dicttomark
-put
-
-end % .cspace_util
-
-NOPSICC { (%END PSICC) .skipeof } if
-% Now set up ICC profile loading for PostScript %%BeginICCProfile sections.
-
-systemdict begin
-/.ProcessICCcomment { % file comment -- file comment
- dup
- (%%BeginICCProfile) anchorsearch {
- pop pop
- DEBUG { (.ProcessICCcomment found %%BeginICCProfile) print flush } if
-
- % load an ICC profile defined as comments (hex encoded).
- % Ends with %%End at the start of a line. Read the data into
- % a bytestring to allow seeking. This string can be used as a
- % seekable ReusableStreamDecode filter source by the ICC logic.
- %
- % Since .bigstring needs to know the size, we first read an array of
- % strings each 64000 max length.
- %
- % stack: --file-- (%%BeginICCProfile: ...)
- 1 index 0 (%%EndICCProfile) /SubFileDecode filter
- [ { counttomark 1 add index
- 64000 string readhexstring
- not { exit } if
- } loop
- ] exch closefile
- 0 1 index { length add } forall
- .bigstring
- exch 0 exch {
- % stack: --file-- (%%BeginICCProfile: ...) --bytestring-- cur_index --string--
- 2 copy length add % calculate next string start point
- 3 1 roll 3 index 3 1 roll putinterval
- } forall
- pop % discard length of bytestring
- % make a seekable -file- out of the bytestring
- mark /AsyncRead true .dicttomark /ReusableStreamDecode filter
- % stack: --file-- (%%BeginICCProfile: ...) --icc_subfile--
- /DeviceCMYK setcolorspace
- << /DataSource 3 -1 roll
- /N 4 % Try CMYK first
- >> { .seticcspace } stopped {
- /DeviceRGB setcolorspace
- dup /N 3 put { .seticcspace } stopped {
- /DeviceGray setcolorspace
- dup /N 1 put { .seticcspace } stopped { % last choice
- QUIET not { ( *** Unable to load ICC profile from PostScript DSC comments ***) = flush } if
- pop
- } if
- } if
- } if
- } {
- pop % Not interested in this DSC comment
- } ifelse
-} bind def
-
-% Merge ProcessICCcomment with existing handler
-/.ProcessICCcomment load /exec load
-currentuserparams /ProcessDSCComment get
-dup null eq {pop {pop pop}} if /exec load
-4 array astore cvx readonly
-<< /ProcessDSCComment 3 -1 roll >> setuserparams
-
-end % systemdict
-%END PSICC
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_il1_e.ps b/Master/tlpkg/tlgs/lib/gs_il1_e.ps deleted file mode 100644 index 3dc2141826c..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_il1_e.ps +++ /dev/null @@ -1,66 +0,0 @@ -% Copyright (C) 1993, 1994, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_il1_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the ISO Latin-1 encoding vector.
-% The first half is the same as the standard encoding,
-% except for minus instead of hyphen at code 055.
-/ISOLatin1Encoding
-StandardEncoding 0 45 getinterval aload pop
- /minus
-StandardEncoding 46 82 getinterval aload pop
-% NOTE: the following are missing in the Adobe documentation,
-% but appear in the displayed table:
-% macron at 0225, dieresis at 0230, cedilla at 0233, space at 0240.
-% This is an error in the Red Book, corrected in Adobe TN 5085.
-% \20x
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /dotlessi /grave /acute /circumflex /tilde /macron /breve /dotaccent
- /dieresis /.notdef /ring /cedilla /.notdef /hungarumlaut /ogonek /caron
-% \24x
- /space /exclamdown /cent /sterling
- /currency /yen /brokenbar /section
- /dieresis /copyright /ordfeminine /guillemotleft
- /logicalnot /hyphen /registered /macron
- /degree /plusminus /twosuperior /threesuperior
- /acute /mu /paragraph /periodcentered
- /cedilla /onesuperior /ordmasculine /guillemotright
- /onequarter /onehalf /threequarters /questiondown
-% \30x
- /Agrave /Aacute /Acircumflex /Atilde
- /Adieresis /Aring /AE /Ccedilla
- /Egrave /Eacute /Ecircumflex /Edieresis
- /Igrave /Iacute /Icircumflex /Idieresis
- /Eth /Ntilde /Ograve /Oacute
- /Ocircumflex /Otilde /Odieresis /multiply
- /Oslash /Ugrave /Uacute /Ucircumflex
- /Udieresis /Yacute /Thorn /germandbls
-% \34x
- /agrave /aacute /acircumflex /atilde
- /adieresis /aring /ae /ccedilla
- /egrave /eacute /ecircumflex /edieresis
- /igrave /iacute /icircumflex /idieresis
- /eth /ntilde /ograve /oacute
- /ocircumflex /otilde /odieresis /divide
- /oslash /ugrave /uacute /ucircumflex
- /udieresis /yacute /thorn /ydieresis
-% Make an array on large systems, a packed array on small ones.
-256
-vmstatus exch pop exch pop
-100000 ge { array astore readonly } { packedarray } ifelse
-def
-1 ISOLatin1Encoding .registerencoding
-/ISOLatin1Encoding ISOLatin1Encoding .defineencoding
diff --git a/Master/tlpkg/tlgs/lib/gs_il2_e.ps b/Master/tlpkg/tlgs/lib/gs_il2_e.ps deleted file mode 100644 index 0b152f23af3..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_il2_e.ps +++ /dev/null @@ -1,63 +0,0 @@ -% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_il2_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the ISO Latin-2 (8859-2) encoding vector.
-
-% The original version of this encoding vector used Unicode names, rather
-% than Adobe names, for many characters. Here are the names that appeared
-% in the original version:
-% \047 /quoteright /apostrophe
-% \056 /period /fullstop
-% \137 /underscore /lowline
-% \140 /quoteleft /grave
-% \055 is /hyphen in StandardEncoding, but /minus in 8859-1; we follow
-% 8859-1 here. In addition, the following substitutions were made:
-% /Lstroke => /Lslash
-% /Dstroke => /Dcroat
-% /*diaeresis => /*dieresis
-% /softhyphen => /hyphen
-% /*abovedot => /*dotaccent
-% /*doubleacute => /*hungarumlaut
-% /division => /divide
-% /ssharp => /germandbls
-
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/ISOLatin2Encoding
-% The first 144 entries are the same as the ISO Latin-1 encoding.
-ISOLatin1Encoding 0 144 getinterval aload pop
-% \22x
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-% \24x
- /nbspace /Aogonek /breve /Lslash /currency /Lcaron /Sacute /section
- /dieresis /Scaron /Scedilla /Tcaron /Zacute /hyphen /Zcaron /Zdotaccent
- /degree /aogonek /ogonek /lslash /acute /lcaron /sacute /caron
- /cedilla /scaron /scedilla /tcaron /zacute /hungarumlaut /zcaron /zdotaccent
-% \30x
- /Racute /Aacute /Acircumflex /Abreve /Adieresis /Lacute /Cacute /Ccedilla
- /Ccaron /Eacute /Eogonek /Edieresis /Ecaron /Iacute /Icircumflex /Dcaron
- /Dcroat /Nacute /Ncaron /Oacute /Ocircumflex /Ohungarumlaut /Odieresis /multiply
- /Rcaron /Uring /Uacute /Uhungarumlaut /Udieresis /Yacute /Tcedilla /germandbls
-% \34x
- /racute /aacute /acircumflex /abreve /adieresis /lacute /cacute /ccedilla
- /ccaron /eacute /eogonek /edieresis /ecaron /iacute /icircumflex /dcaron
- /dcroat /nacute /ncaron /oacute /ocircumflex /ohungarumlaut /odieresis /divide
- /rcaron /uring /uacute /uhungarumlaut /udieresis /yacute /tcedilla /dotaccent
-256 packedarray .defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_img.ps b/Master/tlpkg/tlgs/lib/gs_img.ps deleted file mode 100644 index a8a8bf774d5..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_img.ps +++ /dev/null @@ -1,858 +0,0 @@ -% (C) 2002 Artifex, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_img.ps 8242 2007-09-18 15:41:08Z leonardo $
-% image, colorimage, and imagemask implementation
-
-%
-% The design of the overprint facility in Ghostscript requires that color
-% specifications include the color space from which they were expressed,
-% even after conversion to the device color model. Directly including this
-% information in color specifications is usually not efficient, and is
-% difficult to integrate into the existing code structure. The alternative
-% approach taken is to extend a state mechanism through the device
-% interface, and make the current color space, or more specifically,
-% certain information about the current color space, a property of this
-% state.
-%
-% For such a mechanism to work, it is necessary to identify all changes
-% to the current color space. This is accomplished in the graphic library
-% by funneling all changes to the current color space through the
-% gs_setcolorspace procedure. At the PostScript interpreter level, this
-% result is achieved by forcing color space changes through the
-% setcolorspace operator.
-%
-% Aside from explicit use of setcolorspace, PostScript provides a few
-% implicit methods of changing the current color space. The setgray,
-% setrgbcolor, and setcmykcolor operators implicitly set the color space
-% while explicitly setting the current color. Similarly, the colorimage
-% operator and the traditional form of the image operator (5 operands)
-% both temporarily modify the current color space while an image is
-% being processed. The current file is concerned with the implementation
-% of these two operators. In addition, the traditional form of the
-% imagemask operator (5 operands), while it does not affect the current
-% color space, is closely related to the image operator and thus is
-% implemented in this file as well.
-%
-% In this implementation, all sampled objects are passed through one of
-% the internal operators .image1, .imagemask1, .image1alpha, .image2,
-% .image3, or .image4, each of which handles a specific ImageType value.
-%
-% The procedures in this file are responsible for constructing
-% image dictionaries from a set of stack entries. This is, in principle,
-% a trivial exercise. In practice it appears to be far more complex,
-% primarily due to the need to reconstruct the original state in the
-% event of an error. This is a particular problem for operators such as
-% image, which include data source objects that may, directly or
-% indirectly, be procedures. When these procedures are executed, the
-% image operator's operands must have been cleared from the operand
-% stack. Hence, the operand stack cannot be used to store state
-% information. Similarly, the dictionary stack also cannot be used to
-% store state information, as the data source procedures may depend on
-% a particular dictionary being on the top of this stack.
-%
-% Adobe's PostScript implementations determine the extent to which the
-% interpreter state is restored in the event of an error by the point at
-% which the error is detected. Errors in the image/colorimage/imagemask
-% operators that are detected before the data source procedures are
-% executed restore the state in effect before the image was processed.
-% Those that are detected as part of running the data source procedures
-% only attempt to restore the state to that in effect at the start of
-% the operator that failed (or at the conclusion of the data source
-% procedure, if this procedure failed to push a string).
-%
-% The implementation given here follows the Adobe convention. The
-% mechanism used is as follows:
-%
-% 1. Check that the stack has a sufficient number of operands, and
-% that enough of them have the proper type to allow construction
-% of the image dictionary. Any errors at this point are handled
-% in the conventional manner.
-%
-% 2. Build the image dictionary, in the process clearing the image/
-% colorimage/imagemask operands from the stack. No errors can
-% occur during this process.
-%
-% (Special precautions could be taken during this step to handle
-% a limitcheck or VMError during the building of the image
-% dictionary, but this essentially never occurs in practice and, if
-% it did, is very unlikely to leave a useable state. Hence, we don't
-% bother with this possibility.)
-%
-% 3. The .image operator is executed in a stopped context. If it
-% returns abnormally, a check is made to see if the uppermost
-% operand on the stack is a color image dictionary. If so, the
-% original stack is created anew using this dictionary. (Because
-% the image operand works via colorimage, some additional special
-% handling is required in this case.)
-%
-
-
-%
-% Create a dictionary of operators for specific image and image mask types.
-% Each of these will always handle ImageType 1. Additional types are added
-% as they are supported in specific interpreter levels or versions.
-%
-% These dictionaries are in systemdict for historical reasons.
-%
-.currentglobal true .setglobal
-systemdict begin
-/.imagetypes
- 5 dict
- dup 1 /.image1 load put
-def
-/.imagemasktypes
- 5 dict
- dup 1 /.imagemask1 load put
-def
-end
-.setglobal
-
-%
-% Build a dictionary of utility procedures and constants for use in
-% impelementing the image operators. This dictionary is in global VM but
-% is maintained (during initialization) in userdict. It should be pushed
-% onto the dictionary stack when constructing image-related procedures
-% and pseudo-operators.
-%
-% This dictionary is removed from userdict when initialization is
-% completed.
-%
-.currentglobal true .setglobal
-userdict /img_utils_dict 30 dict put
-img_utils_dict begin
-
-
-%
-% Some useful local data structures:
-%
-% img_csary maps the number of components in an image to the implied
-% color space.
-%
-% img_decary is a prototype Decode array; subintervals of this array
-% may be used for fewer than 4 color components.
-%
-% img_params_ary is a list of the parameters to be built in the image
-% dictionary for a colorimage invocation. ImageType is given a
-% fixed value; the other parameters are in stack order (IMG_NComps
-% is the number of components).
-%
-% img_mask_params_ary is the equivalent of img_params_ary for imagemask
-% invocations. Polarity is a proxy for Decode, and is replaced
-% by the Decode key in the image dictionary.
-%
-% img_mask_check_ary is the set of parameters that must be present in
-% an image dictionary generated by an imagemask invocation. This
-% differs from img_mask_params_ary in that Decode replaces Polarity.
-%
-/img_csary [ null /DeviceGray null /DeviceRGB /DeviceCMYK ] def
-/img_decary [ 0 1 0 1 0 1 0 1 ] def
-
-/img_params_ary
- [
- /ImageType /IMG_NComps /MultipleDataSources /DataSource
- /ImageMatrix /BitsPerComponent /Height /Width /Decode
- ]
-def
-/img_check_ary //img_params_ary def
-/img_unbuild_ary
- //img_params_ary 1 1 index length 2 sub getinterval
-def
-
-/img_mask_params_ary
- [ /ImageType /DataSource /ImageMatrix /Polarity /Height /Width ]
-def
-/img_mask_check_ary
- [
- /ImageType /BitsPerComponent
- /DataSource /ImageMatrix /Decode /Height /Width
- ]
-def
-/img_mask_unbuild_ary
- //img_mask_check_ary 2 1 index length 2 sub getinterval
-def
-
-
-%
-% <?any?> <array> img_check_keys <?any?> <bool>
-%
-% Verify that:
-% that there are at least two entries on the stack, and
-% the second (lower) entry is a dictionary, and
-% that dictionary contains all of the keys in the array
-%
-% If any one of these conditions does not hold, pop the array and push
-% false; otherwise pop the array and push true. This utility is used by
-% the colorimage and imagematrix procedures to determine if .image left
-% the image dictionary on the stack after an abnormal return.
-%
-/img_check_keys
- {
- count 2 ge
- {
- 1 index type /dicttype eq
- {
- true exch
- {
- 2 index exch known and
- dup not
- { exit }
- if
- }
- forall
- }
- { pop //false }
- ifelse
- }
- { pop //false }
- ifelse
- }
-.bind def
-
-%
-% Procedures to convert a set of stack entries to a dictionary. There is
-% a procedure associated with each key, though most keys use the same
-% procedure. The dictionary to be built is at the top of the dictionary
-% stack. Stack handling for the procedures is:
-%
-% <?val0?> ... <?val(n - 1)?> <key> proc -
-%
-% Parameters are handle in inverse-stack order, so inter-parameter
-% dependencies that on the stack can generally be used here.
-%
-/img_params_dict
- mark
- /ImageType { 1 def } .bind
-
- /IMG_NComps { exch def } .bind % number of components
- /MultipleDataSources 1 index
- /Width 1 index
- /Height 1 index
- /ImageMatrix 1 index
- /BitsPerComponent 1 index
- /DataSource 1 index
-
- % Polarity is a proxy for Decode; it never appears in a dictionary
- /Polarity
- {
- pop
- { { 1 0 } }
- { { 0 1 } }
- ifelse
- /Decode exch cvlit def
- }
- .bind
-
- % the definition of Decode is based on the number of components
- /Decode { //img_decary 0 IMG_NComps 2 mul getinterval def } .bind
- .dicttomark
-def
-
-%
-% <oper_0> ... <oper_n> <array> img_build_dict <dict>
-%
-% Build a dictionary. This will always be done in local VM. The array is
-% a list of the keys to be associated with operands on the stack, in
-% inverse stack order (topmost element first). The caller should verify
-% that the dictionary can be built successfully (except for a possible
-% VMerror) before calling this routine.
-%
-/img_build_dict
- {
- % build the dictionary in local VM; all for 2 extra entries
- .currentglobal false .setglobal
- 1 index length 2 add dict
- exch .setglobal
- begin
-
- % process all keys in the array
- { //img_params_dict 1 index get exec }
- forall
-
- % if BitsPerComponent is not yet defined, define it to be 1
- currentdict /BitsPerComponent known not
- { /BitsPerComponent 1 def }
- if
-
- currentdict end
- }
-.bind def
-
-%
-% <dict> <array> img_unbuild_dict <oper_0> ... <oper_n>
-%
-% "Unbuild" a dictionary: spread the contents the dictionary back onto the
-% stack, in the inverse of the order indicated in the array (inverse is
-% used as this order is more convenient for img_build_dict, which is
-% expected to be invoked far more frequently).
-%
-/img_unbuild_dict
- {
- exch begin
- dup length 1 sub -1 0
- { 1 index exch get load exch }
- for
- pop
- end
- }
-.bind def
-
-%
-% Check the image types that can be used as data sources
-% <any> foo <bool>
-%
-/good_image_types mark
- /filetype { pop //true } .bind
- /stringtype 1 index
- /arraytype //xcheck
- /packedarraytype //xcheck
-.dicttomark readonly def
-
-%
-% <width> <height> <bits/component> <matrix> <dsrc0> ...
-% <multi> <ncomp> <has_alpha>
-% img_build_image_dict
-% <dict> <has_alpha>
-%
-% Build the dictionary corresponding to a colorimage operand stack. This
-% routine will check just enough of the stack to verify that the
-% dictionary can be built, and will generate the appropriate error if this
-% is not the case.
-%
-% The <has_alpha> boolean is used to support the Next alphaimage extension.
-%
-% At the first level, errors in this procedure are reported as colorimage
-% errors. The error actually reported will usually be determined by the
-% pseudo-operator which invokes this routine.
-%
-/img_build_image_dict
- {
- % Veify that at least 8 operands are available, and that the top three
- % operands have the expected types
- count 8 lt
- { /.colorimage cvx /stackunderflow signalerror }
- if
- 3 copy
- type /booleantype ne exch
- type /integertype ne or exch
- type /booleantype ne or
- { /.colorimage cvx /typecheck signalerror }
- if
-
- % verify that the number of components is 1, 3, or 4
- 1 index 1 lt 2 index 2 eq or 2 index 4 gt or
- { /.colorimage cvx /rangecheck signalerror }
- if
-
- % Verify that the required number of operands are present if multiple
- % data sources are being used. If this test is successful, convert
- % the data sources to an array (in local VM).
- 2 index
- {
- % if an alpha component is present, this adds one more component
- 2 copy
- { 1 add }
- if
- dup count 9 sub gt
- {
- % Adobe interpreters appear to test the arguments sequentially
- % starting from the top of the stack and report the 1st error found.
- % To satisfy CET test 12-02.PS we emulate this logic.
- //true exch -1 1
- { 3 add index
- //good_image_types 1 index type .knownget
- { exec and
- }
- { pop pop //false
- }
- ifelse
- }
- for
- { /stackunderflow
- }
- { /typecheck
- }
- ifelse
- /.colorimage cvx exch signalerror
- }
- if
-
- % build the DataSource array in local VM
- dup .currentglobal false .setglobal exch array exch .setglobal
-
- % stack: <w> <h> <bps> <mtx> <d0> ... <multi> <n> <alpha> <n'> <array>
- 5 1 roll 4 add 3 roll astore 4 1 roll
- }
- if
-
- % the image dictionary can be built; do so
- % stack: <w> <h> <bps> <mtx> <dsrc|dsrc_array> <multi> <n> <alpha>
- 8 1 roll //img_params_ary //img_build_dict exec exch
- }
-.bind def
-currentdict /good_image_types .undef
-
-%
-% <?dict?>
-% img_unbuild_image_dict
-% <width> <height> <bits/component> <matrix> <dsrc0> ...
-% <multi> <ncomp>
-%
-% If the top entry of the stack is a dictionary that has the keys required
-% by a colorimage dictionary, unpack that dictionary onto the stack.
-% Otherwise just leave things as they are. Note that the <has_alpha>
-% parameter is not pushd onto the stack.
-%
-/img_unbuild_image_dict
- {
- //img_check_ary //img_check_keys exec
- {
- //img_unbuild_ary //img_unbuild_dict exec
- 1 index type /booleantype eq
- {
- 1 index
- { 3 -1 roll aload length 2 add -2 roll }
- if
- }
- if
- }
- if
- }
-.bind def
-
-
-%
-% <width> <height> <polarity> <matrix> <dsrc>
-% img_unbuild_imagemask_dict
-% <dict>
-%
-% Build the dictionary corresponding to an imagemask stack. This routine
-% will verify that the appropriate number of operands are on the stack,
-% and that polarity is a boolean. This is all that is necessary to build
-% the dictionary.
-%
-/img_build_imagemask_dict
- {
- % check for proper number of operands
- count 5 lt
- { /imagemask .systemvar /stackunderflow signalerror }
- if
-
- % verify that polarity is a boolean
- 2 index type /booleantype ne
- { /imagemask .systemvar /typecheck signalerror }
- if
-
- % the imagemask dictionary can be built; do so
- //img_mask_params_ary //img_build_dict exec
- }
-.bind def
-
-%
-% <?dict?>
-% img_unbuild_imagemask_dict
-% <width> <height> <polarity> <matrix> <dsrc>
-%
-% If the top entry of the stack is a dictionary that has the keys rquired
-% by an imagemask dictionary, unpack that dictionary onto the stack.
-% Otherwise just leave things as they are.
-%
-/img_unbuild_imagemask_dict
- {
- //img_mask_check_ary //img_check_keys exec
- {
- //img_mask_unbuild_ary //img_unbuild_dict exec
- 3 -1 roll
- dup type dup /arraytype eq exch /packedarraytype eq or
- 1 index rcheck and
- { 0 get 1 eq }
- if
- 3 1 roll
- }
- if
- }
-.bind def
-
-
-%
-% <width> <height> <bits/component> <matrix> <dsrc_0> ...
-% <multi> <ncomp> <has_alpha>
-% .colorimage
-% -
-%
-% Convert the image/colorimage operator from their traditional form to
-% the dictionary form. The <has_alpha> operand is used ot support the
-% Next alphaimage extension.
-%
-% Error handling for these operators is a bit complex, due to the stack
-% handling required of operators that potentially invoke procedures.
-% This problem is discussed in the comment above. The facts relevant to
-% this particular implementation are:
-%
-% 1. The .image1 (or .alphaimage) operator is executed in a stopped
-% context, so that we can undo the gsave context in the event of
-% an error.
-%
-% 2. In the event of an error, the stack is examined to see if the
-% dictionary passed to .image1 (.alphaimage) is still present.
-% If so, this dictionary is "unpacked" onto the stack to re-
-% create the original stack. The <has_alpha> parameter is not
-% pushed onto the stack, as it is not required for any of the
-% pseudo-operators than invoke this procedure.
-%
-% 3. The use of pseudo-operators in this case may yield incorrect
-% results for late-detected errors, as the stack depth will be
-% restored (even though the stack is not). This is, however, no
-% worse than the prior (level >= 2) code, so it should cause no
-% new problems.
-%
-/.colorimage
- {
- % build the image dictionary
- //img_build_image_dict exec
-
- % execute .image1 in a stopped context
- {
- gsave
- % The CET test file 12-02.ps creates colorimages with a width and
- % height of 0. Ignore these since that is what the CET expects.
- 1 index dup /Height get 0 eq exch /Width get 0 eq or
- { pop pop } % Ignore colorimage. Pop bool and dict
- {
- 0 .setoverprintmode % disable overprint mode for images
- //img_csary 2 index /IMG_NComps get get setcolorspace
- { .alphaimage }
- { .image1 }
- ifelse
- }
- ifelse
- }
- stopped
- grestore
- {
- //img_unbuild_image_dict exec
- /.colorimage cvx $error /errorname get
- signalerror
- }
- if
- }
-.bind def
-
-
-%
-% <width> <height> <bits/component> <matrix> <dsrc_0> ...
-% <multi> <ncomp>
-% colorimage
-% -
-%
-% Build the colorimage pseudo-operator only if setcolorscreen is visible.
-%
-systemdict /setcolorscreen .knownget
- {
- type /operatortype eq
- {
- /colorimage
- {
- //false
- //.colorimage
- stopped
- { /colorimage .systemvar $error /errorname get signalerror }
- if
- }
- .bind systemdict begin odef end
- }
- if
- }
-if
-
-
-%
-% width height bits_per_component matrix data_src image -
-%
-% <dict> image -
-%
-% Some special handling is required for ImageType 2 (Display PostScript
-% pixmap images) so as to set the appropriate color space as the current
-% color space.
-%
-/image
- {
- dup type /dicttype eq .languagelevel 2 ge and
- {
- dup /ImageType get dup 2 eq
- {
- % verify the ImageType 2 is supported
- //.imagetypes exch known
- {
- %
- % Set either DevicePixel or DeviceRGB as the current
- % color space. DevicePixel is used if the image data is
- % to be copied directly, with only a geometric
- % transformation (PixelCopy true). The use of DeviceRGB
- % in the alternate case is not, in general, correct, and
- % reflects a current implementation limitation. Ideally,
- % an intermediate color space should be used only if
- % the source and destination color models vary; otherwise
- % the native color space corresponding to the color model
- % should be used.
- %
- % The mechanism to determine depth for the DevicePixel
- % color space when BitsPerPixel is not available is
- % somewhat of a hack.
- %
- gsave
- 0 .setoverprintmode % disable overprintmode for images
- dup /PixelCopy .knownget dup
- { pop }
- if
- {
- [
- /DevicePixel
- currentpagedevice dup /BitsPerPixel .knownget
- { exch pop }
- {
- /GrayValues .knownget not
- { 2 } % try a guess
- if
- ln 2 ln div round cvi
- }
- ifelse
- ]
- }
- { /DeviceRGB }
- ifelse
- setcolorspace
- //.imagetypes 2 get
- stopped
- grestore
- { /image .systemvar $error /errorname get signalerror }
- if
- }
- { /image .systemvar /rangecheck signalerror
- }
- ifelse
- }
- {
- dup //.imagetypes exch .knownget
- {
- exch pop gsave
- 0 .setoverprintmode % disable overprintmode for images
- stopped
- grestore
- { /image .systemvar $error /errorname get signalerror }
- if
- }
- {
- /image .systemvar exch type /integertype eq
- { /rangecheck } { /typecheck }
- ifelse signalerror
- }
- ifelse
- }
- ifelse
- }
- {
- //false 1 //false
- //.colorimage
- stopped
- { /image .systemvar $error /errorname get signalerror }
- if
- }
- ifelse
- }
-.bind systemdict begin odef end
-
-% An auxiliary function for checking whether an imagemask to be interpolated.
-/.is_low_resolution % <image dict> .is_low_resolution <bool>
-{ % Checking whether image pixel maps to more than 2 device pixels.
- % The threshold 2 is arbitrary.
- 1 exch 0 exch
- 0 exch 1 exch
- /ImageMatrix get dup
- 2 {
- 4 1 roll
- idtransform dtransform dup mul exch dup mul add sqrt
- } repeat
- max
- 2 gt % arbitrary
-} .bind def
-
-
-%
-% width height polarity matrix datasrc imagemask -
-%
-% See the comment preceding the definition of .colorimage for information
-% as to the handling of error conditions.
-%
-/imagemask
- {
- dup type /dicttype eq .languagelevel 2 ge and
- { dup /ImageType get
- //.imagemasktypes exch .knownget
- { 1 index //.is_low_resolution exec
- 2 index /ImageType get 1 eq and
- 2 index /BitsPerComponent get 1 eq and
- 2 index /Interpolate .knownget not { false } if and
- //filterdict /ImscaleDecode known and {
- % Apply interpolated imagemask scaling filter
- exch dup length dict .copydict
- dup dup /DataSource get
- mark /Width 3 index /Width get /Height 5 index /Height get .dicttomark
- /ImscaleDecode filter /DataSource exch put
- dup dup /Width get 4 mul /Width exch put
- dup dup /Height get 4 mul /Height exch put
- dup dup /ImageMatrix get
- 4 4 matrix scale matrix concatmatrix /ImageMatrix exch put
- exch
- } if
- exec
- }
- { % CET 12-08b.ps wants /typecheck
- /imagemask .systemvar /typecheck signalerror
- }
- ifelse
- }
- {
- //img_build_imagemask_dict exec
- { .imagemask1 }
- stopped
- {
- //img_unbuild_imagemask_dict exec
- /imagemask .systemvar $error /errorname get signalerror
- }
- if
- }
- ifelse
- }
-.bind systemdict begin odef end
-
-end % img_utils_dict
-
-% Conditionally turn image interpolation on or off.
-% INTERPOLATE is not yet set, handle all cases
-currentdict /INTERPOLATE known
-currentdict /DOTERPOLATE known or
-currentdict /NOTERPOLATE known or not {
- currentfile 1 (%END INTERPOLATE) .subfiledecode flushfile
-} if
-
-/.interpolate {
- dup /Interpolate .knownget not { //false } if
- /INTERPOLATE .systemvar ne {
- dup gcheck .currentglobal exch .setglobal
- exch dup length dict copy
- dup /Interpolate /INTERPOLATE .systemvar put
- exch .setglobal
- } if
-} .bind odef
-
-/colorimage
- { /INTERPOLATE .systemvar
- { .currentglobal % w h bit [] {}...{} multi ncomp glob
- //false .setglobal
- 9 dict begin % w h bit [] {}...{} multi ncomp glob
- 2 .argindex { 1 index 7 add } { 8 } ifelse
- dup .argindex pop % check # of arguments
- copy gsave pop % preserve the arguments
- { 0 /DeviceGray 0 /DeviceRGB /DeviceCMYK }
- 1 index get setcolorspace % ... glob w h bit [] {}...{} multi ncomp
- {0 1 0 1 0 1 0 1}
- 1 index 2 mul 0 exch % ... glob w h bit [] {}...{} multi ncomp {0 1 ...} 0 2*ncomp
- getinterval /Decode exch def % ... glob w h bit [] {}...{} multi ncomp
- exch dup % ... glob w h bit [] {}...{} ncomp multi multi
- /MultipleDataSources exch def % ... glob w h bit [] {}...{} ncomp multi
- { array astore} { pop } ifelse % ... glob w h bit [] [{}...{}]
- /DataSource exch def % ... glob w h bit []
- /ImageMatrix exch def % ... glob w h bit
- /BitsPerComponent exch def % ... glob w h
- /Height exch def % ... glob w
- /Width exch def % ... glob
- /ImageType 1 def
- /Interpolate //true def
- .setglobal currentdict end % ... <<>>
- image grestore
- exch { 4 add } { 6 } ifelse
- { pop } repeat % -
- }
- { colorimage
- }
- ifelse
- } .bind odef
-
-/image
- { dup type /dicttype eq
- { dup /ImageType get 3 eq
- { .currentglobal //false .setglobal exch
- dup length dict copy begin .setglobal
- /DataDict DataDict .interpolate def
- /MaskDict MaskDict .interpolate def
- currentdict end
- }
- { .interpolate
- }
- ifelse
- image
- }
- { /INTERPOLATE .systemvar
- { 4 .argindex pop % check # of args
- .currentglobal //false .setglobal
- 8 dict begin .setglobal
- /ImageType 1 def
- /DataSource 1 index def
- /ImageMatrix 2 index def
- /BitsPerComponent 3 index def
- /Decode {0 1} def
- /Height 4 index def
- /Width 5 index def
- /Interpolate //true def
- currentdict end
- gsave /DeviceGray setcolorspace image grestore
- 5 { pop } repeat
- }
- { image
- }
- ifelse
- }
- ifelse
- } .bind odef
-
-/imagemask {
- dup type /dicttype eq {
- .interpolate imagemask
- } {
- /INTERPOLATE .systemvar {
- 4 .argindex pop % check # of args
- .currentglobal //false .setglobal
- 8 dict begin .setglobal
- /ImageType 1 def
- /DataSource 1 index def
- /ImageMatrix 2 index def
- /BitsPerComponent 1 def
- 2 index { {1 0} } { {0 1} } ifelse /Decode exch def
- /Height 4 index def
- /Width 5 index def
- /Interpolate //true def
- currentdict end imagemask 5 { pop } repeat
- } {
- imagemask
- } ifelse
- } ifelse
-} .bind odef
-
-currentdict /.interpolate .undef
-
-%END INTERPOLATE
-
-.setglobal % restore VM mode
diff --git a/Master/tlpkg/tlgs/lib/gs_indxd.ps b/Master/tlpkg/tlgs/lib/gs_indxd.ps deleted file mode 100644 index f58e552d0a8..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_indxd.ps +++ /dev/null @@ -1,205 +0,0 @@ -% Copyright (C) 2001, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_indxd.ps 7162 2006-11-04 17:05:22Z alexcher $
-% Indexed color space method dictionary
-
-
-% verify that Indexed color spaces are supported
-/.setindexedspace where
- { pop }
- { currentfile closefile }
-ifelse
-
-.currentglobal true .setglobal
-.cspace_util begin
-
-%
-% <num> <array> restrict_index <int> <array>
-%
-% Restrict the operand to setcolor for an Indexed color space to be an
-% integer in the applicable range.
-%
-/restrict_index
- {
- exch round cvi
- dup 0 lt
- { pop 0 }
- {
- 1 index 2 get 2 copy gt
- { exch }
- if
- pop
- }
- ifelse
- exch
- }
-bind def
-
-%
-% <num> <array> get_indexed_base_color <c1> ... <cn> <array>
-%
-% Get the base color corresponding to an indexed color value.
-%
-/get_indexed_base_color
- {
- % just in case, set the index into the appropriate range
- //restrict_index exec
-
- % lookup in the string or use the lookup proc
- mark 1 index 3 get dup type /stringtype eq
- {
- 2 index 1 get //.cs_get_ncomps exec dup 6 -1 roll mul exch getinterval
- { 255 div }
- forall
- }
- { 4 -1 roll exch exec }
- ifelse
- counttomark 2 add -2 roll pop
- }
-bind def
-
-
-colorspacedict
-/Indexed
- mark
- /cs_potential_indexed_base false
- /cs_potential_pattern_base true
- /cs_potential_alternate false
- /cs_potential_icc_alternate false
- /cs_get_ncomps //ncomps_1
- /cs_get_range { 0 exch 2 get 2 array astore } bind
- /cs_get_default_color { pop 0 } bind
-
- /cs_get_currentgray
- { //get_indexed_base_color exec 1 get //.cs_get_currentgray exec }
- bind
- /cs_get_currentrgb
- { //get_indexed_base_color exec 1 get //.cs_get_currentrgb exec }
- bind
- /cs_get_currentcmyk
- { //get_indexed_base_color exec 1 get //.cs_get_currentcmyk exec }
- bind
-
- % a lot of validation is done by the cs_validate method
- /cs_validate
- {
- //check_array exec
- dup 1 get //.cs_validate exec //.cs_potential_indexed_base exec not
- //setcspace_rangecheck
- if
- dup 2 get dup type /integertype ne
- //setcspace_typecheck
- {
- dup 0 lt exch 4095 gt or
- //setcspace_rangecheck
- if
- }
- ifelse
- dup 3 get dup type /stringtype eq
- {
- length
- 1 index dup 2 get 1 add exch 1 get //.cs_get_ncomps exec mul
- lt
- //setcspace_rangecheck
- if
- }
- {
- //check_array exec xcheck not
- //setcspace_typecheck
- if
- }
- ifelse
- }
- bind
-
- % substitute the base space if appropriate
- /cs_substitute
- {
- dup 1 get //.cs_substitute exec 2 copy eq
- { pop pop dup }
- {
- % retain only the new base space
- exch pop
-
- % build all new structures in local VM
- .currentglobal 3 1 roll //false .setglobal
-
- % construct a new array and insert the new base color space
- 1 index dup length array copy dup 1 4 -1 roll put
-
- % restore VM mode
- 3 -1 roll .setglobal
- }
- ifelse
- }
- bind
-
- /cs_prepare {}
-
- %
- % Install the current color space. Note that the alternative color
- % space will already have been set as the current color space.
- %
- % The current Ghostscript color space implementation requires that
- % color spaces that provide a base or alternative color space set
- % that base/alternative color space to be the current color space
- % before attempting to set the original color space.
- %
- /cs_install
- {
- % save the current color space
- currentcolorspace
-
- % set the base color space as the current color space
- 1 index 1 get //forcesetcolorspace
-
- % set the indexed color space; restore the earlier space on error
- mark 2 index
- { .setindexedspace }
- stopped
- { cleartomark setcolorspace stop }
- { pop pop pop }
- ifelse
- }
- bind
-
- % Adobe implementations accept floating point values
- /cs_prepare_color { //validate_1 exec cvi } bind
-
- %
- % Adobe implementations always execute a lookup procedure when setcolor
- % is invoked. Ghostscript samples the lookup procedure when
- % setcolorspace is invoked, and then does not access it again. In the
- % unlikely event that an application depends on the Adobe-specific
- % behavior, it is replicated in this method.
- %
- /cs_complete_setcolor
- {
- 3 get dup type /stringtype eq
- { pop }
- {
- currentcolor exch exec
- currentcolorspace 1 get //clear_setcolor_operands exec
- }
- ifelse
- }
- bind
-
- .dicttomark
-put
-
-end % .cspace_util
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_init.ps b/Master/tlpkg/tlgs/lib/gs_init.ps deleted file mode 100644 index 7a80d35ed51..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_init.ps +++ /dev/null @@ -1,2191 +0,0 @@ -% Copyright (C) 1989-2004 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_init.ps 8401 2007-11-21 22:42:03Z giles $
-% Initialization file for the interpreter.
-% When this is run, systemdict is still writable.
-
-% Comment lines of the form
-% %% Replace <n> <file(s)>
-% indicate places where the next <n> lines should be replaced by
-% the contents of <file(s)>, when creating a single merged init file.
-
-% The interpreter can call out to PostScript code. All procedures
-% called in this way, and no other procedures defined in these
-% initialization files, have names that begin with %, e.g.,
-% (%Type1BuildChar) cvn.
-
-% Interpreter library version number
-% NOTE: the interpreter code requires that the first non-comment token
-% in this file be an integer, and that it match the compiled-in version!
-862
-
-% Check the interpreter revision.
-dup revision ne
- { (gs: Interpreter revision \() print revision 10 string cvs print
- (\) does not match gs_init.ps revision \() print 10 string cvs print
- (\).\n) print flush //null 1 .quit
- }
-if pop
-
-% Acquire userdict, and set its length if necessary.
-/userdict where
- { pop userdict maxlength 0 eq }
- { true }
-ifelse
-systemdict exch
- { % userdict wasn't already set up by iinit.c.
- dup /userdict
- currentdict dup 200 .setmaxlength % userdict
- .forceput % userdict is local, systemdict is global
- }
-if begin
-
-% Define dummy local/global operators if needed.
-systemdict /.setglobal known
- { true .setglobal
- }
- { /.setglobal { pop } bind def
- /.currentglobal { false } bind def
- /.gcheck { pop false } bind def
- }
-ifelse
-
-% Define .languagelevel if needed.
-systemdict /.languagelevel known not { /.languagelevel 1 def } if
-
-% Optionally choose a default paper size other than U.S. letter.
-% The default page size for many devices is set at compile time to
-% letter, but this can be changed to A4 although this is rarely done.
-% Some devices such as bbox have a different default page size,
-% and should not be set to A4 or letter.
-% When ghostscript is used in countries that use the international
-% standard page size A4 rather than US letter, the page size of
-% devices that default to letter or A4 can be changed by setting
-% DEFAULTPAPERSIZE.
-% /DEFAULTPAPERSIZE (a4) def
-
-% Turn on array packing for the rest of initialization.
-true setpacking
-
-% Define the old MS-DOS EOF character as a no-op.
-% This is a hack to get around the absurd habit of MS-DOS editors
-% of adding an EOF character at the end of the file.
-<1a> cvn { } def
-
-% Acquire the debugging flags.
-currentdict /DEBUG known /DEBUG exch def
-
-% if DEBUG is set, set ALL of the subset debugging flags
-mark % '[' isn't defined yet
- /CCFONTDEBUG % Compiled Fonts
- /CFFDEBUG % CFF Fonts
- /CMAPDEBUG % CMAP
- /DOCIEDEBUG % CIE color
- /EPSDEBUG % EPS handling
- /FAPIDEBUG % Font API
- /INITDEBUG % Initialization
- /PDFDEBUG % PDF Interpreter
- /PDFOPTDEBUG % PDF Optimizer (Linearizer)
- /PDFWRDEBUG % PDF Writer
- /SETPDDEBUG % setpagedevice
- /TTFDEBUG % TTF Fonts
- /VGIFDEBUG % ViewGIF
- /VJPGDEBUG % ViewJPEG
- /RESMPDEBUG % Resource map
-counttomark array astore exch pop % ']' isn't defined yet
-{ dup currentdict exch known DEBUG or def } forall
-
-currentdict /PDFSTEP known /PDFSTEP exch def
-% if PDFSTEP is on, turn on PDFDEBUG
-PDFSTEP { /PDFDEBUG true def } if
-
- /VMDEBUG
- INITDEBUG {{print mark
- systemdict /level2dict known
- { .currentglobal dup false .setglobal vmstatus
- true .setglobal vmstatus 3 -1 roll pop
- 6 -2 roll pop .setglobal
- }
- { vmstatus 3 -1 roll pop
- }
- ifelse usertime 16#fffff and counttomark
- { ( ) print ( ) cvs print }
- repeat pop
- ( ) print systemdict length ( ) cvs print
- ( ) print countdictstack ( ) cvs print
- ( <) print count ( ) cvs print (>\n) print flush
- }}
- {{pop
- }}
- ifelse
- def
-
-currentdict /BATCH known /BATCH exch def
-currentdict /DELAYBIND known /DELAYBIND exch def
-currentdict /DISKFONTS known /DISKFONTS exch def
-currentdict /DOINTERPOLATE .knownget { /INTERPOLATE exch def } if
-currentdict /ESTACKPRINT known /ESTACKPRINT exch def
-currentdict /FAKEFONTS known /FAKEFONTS exch def
-currentdict /FIXEDMEDIA known /FIXEDMEDIA exch def
-currentdict /FIXEDRESOLUTION known /FIXEDRESOLUTION exch def
-currentdict /LOCALFONTS known /LOCALFONTS exch def
-currentdict /JOBSERVER known /JOBSERVER exch def
-currentdict /NOBIND known /NOBIND exch def
-/.bind /bind load def
-NOBIND { /bind { } def } if
-currentdict /NOCACHE known /NOCACHE exch def
-currentdict /NOCCFONTS known /NOCCFONTS exch def
-currentdict /NOCIE known /NOCIE exch def
-currentdict /NOPSICC known /NOPSICC exch def
-currentdict /NODISPLAY known not /DISPLAYING exch def
-currentdict /NOFONTMAP known /NOFONTMAP exch def
-currentdict /NOFONTPATH known /NOFONTPATH exch def
-currentdict /NOGC known /NOGC exch def
-currentdict /NOINTERPOLATE .knownget { /INTERPOLATE exch not def } if
-currentdict /NOMEDIAATTRS known /NOMEDIAATTRS exch def
-currentdict /NOOUTERSAVE known /NOOUTERSAVE exch def
-currentdict /NOPAGEPROMPT known /NOPAGEPROMPT exch def
-currentdict /NOPAUSE known /NOPAUSE exch def
-currentdict /NOPLATFONTS known /NOPLATFONTS exch def
-currentdict /NOPROMPT known /NOPROMPT exch def
-currentdict /NOTRANSPARENCY known /NOTRANSPARENCY exch def
-currentdict /DOPS known /DOPS exch def
-currentdict /NOSUBSTDEVICECOLORS known /NOSUBSTDEVICECOLORS exch def
-% The default value of ORIENT1 is true, not false.
-currentdict /ORIENT1 known not { /ORIENT1 true def } if
-currentdict /OSTACKPRINT known /OSTACKPRINT exch def
-currentdict /OUTPUTFILE known % obsolete
- { /OutputFile /OUTPUTFILE load def
- currentdict /OUTPUTFILE .undef
- } if
-currentdict /QUIET known /QUIET exch def
-% DELAYSAFER is effectively the same as newer NOSAFER
-currentdict /DELAYSAFER known { /DELAYSAFER true def /NOSAFER true def } if
-/SAFER currentdict /NOSAFER known {
- false
-} {
- currentdict /SAFER known
- currentdict /PARANOIDSAFER known or % PARANOIDSAFER is equivalent
-}
-ifelse def
-currentdict /SHORTERRORS known /SHORTERRORS exch def
-currentdict /STRICT known /STRICT exch def
-currentdict /TTYPAUSE known /TTYPAUSE exch def
-currentdict /WRITESYSTEMDICT known /WRITESYSTEMDICT exch def
-
-% Acquire environment variables.
-currentdict /DEVICE known not
- { (GS_DEVICE) getenv { /DEVICE exch def } if } if
-
-(START) VMDEBUG
-
-% Open the standard files, so they will be open at the outermost save level.
-(%stdin) (r) file pop
-(%stdout) (w) file pop
-(%stderr) (w) file pop
-
-/.currentuserparams where {
- pop mark
- % The Adobe implementations appear to have very large maximum
- % stack sizes. This turns out to actually make a difference,
- % since some badly-behaved files include extremely long procedures,
- % or construct huge arrays on the operand stack.
- % We reset the stack sizes now so that we don't have to worry
- % about overflowing the (rather small) built-in stack sizes
- % during initialization.
- /MaxDictStack 500
- /MaxExecStack 5000
- /MaxOpStack 65414
- .dicttomark .setuserparams
-} if
-
-% Define a procedure for skipping over an unneeded section of code.
-% This avoids allocating space for the skipped procedures.
-% We can't use readline, because that imposes a line length limit.
-/.skipeof % <string> .skipeof -
- { currentfile exch 1 exch .subfiledecode flushfile
- } .bind def
-
-% Define procedures to assist users who don't read the documentation.
-userdict begin
-/help
- { (Enter PostScript commands. '(filename) run' runs a file, 'quit' exits.\n)
- print flush
- } .bind def
-end
-
-% Define =string, which is used by some PostScript programs even though
-% it isn't documented anywhere.
-% Put it in userdict so that each context can have its own copy.
-userdict /=string 256 string put
-
-% Print the greeting.
-
-/printgreeting
- { mark
- product (Ghostscript) search
- { pop pop pop
- (This software comes with NO WARRANTY: see the file PUBLIC for details.\n)
- }
- { pop
- }
- ifelse
- (\n) copyright
- (\)\n) revisiondate 10 mod revisiondate 10 idiv 10 mod (-)
- revisiondate 100 idiv 10 mod revisiondate 1000 idiv 10 mod (-)
- revisiondate 10000 idiv ( \()
- revision 10 mod
- revision 100 mod 10 idiv (.)
- revision 100 idiv ( )
- product
- counttomark
- { (%stdout) (w) file exch 0 .writecvp
- } repeat pop
- } .bind def
-
-QUIET not { printgreeting flush } if
-
-% Define a special version of def for making operator procedures.
-/obind { % <name> <proc> obind <name> <oper>
- 1 index exch .makeoperator
-} .bind def
-/odef { % <name> <proc> odef -
- 1 index exch .makeoperator def
-} .bind def
-
-% Define a special version of def for storing local objects into global
-% dictionaries. Like .forceput, this exists only during initialization.
-/.forcedef { % <key> <value> .forcedef -
- 1 .argindex pop % check # of args
- currentdict 3 1 roll .forceput
-} .bind odef
-
-% Define procedures for accessing variables in systemdict and userdict
-% regardless of the contents of the dictionary stack.
-/.systemvar { % <name> .systemvar <value>
- //systemdict exch get
-} .bind odef
-/.userdict { % - .userdict <dict>
- /userdict .systemvar
-} .bind odef
-/.uservar { % <name> .uservar <value>
- .userdict exch get
-} .bind odef
-
-% If we're delaying binding, remember everything that needs to be bound later.
-DELAYBIND NOBIND not and
- { .currentglobal false .setglobal
- systemdict /.delaybind 1500 array .forceput
- .setglobal
- userdict /.delaycount 0 put
- % When we've done the delayed bind, we want to stop saving.
- % Detect this by the disappearance of .delaybind.
- /bind
- { /.delaybind .systemvar dup length 0 ne
- { .delaycount 2 index put
- .userdict /.delaycount .delaycount 1 add put
- }
- { pop /.bind cvx exec
- }
- ifelse
- } .bind def
- } if
-
-%**************** BACKWARD COMPATIBILITY ****************
-/hwsizedict mark /HWSize //null .dicttomark readonly def
-/copyscanlines { % <device> <y> <string> copyscanlines <substr>
- 0 3 1 roll 3 index //hwsizedict .getdeviceparams
- exch pop exch pop aload pop 3 2 roll
- 0 exch //null exch .getbitsrect exch pop
-} bind odef
-currentdict /hwsizedict .undef
-/getdeviceprops
- { //null .getdeviceparams
- } bind odef
-/.putdeviceprops
- { //null true counttomark 1 add 3 roll .putdeviceparams
- dup type /booleantype ne
- { dup mark eq { /unknown /rangecheck } if
- counttomark 4 add 1 roll cleartomark pop pop pop
- /.putdeviceprops .systemvar exch signalerror
- }
- if
- } bind odef
-/.currentfilladjust { .currentfilladjust2 pop } bind odef
-/.setfilladjust { dup .setfilladjust2 } bind odef
-/.writecvs { 0 .writecvp } bind odef
-%**************** DEPRECATED PROCEDURES ****************
-%**************** DO NOT USE THESE IN NEW CODE ****************
-/max { .max } bind def % use .max instead
-/min { .min } bind def % use .min instead
-/unread /.unread load def % use .peekstring instead
-%**************** END OF BACKWARD COMPATIBILITY SECTION ****************
-
-% Utility for removing all entries from a dictionary
-/.PurgeDict % <dict> .PurgeDict -
-{ { true
- 1 index { pop exch pop false exit
- } forall
- { exit
- } if
- 1 index exch undef
- } loop
- pop
-} bind def
-
-% Define predefined procedures substituting for operators,
-% in alphabetical order.
-
-userdict /#copies 1 put
-% Adobe implementations don't accept /[ or /], so we don't either.
-([) cvn
- /mark load def
-(]) cvn
- {counttomark array astore exch pop} odef
-% .beginpage is redefined if setpagedevice is present.
-/.beginpage { } odef
-% In LanguageLevel 3, copypage erases the page.
-/copypage {
- .languagelevel 3 ge
- dup { 0 } { 1 } ifelse .endpage .doneshowpage {
- .currentnumcopies 1 index .outputpage
- (>>copypage, press <return> to continue<<\n) .confirm
- dup { erasepage } if
- } if pop
- systemdict /..page_default_spaces .knownget { //.PurgeDict exec } if
- .beginpage
-} odef
-/currentmatrix {
- dup type /arraytype ne
- { /currentmatrix load /typecheck signalerror } if
- dup length 6 ne
- { /currentmatrix load /rangecheck signalerror } if
- .currentmatrix 6 .argindex astore pop
-} odef
-% .currentnumcopies is redefined in Level 2.
-/.currentnumcopies { #copies } odef
-/setcolorscreen where { pop % not in all Level 1 configurations
- /currentcolorscreen
- { .currenthalftone
- { { 60.0 exch 0.0 exch 3 copy 6 copy } % halftone - not possible
- { 3 copy 6 copy } % screen
- { } % colorscreen
- }
- exch get exec
- } odef
-} if
-/currentscreen
- { .currenthalftone
- { { 60.0 exch 0.0 exch } % halftone - not possible
- { } % screen
- { 12 3 roll 9 { pop } repeat } % colorscreen
- }
- exch get exec
- } odef
-/.echo /echo load def
-userdict /.echo.mode true put
-/echo {dup /.echo.mode exch store .echo} odef
-/.eexec_param_dict mark
- /eexec true
- /seed 55665
-.dicttomark readonly def
-/eexec {
- % Rebind .currentresourcefile if it is the source for the eexec.
- dup //.eexec_param_dict //filterdict /eexecDecode get exec
- cvx exch .currentresourcefile eq
- //systemdict begin { {exec} .execasresource } { exec } ifelse
- % Only pop systemdict if it is still the top element,
- % because this is apparently what Adobe interpreters do.
- currentdict //systemdict eq { end } if
-} odef
-% .endpage is redefined if setpagedevice is present.
-/.endpage { 2 ne } odef
-% erasepage mustn't use gsave/grestore, because we call it before
-% the graphics state stack has been fully initialized.
-/erasepage
- { /currentcolor where
- { pop currentcolor currentcolorspace { setcolorspace setcolor } }
- { /currentcmykcolor where
- { pop currentcmykcolor { setcmykcolor } }
- { currentrgbcolor { setrgbcolor } }
- ifelse
- }
- ifelse
- currentoverprint false setoverprint 1 setgray .fillpage setoverprint
- exec
- } odef
-% To satisfy the Genoa FTS, executive must be a procedure, not an operator.
-/executive
- { { prompt
- { (%statementedit) (r) .systemvmfile } stopped
- { pop pop $error /errorname get /undefinedfilename eq
- { .clearerror exit } if % EOF
- /handleerror .systemvar exec //null % ioerror??
- }
- if
- cvx { .runexec } execute
- } loop
- } bind def
-/filter
- { //filterdict 1 .argindex .knownget
- { exch pop exec }
- { /filter .systemvar /undefined signalerror }
- ifelse
- } odef
-% handleerror procedure as mentioned in the "Operators" section of the PLRM Section 8.2
-% This invokes the handleerror procedure from errordict (unless we are running under a
-% JOBSERVER where we want to always use a defined error handler (many error handlers in
-% 'wild' PostScript files are broken and don't indicate the error in any useful fashion).
-%
-% We run the handleerror procedure using .internalstopped so that broken error handlers
-% won't cause nested errors (Unexpected Error conditions).
-/handleerror
- JOBSERVER {
- { /.GShandleerror .systemvar .internalstopped pop } bind % always use .GShandleerror.
- } {
- { /errordict .systemvar /handleerror get .internalstopped pop } bind % PLRM standard errorhandling
- } ifelse def
-/identmatrix [1.0 0.0 0.0 1.0 0.0 0.0] readonly def
-/identmatrix {
- dup type /arraytype ne { /identmatrix load /typecheck signalerror } if
- dup length 6 ne { /identmatrix load /rangecheck signalerror } if
- dup 0 //identmatrix putinterval
-} odef
-/languagelevel 1 def % gs_lev2.ps may change this
-/makeimagedevice { false makewordimagedevice } odef
-/matrix { 6 array identmatrix } odef
-% .promptmsg is redefined if the interpreter includes readline support.
-/.promptmsg {
- (GS) print
- count 0 ne { (<) print count =only } if
- (>) print flush
-} bind def
-/prompt { flush flushpage NOPROMPT not { .promptmsg } if } bind def
-/pstack { 0 1 count 3 sub { index == } for } bind def
-/putdeviceprops
- { .putdeviceprops { erasepage } if } odef
-/quit { /quit load 0 .quit } odef
-/run { dup type /filetype ne { (r) .systemvmfile } if
- % We must close the file when execution terminates,
- % regardless of the state of the stack,
- % and then propagate an error, if any.
- cvx null {.runexec} .errorexec
- } odef
-% Execute a file.
-% Level 2 uses 2 .stop to clear the e-stack for a successful startjob:
-% we detect that here, since we need to handle this even if we start out
-% without job control in effect.
-%
-% What we push on the e-stack is the following to be executed in this order:
-% <lit-file|fileproc> .runexec1 <lit-file|fileproc> .runexec2
-/.runexec1 { % <file|fileproc> .runexec1 -
- dup type /filetype ne { cvx exec } if
- cvx //null 2 .stopped
- % If we got back here from a startjob, just keep going.
- % startjob replaces the null on the o-stack with a procedure
- % to be executed when we get back here.
- dup //null ne { exec true } { pop false } ifelse
-} bind def
-/.runexec2 { % <continue> <file|fileproc> .runexec2 -
- exch {
- .runexec
- } {
- dup type /filetype ne { cvx exec } if
- closefile
- } ifelse
-} bind def
-/.runexec { % <file|fileproc> .runexec -
- cvlit /.runexec1 cvx 1 index /.runexec2 cvx 4 .execn
-} bind def
-% The following is only for compatibility with Adobe interpreters.
-/setdash {
- 0 .argindex type dup /integertype eq exch /realtype eq or not {
- /setdash .systemvar /typecheck signalerror
- } if
- 1 .argindex length 11 gt { /setdash .systemvar /limitcheck signalerror } if
- //setdash
-} odef
-/setdevice
- {
- .setdevice
- {
- mark
- { % Reset the halftone since the device may differ
- currenthalftone
- dup type /dicttype eq
- { sethalftone }
- { pop }
- ifelse
- }
- stopped
- cleartomark
- erasepage
- }
- if
- }
-odef
-/setlinecap {
- dup 2 gt { /setlinecap .systemvar /rangecheck signalerror } if
- .setlinecap
-} odef
-/setlinejoin {
- dup 2 gt { /setlinejoin .systemvar /rangecheck signalerror } if
- .setlinejoin
-} odef
-/setmatrix {
- dup type /arraytype ne {
- dup type /packedarraytype ne {
- /setmatrix load /typecheck signalerror
- } if
- } if
- dup length 6 ne { /setmatrix load /rangecheck signalerror } if
- dup aload pop .setmatrix pop
-} odef
-/showpage {
- 0 .endpage .doneshowpage {
- .currentnumcopies true .outputpage
- (>>showpage, press <return> to continue<<\n) .confirm
- initgraphics
- currentoverprint false setoverprint 1 setcolor
- .fillpage
- setoverprint 0 setcolor
- }
- { initgraphics } ifelse
- systemdict /..page_default_spaces .knownget { //.PurgeDict exec } if
- .beginpage
-} odef
-% Code output by Adobe Illustrator relies on the fact that
-% `stack' is a procedure, not an operator!!!
-/stack { 0 1 count 3 sub { index = } for } bind def
-/start { BATCH { //null 0 .quit } { executive } ifelse } def
-% Internal uses of stopped that aren't going to do a stop if an error occurs
-% should use .internalstopped to avoid setting newerror et al.
-/.internalstopped { //null 1 .stopped //null ne } bind def
-/store { % Don't alter operands before completing.
- 1 .argindex where { 2 index 2 index put pop pop } { def } ifelse
-} odef
-/.typenames mark .typenames counttomark packedarray exch pop def
-/type {
- //.typenames .type
-} odef
-currentdict /.typenames .undef
-% When running in Level 1 mode, this interpreter is supposed to be
-% compatible with PostScript "version" 54.0 (I think).
-/version (54.0) readonly def
-/.wheredict 10 dict def
-/.where /where load def
-/where {
- //.wheredict 1 .argindex .knownget { exec } { .where } ifelse
-} odef
-
-% internaldict is defined in systemdict, but the dictionary is allocated
-% in local VM. However, the procedure must be global, since it is an
-% "operator" and must be bind-able into global procedures.
-% We make a procedure for creating it, since we must create a new one
-% for each context with private local VM.
-/.makeinternaldict {
- .currentglobal true .setglobal
- [ /dup .systemvar 1183615869 /eq .systemvar
- [ /pop .systemvar //null ] cvx
- false .setglobal
- dup 1 10 dict .forceput % proc is global, dict is local
- true .setglobal
- [ /internaldict /cvx .systemvar /invalidaccess /signalerror cvx ] cvx
- /ifelse .systemvar
- ] cvx executeonly
- exch .setglobal
-} odef
-systemdict /internaldict dup .makeinternaldict .makeoperator
-.forceput % proc is local, systemdict is global
-
-% Define some additional built-in procedures (beyond the ones defined by
-% the PostScript Language Reference Manual).
-% Warning: these are not guaranteed to stay the same from one release
-% to the next!
-/concatstrings % (str1) (str2) concatstrings (str1str2)
- { exch dup length 2 index length add string % str2 str1 new
- dup dup 4 2 roll copy % str2 new new new1
- length 4 -1 roll putinterval
- } bind def
-/copyarray
- { dup length array copy } bind def
-% Copy a dictionary per the Level 2 spec even in Level 1.
-/.copydict % <fromdict> <todict> .copydict <todict>
- { dup 3 -1 roll { put dup } forall pop } bind def
-/copystring
- { dup length string copy } bind def
-/findlibfile {
- .systemvmlibfile { dup .filename pop exch true } { false } ifelse
-} odef
-/.growdictlength % get size for growing a dictionary
- { length 3 mul 2 idiv 1 add
- } bind def
-/.growdict % grow a dictionary
- { dup .growdictlength .setmaxlength
- } bind def
-/.growput % put, grow the dictionary if needed
- { 2 index length 3 index maxlength eq
- { 3 copy pop known not { 2 index .growdict } if
- } if
- put
- } bind def
-% .localvmarray may be an operator: see zsysvm.c.
-/.localvmarray where {
- pop
-} {
- /.localvmarray {
- .currentglobal false .setglobal
- exch array exch .setglobal
- } bind def
-} ifelse
-/.localvmdict where {
- pop
-} {
- /.localvmdict {
- .currentglobal false .setglobal
- exch dict exch .setglobal
- } bind def
-} ifelse
-/.packtomark
- { counttomark packedarray exch pop } bind def
-/ppstack
- { 0 1 count 3 sub { index === } for } bind def
-/runlibfile
- { % We don't want to bind 'run' into this procedure,
- % since run may get redefined.
- findlibfile
- { exch pop /run .systemvar exec }
- { /undefinedfilename signalerror }
- ifelse
- } bind def
-/selectdevice
- { finddevice setdevice .setdefaultscreen } bind def
-/signalerror % <object> <errorname> signalerror -
- { /errordict .systemvar exch get exec } bind def
-/signaloperror { % <object> <errorname> signaloperror -
- % Same as signalerror, except that if we are inside a pseudo-operator
- % or .errorexec, we use its error object, just as errors generated by
- % real operators do.
- /errordict .systemvar exch get
- .finderrorobject { 3 -1 roll pop exch } if
- exec
-} bind def
-
-% Define the =[only] procedures. Also define =print,
-% which is used by some PostScript programs even though
-% it isn't documented anywhere.
-/write=only {
- .writecvs
-} bind def
-/write= {
- 1 index exch write=only (\n) writestring
-} bind def
-/=only { (%stdout) (w) file exch write=only } bind def
-/= { =only (\n) print } bind def
-/=print /=only load def
-% Temporarily define == as = for the sake of runlibfile0.
-/== /= load def
-
-% The following procedures are documented.
-/copydevice { % <device> copydevice <newdevice>
- false .copydevice2
-} odef
-/finddevice { % <devicename> finddevice <device>
- /devicedict .systemvar exch get
- dup 1 get //null eq {
- % This is the first request for this type of device.
- % Create a default instance now.
- % Stack: [proto null]
- .currentglobal true .setglobal exch
- dup dup 0 get copydevice 1 exch put
- exch .setglobal
- } if 1 get
-} bind def
-/findprotodevice { % <devicename> findprotodevice <protodevice>
- /devicedict .systemvar exch get 0 get
-} bind def
-
-% Run a resource file. This allows us to distinguish resource objects
-% from objects coming from input files.
-userdict /.currentresourcefile //null put
-/.execasresource { % <file> <proc|runfile> .execasresource -
- /stopped .systemvar
- /.currentresourcefile .uservar
- % Stack: file proc -stopped- currfile
- .userdict /.currentresourcefile 5 index cvlit put
- 2 .execn % stopped <file>
- .userdict /.currentresourcefile 3 -1 roll put
- { stop } if
-} bind def
-/.runresource { % <file> .runresource -
- { /run .systemvar exec } .execasresource
-} bind def
-
-% Define procedures for getting and setting the current device resolution.
-
-/gsgetdeviceprop % <device> <propname> gsgetdeviceprop <value>
- { 2 copy mark exch //null .dicttomark .getdeviceparams
- dup mark eq % if true, not found
- { pop dup /undefined signalerror }
- { 5 1 roll pop pop pop pop }
- ifelse
- } bind def
-/gscurrentresolution % - gscurrentresolution <[xres yres]>
- { currentdevice /HWResolution gsgetdeviceprop
- } bind def
-/gssetresolution % <[xres yres]> gssetresolution -
- { 2 array astore mark exch /HWResolution exch
- currentdevice copydevice putdeviceprops setdevice
- } bind def
-
-% Define auxiliary procedures needed for the above.
-/shellarguments % -> shell_arguments true (or) false
- { /ARGUMENTS where
- { /ARGUMENTS get dup type /arraytype eq
- { aload pop /ARGUMENTS //null store true }
- { pop false }
- ifelse }
- { false } ifelse
- } bind def
-/.confirm {
- DISPLAYING NOPAUSE not TTYPAUSE or and {
- % Print a message (unless NOPAGEPROMPT or NOPROMPT is true)
- % and wait for the user to type something.
- % If the user just types a newline, flush it.
- NOPAGEPROMPT NOPROMPT or { pop } { print flush } ifelse
- .confirmread
- } {
- pop
- } ifelse
-} bind def
-/.confirmread {
- TTYPAUSE {
- (/dev/tty) (r) file dup read pop pop closefile
- } {
- .echo.mode false echo
- (%stdin) (r) file dup read {
- dup (\n) 0 get eq { pop pop } { unread } ifelse
- } {
- pop
- } ifelse echo
- } ifelse
-} bind def
-
-% Define the procedure used by .runfile, .runstdin and .runstring
-% for executing user input.
-% This is called with a procedure or executable file on the operand stack.
-/.execute { % <obj> .execute <stopped>
- stopped $error /newerror get and
- { /handleerror .systemvar exec flush true } { false } ifelse
-} bind def
-/execute { % <obj> execute -
- .execute pop
-} odef
-% Define an execute analogue of runlibfile0.
-/execute0 { % <obj> execute0 -
- .execute { /execute0 cvx 1 .quit } if
-} bind def
-% Define the procedure that the C code uses for running files
-% named on the command line.
-/.runfile {
- { runlibfile } execute0
-} def
-% Define the procedure that the C code uses for running piped input.
-% We don't use the obvious { (%stdin) run }, because we want the file to be
-% reopened if a startjob does a restore.
-/.runstdin {
- { { (%stdin) (r) file cvx } .runexec } execute0
-} bind def
-% Define the procedure that the C code uses for running commands
-% given on the command line with -c. We turn the string into a file so that
-% .runexec can do the right thing with a startjob.
-/.runstring {
- 0 0 .systemvmstring .systemvmSFD cvx { .runexec } execute0
-} bind def
-% Define the procedure that the C code uses to set up for executing
-% a string that may be received in pieces.
-/.runstringbegin {
- 1 .systemvmarray dup 0 /.needinput load put cvx % { .needinput } in systemvm
- 0 0 .systemvmstring .systemvmSFD cvx .runexec
-} bind def
-
-% Define a special version of runlibfile that aborts on errors.
-/runlibfile0
- { cvlit dup dup /.currentfilename exch def
- { findlibfile not { stop } if }
- stopped
- { (Can't find \(or open\) initialization file ) print
- .currentfilename == flush /runlibfile0 cvx 1 .quit
- } if
- exch pop cvx
- { stopped } 0 get 3 -1 roll 2 array astore cvx exec
- /.currentfilename exch store
- { (While reading ) print .currentfilename print (:\n) print flush
- /handleerror .systemvar exec /runlibfile0 1 .quit
- } if
- } bind def
-% Temporarily substitute it for the real runlibfile.
-/.runlibfile /runlibfile load def
-/runlibfile /runlibfile0 load def
-
-% Create the error handling machinery.
-% Define the standard error handlers.
-% The interpreter has created the ErrorNames array.
-/.unstoppederrorhandler % <command> <errorname> .unstoppederrorhandler -
- { % This is the handler that gets used for recursive errors,
- % or errors outside the scope of a 'stopped'.
- 2 copy SHORTERRORS
- { (%%[ Error: ) print =only flush
- (; OffendingCommand: ) print =only ( ]%%) =
- }
- { (Unrecoverable error: ) print =only flush
- ( in ) print = flush
- count 2 gt
- { (Operand stack:\n ) print
- count 1 sub -1 2 { ( ) print index =only flush } for
- () = flush
- } if
- }
- ifelse
- -1 0 1 //ErrorNames length 1 sub
- { dup //ErrorNames exch get 3 index eq
- { not exch pop exit } { pop } ifelse
- }
- for exch pop .quit
- } bind def
-/.errorhandler % <command> <errorname> .errorhandler -
- { % Detect an internal 'stopped'.
- 1 .instopped { //null eq { pop pop stop } if } if
- (I) false .setdebug
- $error /.inerror get 1 .instopped { pop } { pop true } ifelse
- { .unstoppederrorhandler
- } if % detect error recursion
- $error /globalmode .currentglobal false .setglobal put
- $error /.inerror true put
- $error /newerror true put
- $error exch /errorname exch put
- $error exch /command exch put
- $error /errorinfo known not { $error /errorinfo //null put } if
- $error /recordstacks get $error /errorname get /VMerror ne and
- { % Attempt to store the stack contents atomically.
- count array astore dup $error /ostack 4 -1 roll
- % Grab the execstack, then remove to two elements that are from
- % this error handler (not interesting).
- countexecstack array execstack dup length 2 sub 0 exch getinterval
- $error /estack 3 -1 roll
- countdictstack array dictstack $error /dstack 3 -1 roll
- put put put aload pop
- }
- { $error /dstack .undef
- $error /estack .undef
- $error /ostack .undef
- }
- ifelse
- $error /position currentfile status
- { currentfile { fileposition } .internalstopped { pop //null } if
- }
- { % If this was a scanner error, the file is no longer current,
- % but the command holds the file, which may still be open.
- $error /command get dup type /filetype eq
- { { fileposition } .internalstopped { pop //null } if }
- { pop //null }
- ifelse
- }
- ifelse put
- % During initialization, we don't reset the allocation
- % mode on errors.
- $error /globalmode get $error /.nosetlocal get and .setglobal
- $error /.inerror false put
- stop
- } bind def
-% Define the standard handleerror. We break out the printing procedure
-% (.printerror) so that it can be extended for binary output
-% if the Level 2 facilities are present.
- /.printerror
- { $error begin newerror
- {
- /command load errorname SHORTERRORS
- { (%%[ Error: ) print =only flush
- (; OffendingCommand: ) print =only
- errorinfo dup //null eq {
- pop
- } {
- (;\nErrorInfo:) print
- dup type /arraytype eq
- { { ( ) print =only } forall }
- { ( ) print =only }
- ifelse
- } ifelse
- ( ]%%) = flush
- }
- { (Error: ) print ==only flush
- ( in ) print ==only flush
- errorinfo dup //null eq {
- pop
- } {
- (\nAdditional information: ) print ==only flush
- } ifelse
- .printerror_long
- }
- ifelse
- .clearerror flush
- }
- { % newerror is false, test to see if user has set handleerror to a different
- % routine, if so execute it, otherwise, just return. This code deals with the
- % Genoa issue of setting /handleerror, and then calling it, without an error
- % being set. We were erroring in this case, due to /command load failing.
-
- //JOBSERVER {
- /errordict .systemvar /handleerror get /.GShandleerror .systemvar ne
- } {
- false
- } ifelse
- { /errordict .systemvar begin /handleerror load .internalstopped pop end
- }
- if
- }
- ifelse % newerror
- end
- flush
- } bind def
- /.printerror_long % long error printout,
- % $error is on the dict stack
- { % Push the (anonymous) stack printing procedure.
- % <heading> <==flag> <override-name> <stackname> proc
- {
- currentdict exch .knownget % stackname defined in $error?
- {
- 4 1 roll % stack: <stack> <head> <==flag> <over>
- /errordict .systemvar exch .knownget % overridename defined?
- {
- exch pop exch pop exec % call override with <stack>
- }
- {
- exch print exch % print heading. stack <==flag> <stack>
- 1 index not { () = } if
- { 1 index { (\n ) } { ( ) } ifelse print
- dup type /dicttype eq
- {
- (--dict:) print
- dup rcheck {
- dup length =only (/) print dup maxlength =only
- dup wcheck not { ((ro)) print } if
- } if
- /gcheck where {
- pop gcheck { ((G)) } { ((L)) } ifelse print
- } {
- pop
- } ifelse (--) print
- }
- {
- dup type /stringtype eq 2 index or
- { ==only } { =only } ifelse
- } ifelse
- } forall
- pop
- }
- ifelse % overridden
- }
- { pop pop pop
- }
- ifelse % stack known
- }
-
- (\nOperand stack:) OSTACKPRINT /.printostack /ostack 4 index exec
- (\nExecution stack:) ESTACKPRINT /.printestack /estack 4 index exec
- (\nBacktrace:) true /.printbacktrace /backtrace 4 index exec
- (\nDictionary stack:) false /.printdstack /dstack 4 index exec
- () =
- pop % printing procedure
-
- errorname /VMerror eq
- { (VM status:) print mark vmstatus
- counttomark { ( ) print counttomark -1 roll dup =only } repeat
- cleartomark () =
- } if
-
- .languagelevel 2 ge
- { (Current allocation mode is ) print
- globalmode { (global\n) } { (local\n) } ifelse print
- } if
-
- .oserrno dup 0 ne
- { (Last OS error: ) print
- errorname /VMerror ne
- { dup .oserrorstring { = pop } { = } ifelse }
- { = }
- ifelse
- }
- { pop
- }
- ifelse
-
- position //null ne
- { (Current file position is ) print position = }
- if
-
- } bind def
-% Define a procedure for clearing the error indication.
-/.clearerror
- { $error /newerror false put
- $error /errorname //null put
- $error /errorinfo //null put
- 0 .setoserrno
- } bind def
-
-% Define $error. This must be in local VM.
-.currentglobal false .setglobal
-/$error 40 dict .forcedef % $error is local, systemdict is global
- % newerror, errorname, command, errorinfo,
- % ostack, estack, dstack, recordstacks,
- % binary, globalmode,
- % .inerror, .nosetlocal, position,
- % plus extra space for badly designed error handers.
-$error begin
- /newerror false def
- /recordstacks true def
- /binary false def
- /globalmode .currentglobal def
- /.inerror false def
- /.nosetlocal true def
- /position //null def
- /errorinfo //null def
-end
-% Define errordict similarly. It has one entry per error name,
-% plus handleerror. However, some astonishingly badly written PostScript
-% files require it to have at least one empty slot.
-/errordict ErrorNames length 3 add dict
-.forcedef % errordict is local, systemdict is global
-.setglobal % back to global VM
-% For greater Adobe compatibility, we put all non-standard errors in a
-% separate dictionary, gserrordict. It does not need to be in local VM,
-% because PostScript programs do not access it.
-% NOTE: the name gserrordict is known to the interpreter.
-/gserrordict 5 dict def
-% Register an error in errordict. We make this a procedure because we only
-% register the Level 1 errors here: the rest are registered by "feature"
-% files. However, ErrorNames contains all of the error names regardless of
-% what features are included, so we have to "know" that VMerror is the last
-% Level 1 error.
-/.registererror % <name> .registererror -
- { errordict exch .registererror2
- } bind def
-/.registererror2 % <dict> <name> .registererror -
- { .currentglobal true .setglobal % create procs in global VM
- 3 1 roll
- mark 1 index systemdict /.errorhandler get /exec load .packtomark cvx put
- .setglobal
- } bind def
-ErrorNames
- { dup .registererror /VMerror eq {exit} if
- } forall
-errordict begin
-% The handlers for interrupt and timeout are special; there is no
-% 'current object', so they push their own name.
- { /interrupt /timeout }
- { mark 1 index dup systemdict /.errorhandler get /exec load .packtomark cvx def
- } forall
-/handleerror % this key is 'well known' and some PS may redefine it
- { /.printerror .systemvar exec
- } bind def
-end % errordict
-
-% Put non-standard errors in gserrordict.
-gserrordict /unknownerror errordict /unknownerror get put
-errordict /unknownerror .undef
-% Define a stable private copy of handleerror that we will always use under
-% JOBSERVER mode.
-/.GShandleerror errordict /handleerror get def
-
-% Define the [write]==[only] procedures.
-/.dict 8 dict dup
-begin def
- /.cvp {1 index exch 1 .writecvp} bind def
- /.p {1 index exch writestring} bind def
- /.p1 {2 index exch writestring} bind def
- /.p2 {3 index exch writestring} bind def
- /.print
- { dup type .dict exch .knownget { exec } { .cvp } ifelse
- } bind def
- /arraytype
- {dup rcheck
- {() exch dup xcheck
- {({) .p2
- {exch .p1
- 1 index exch .print pop ( )} forall
- (})}
- {([) .p2
- {exch .p1
- 1 index exch .print pop ( )} forall
- (])}
- ifelse exch pop .p}
- {.cvp}
- ifelse} bind def
- /packedarraytype /arraytype load def
-{//.dict begin .print pop end}
- bind
-end
-
-/write==only exch def
-/write== {1 index exch write==only (\n) writestring} bind def
-/==only { (%stdout) (w) file exch write==only } bind def
-/== {==only (\n) print} bind def
-
-% Define [write]===[only], an extension that prints dictionaries
-% in readable form and doesn't truncate strings.
-/.dict /write==only load 0 get dup length 2 add dict .copydict dup
-begin def
- /dicttype
- { dup rcheck
- { (<< ) .p1
- { 2 index 3 -1 roll .print pop ( ) .p1
- 1 index exch .print pop ( ) .p
- }
- forall (>>) .p
- }
- { .cvp
- }
- ifelse
- } bind def
- /stringtype
- { 1 index exch 2 .writecvp
- } bind def
-
-{//.dict begin .print pop end}
- bind
-end
-
-/write===only exch def
-/write=== {1 index exch write===only (\n) writestring} bind def
-/===only { (%stdout) (w) file exch write===only } bind def
-/=== { ===only (\n) print } bind def
-
-% Create the initialization queue.
-
-/.delayed_init_queue 10 dict def
-
-/.schedule_init % <priority> <proc> .schedule_init -
-{
- //.delayed_init_queue 2 index known {
- (.delayed_init_queue priority conflict with ) print 1 index =
- /.schedule_init cvx /configurationerror signalerror
- } if
- //.delayed_init_queue 3 1 roll .growput
-} bind def
-
-/.execute_scheduled_inits % - .execute_scheduled_inits -
-{
- { 0 //null //.delayed_init_queue { % maxp {} p {}
- 3 index 2 index lt {
- 4 2 roll
- } if
- pop pop
- } forall
- exch //.delayed_init_queue exch undef
- dup //null eq {
- pop exit
- } if
- exec
- } loop
-} bind def
-
-(END PROCS) VMDEBUG
-
-% Define the font directory.
-/FontDirectory false .setglobal 100 dict true .setglobal
-.forcedef % FontDirectory is local, systemdict is global
-
-% Define the encoding dictionary.
-/EncodingDirectory 16 dict def % enough for Level 2 + PDF standard encodings
-
-% Define .findencoding. (This is redefined in Level 2.)
-/.findencoding
- { //EncodingDirectory exch get exec
- } bind def
-/.defineencoding
- { //EncodingDirectory 3 1 roll put
- } bind def
-% If we've got the composite font extensions, define findencoding.
-% To satisfy the Genoa FTS, findencoding must be a procedure, not an operator.
-/rootfont where { pop /findencoding { .findencoding } def } if
-
-% Define .registerencoding.
-% NOTE: This procedure no longer does anything, but it must continue to
-% exist for the sake of toolbin/encs2c.ps.
-/.registerencoding { % <index> <array> .registerencoding -
- pop pop
-} bind odef
-
-% Load StandardEncoding.
-%% Replace 1 (gs_std_e.ps)
-(gs_std_e.ps) dup runlibfile VMDEBUG
-
-% Load ISOLatin1Encoding.
-%% Replace 1 (gs_il1_e.ps)
-(gs_il1_e.ps) dup runlibfile VMDEBUG
-
-% Define stubs for the Symbol and Dingbats encodings.
-% Note that the first element of the procedure must be the file name,
-% since gs_lev2.ps extracts it to set up the Encoding resource category.
-
- /SymbolEncoding { /SymbolEncoding .findencoding } bind def
-%% Replace 3 (gs_sym_e.ps)
- EncodingDirectory /SymbolEncoding
- { (gs_sym_e.ps) //systemdict begin runlibfile SymbolEncoding end }
- bind put
-
- /DingbatsEncoding { /DingbatsEncoding .findencoding } bind def
-%% Replace 3 (gs_dbt_e.ps)
- EncodingDirectory /DingbatsEncoding
- { (gs_dbt_e.ps) //systemdict begin runlibfile DingbatsEncoding end }
- bind put
-
-(END FONTDIR/ENCS) VMDEBUG
-
-% Construct a dictionary of all available devices.
-% These are (read-only) device prototypes that can't be
-% installed or have their parameters changed. For this reason,
-% the value in the dictionary is actually a 2-element writable array,
-% to allow us to create a default instance of the prototype on demand.
-
- % Loop until the .getdevice gets a rangecheck.
-errordict /rangecheck 2 copy get
-errordict /rangecheck { pop stop } put % pop the command
- 0 { {dup .getdevice exch 1 add} loop} .internalstopped pop
- 1 add dict /devicedict 1 index def
- begin % 2nd copy of count is on stack
- { dup .devicename exch
- dup wcheck { dup } { //null } ifelse 2 array astore def
- } repeat
- end
-put % errordict /rangecheck
-.clearerror
-/devicenames devicedict { pop } forall devicedict length packedarray def
-
-% Determine the default device.
-/defaultdevice DISPLAYING
- { systemdict /DEVICE .knownget
- { devicedict 1 index known not
- { (Unknown device: ) print =
- flush /defaultdevice cvx 1 .quit
- }
- if
- }
- { .getdefaultdevice .devicename
- }
- ifelse
- }
- { /nullpage
- }
-ifelse
-/.defaultdevicename 1 index def
-finddevice % make a copy
-def
-devicedict /Default devicedict .defaultdevicename get put
-
-(END DEVS) VMDEBUG
-
-% Define statusdict, for the benefit of programs
-% that think they are running on a LaserWriter or similar printer.
-%% Replace 1 (gs_statd.ps)
-(gs_statd.ps) runlibfile
-
-(END STATD) VMDEBUG
-
-% Load the standard font environment.
-%% Replace 1 (gs_fonts.ps)
-(gs_fonts.ps) runlibfile
-
-(END GS_FONTS) VMDEBUG
-
-% Define the default halftone screen and BG/UCR functions now, so that
-% it will bind in the original definitions of set[color]screen.
-% We make this a procedure so we can call it again when switching devices.
-
-% Use an ordered dither for low-resolution devices.
-/.setloreshalftone { % <dpi> .setloreshalftone -
- % The following 'ordered dither' spot function was contributed by
- % Gregg Townsend. Thanks, Gregg!
- 16.001 div 0 % not 16: avoids rounding problems
- { 1 add 7.9999 mul cvi exch 1 add 7.9999 mul cvi 16 mul add <
- 0E 8E 2E AE 06 86 26 A6 0C 8C 2C AC 04 84 24 A4
- CE 4E EE 6E C6 46 E6 66 CC 4C EC 6C C4 44 E4 64
- 3E BE 1E 9E 36 B6 16 96 3C BC 1C 9C 34 B4 14 94
- FE 7E DE 5E F6 76 D6 56 FC 7C DC 5C F4 74 D4 54
- 01 81 21 A1 09 89 29 A9 03 83 23 A3 0B 8B 2B AB
- C1 41 E1 61 C9 49 E9 69 C3 43 E3 63 CB 4B EB 6B
- 31 B1 11 91 39 B9 19 99 33 B3 13 93 3B BB 1B 9B
- F1 71 D1 51 F9 79 D9 59 F3 73 D3 53 FB 7B DB 5B
- 0D 8D 2D AD 05 85 25 A5 0F 8F 2F AF 07 87 27 A7
- CD 4D ED 6D C5 45 E5 65 CF 4F EF 6F C7 47 E7 67
- 3D BD 1D 9D 35 B5 15 95 3F BF 1F 9F 37 B7 17 97
- FD 7D DD 5D F5 75 D5 55 FF 7F DF 5F F7 77 D7 57
- 02 82 22 A2 0A 8A 2A AA 00 80 20 A0 08 88 28 A8
- C2 42 E2 62 CA 4A EA 6A C0 40 E0 60 C8 48 E8 68
- 32 B2 12 92 3A BA 1A 9A 30 B0 10 90 38 B8 18 98
- F2 72 D2 52 FA 7A DA 5A F0 70 D0 50 F8 78 D8 58
- > exch get 256 div
- }
- bind
- % Use correct, per-plane screens for CMYK devices only.
- //systemdict /setcolorscreen known processcolors 4 eq and
- { 3 copy 6 copy //setcolorscreen }
- { //setscreen }
- ifelse
-} bind def
-/.setloresscreen { % <dpi> .setloresscreen -
- .setloreshalftone
- 0 array cvx settransfer % Genoa CET won't accept a packed array!
- /setstrokeadjust where { pop true setstrokeadjust } if
-} bind def
-% Use a 45-degree spot screen for high-resolution devices.
-% The PS3 CET insists that the screen be an array and not a packedarray (!).
-currentpacking false setpacking
-/.linescreen
-% The following screen algorithm is used by permission of the author.
- { ((C) 1989 Berthold K.P. Horn) pop
- 1 add 180 mul cos 1 0.08 add mul exch 2 add 180 mul cos
- 1 0.08 sub mul add 2 div
- }
-bind readonly def
-setpacking
-/.sethireshalftone { % <dpi> .sethireshalftone <doscreen>
- % According to information published by Hewlett-Packard,
- % they use a 60 line screen on 300 DPI printers and
- % an 85 line screen on 600 DPI printers.
- % However, we use a 106 line screen, which produces smoother-
- % looking shades but fewer of them (32 vs. 50).
- % 46 was suggested as a good frequency value for printers
- % between 200 and 400 DPI, so we use it for lower resolutions.
- % Imagesetters need even higher frequency screens.
- //systemdict /DITHERPPI known
- { DITHERPPI
- }
- { dup cvi 100 idiv 15 .min
- {//null 46 46 60 60 60 106 106 106 106 133 133 133 133 133 150}
- exch get
- }
- ifelse
- 1 index 4.01 div .min % at least a 4x4 cell
- 45
- //.linescreen
- % Determine whether we have lots of process colors.
- % If so, don't bother with color screening or gamma correction.
- % Also don't do gamma correction on very high-resolution devices.
- % (This should depend on dot gain, not resolution, but we don't
- % currently have a way to determine this.) Ignore missing components
- % (*Values = 1).
- currentdevice mark
- /RedValues 0 /GreenValues 0 /BlueValues 0 /GrayValues 0
- .dicttomark .getdeviceparams
- counttomark 2 idiv 1 sub
- { exch pop dup 1 le
- { pop }
- { exch dup 1 le
- { pop }
- { .min }
- ifelse
- }
- ifelse
- }
- repeat
- exch pop exch pop 32 lt 4 index 800 lt and 5 1 roll
- % Stack: doscreen dpi freq angle proc
- % Ghostscript currently doesn't use correct, per-plane halftones
- % unless setcolorscreen has been executed. Since these are
- % computationally much more expensive than binary halftones,
- % we check to make sure they are really warranted, i.e., we have
- % a high-resolution CMYK device (i.e., not a display) with
- % fewer than 5 bits per plane (i.e., not a true-color device).
- 4 -1 roll 150 ge
- { /setcolorscreen where
- { pop //systemdict /COLORSCREEN known
- { COLORSCREEN }
- { 3 index }
- ifelse
- dup false ne
- { 4 1 roll 3 copy 6 copy 13 -1 roll
- % For really high-quality screening on printers, we need to
- % give each plane its own screen angle. Unfortunately,
- % this currently has very large space and time costs.
- true eq % true => different angles,
- % 0 => same angles
- { { 45 90 15 75 } { 3 1 roll exch pop 12 3 roll } forall
- }
- if //setcolorscreen
- }
- { pop //setscreen % false => single binary screen
- }
- ifelse
- }
- { //setscreen % setcolorscreen not known
- }
- ifelse
- }
- { //setscreen % not high resolution
- }
- ifelse
-} bind def
-/.sethiresscreen { % <dpi> .sethiresscreen
- .sethireshalftone % pushes true if a screen halftone used
- % Stack: doscree
- {
- % Set the transfer function to lighten up the grays.
- % Parameter values closer to 1 are better for devices with
- % less dot spreading; lower values are better with more spreading.
- % The value 0.8 is a compromise that will probably please no one!
- %
- % Because of a bug in FrameMaker, we have to accept operands
- % outside the valid range of [0..1].
- {
- dup dup 0.0 gt exch 1.0 lt and
- {
- 0.8 exp
- }
- if
- }
- }
- {
- % Set the transfer function to the identity.
- 0 array cvx % Genoa CET won't accept a packed array!
- }
- ifelse
- settransfer
- /setstrokeadjust where
- { pop false setstrokeadjust }
- if
-
- % Increase fill adjustment so that we effectively use Adobe's
- % any-part-of-pixel rule.
- 0.5 .setfilladjust
-} bind def
-% Set the default screen and BG/UCR.
-/.setdefaultbgucr {
- systemdict /setblackgeneration known {
- { pop 0 } dup setblackgeneration setundercolorremoval
- } if
-} bind def
-/.useloresscreen { % - .useloresscreen <bool>
- % Compute min(|dpi x|,|dpi y|) as the definition of the resolution.
- 72 72 matrix defaultmatrix dtransform abs exch abs .min
- dup 150 lt //systemdict /DITHERPPI known not and
-} bind def
-
-% The following implementation uses LL2 extensions, but only in stopped
-% contexts so that with LL1, the .set??reshalftone will be used.
-%
-% - .getdefaulthalftone <halftonedict> true if default found
-% false
-/.getdefaulthalftone {
- % try the device to see if it has a default halftone
- { currentdevice /HalftoneDefault gsgetdeviceprop } .internalstopped
- { pop pop false } % no device property
- { dup type /dicttype eq { true } { pop false } ifelse }
- ifelse
- % stack: <halftonedict> true if default found
- % false not found
- dup not
- { % device did not provide a default, try Resource
- pop { /Default /Halftone /findresource .systemvar exec } .internalstopped
- { pop pop false } { true } ifelse
- }
- if
-} bind def
-
-/.setdefaulthalftone {
- .getdefaulthalftone
- { sethalftone }
- { % default not found
- .useloresscreen { .setloreshalftone } { .sethireshalftone pop } ifelse
- }
- ifelse
-} bind def
-
-/.setdefaultscreen {
- .useloresscreen { .setloresscreen } { .sethiresscreen } ifelse
- .setdefaultbgucr
-} bind def
-
-% Rendering intent mapping for setcolorrendering1 and PDF interpreter
-/.renderingintentdict mark
- /Perceptual 0
- /RelativeColorimetric 1
- /Saturation 2
- /AbsoluteColorimetric 3
-.dicttomark readonly def
-
-% Load basic color support
-%% Replace 1 (gs_cspace.ps)
-(gs_cspace.ps) runlibfile
-
-(END BASIC COLOR) VMDEBUG
-
-%% Replace 1 (gs_devcs.ps)
-(gs_devcs.ps) runlibfile
-
-(END LEVEL 1 COLOR) VMDEBUG
-
-% Load image support
-%% Replace 1 (gs_img.ps)
-(gs_img.ps) runlibfile
-
-(END IMAGE) VMDEBUG
-
-% Auxiliary procedures for generating file name templates.
-
-% Convert a path name into a string suitable for filenameforall
-% For example: (a\\b*?c) to (a\\\\b\\*\\?c)
-/.makepathtemplate { % str1 -- str2
- dup length dup add string 0 % result string up to twice the size
- 0 1 4 index length 1 sub {
- 3 index exch get
- dup 92 eq { % \ -> \\
- 2 index 2 index 92
- put
- exch 1 add exch
- }
- if
- dup 42 eq { % * -> \*
- 2 index 2 index 92
- put
- exch 1 add exch
- }
- if
- dup 63 eq { % ? -> \?
- 2 index 2 index 92
- put
- exch 1 add exch
- }
- if
- 2 index 2 index 3 -1 roll put 1 add
- } for
- 0 exch getinterval exch pop
-} bind def
-
-% false <dir_list> <template> .generate_dir_list_templates_with_length <t1> ... <tN>
-% true <dir_list> <template> .generate_dir_list_templates_with_length <t1> <l1> ... <tN> <ln>
-%
-% Generates various valid templates combining a directory list with a given template.
-% With 'true' operand it also returns lengths of directory pathes.
-%
-% Example1 (DOS, Windows) :
-% false [(/gs/lib) (/gs/Resource/) (\gs8.00\Resource)] (*/*) -->
-% (/gs/lib/*/*) (/gs/Resource/*/*) (\\gs8.00\\Resource/*/*)
-%
-% Example2 (OpenVMS) :
-% false [(gs:[lib]) (gs:[Resource]) (gs800:[Resource)] (*]*) -->
-% ((gs:[lib.*]*) [gs:[Resource.*]*) ([gs800:[Resource.*]*)
-%
-/.generate_dir_list_templates_with_length
-{ % [dl] (templ)
- % We need to convert paths into templates,
- % because it can include '\' on DOS.
- % In same time, the <template> must not convert,
- % because it is already a template.
- % Besides that, we cannot combine template using .file_name_combine,
- % because template syntax breaks the platform path syntax.
- % To resolve this, we first convert the <template> into
- % a fake filename, and combine it with path,
- % obtaining a correct separator. Then we replace
- % the fake file name with the given template.
- %
-
- % Create the fake file name :
- dup dup length string copy % b [dl] (templ) (ffn)
- (*) 0 get (?) 0 get (\\) 0 get (x) 0 get 0 0 % b [dl] (templ) (ffn) * ? \ x i j
- { 1 index 7 index length ge { exit } if
- 6 index 2 index get % b [dl] (templ) (ffn) * ? \ x i j c
- dup 7 index eq % b [dl] (templ) (ffn) * ? \ x i j c bool
- 1 index 7 index eq or { % *?
- pop 2 index
- } if % b [dl] (templ) (ffn) * ? \ x i j C
- dup 5 index eq { % \
- 3 2 roll 1 add 3 1 roll % b [dl] (templ) (ffn) * ? \ x i' j C
- 2 index 8 index length ge { pop exit } if
- pop 6 index 2 index get % b [dl] (templ) (ffn) * ? \ x i' j C'
- } if
- 7 index 2 index 3 2 roll put % b [dl] (templ) (ffn) * ? \ x i' j
- 1 add exch 1 add exch % b [dl] (templ) (ffn) * ? \ x i'' j'
- } loop % b [dl] (templ) (ffn) * ? \ x i j
- 6 1 roll pop % b [dl] (templ) (ffn) j * ? \ x
- exch pop exch pop exch pop exch % b [dl] (templ) (ffn) x j
- { dup 3 index length ge { exit } if
- 3 copy exch put
- 1 add
- } loop
- pop pop % b [dl] (templ) (ffn)
-
- % An internal procedure :
- { % {} b [dl] (templ) (ffn) (dffn)
- dup length
- 1 sub % drop 'x', which was added above.
- exch % {} b [dl] (templ) (ffn) ldffn (dffn)
- .makepathtemplate % {} b [dl] (templ) (ffn) ldffn (Dffn)
- dup % {} b [dl] (templ) (ffn) ldffn (Dffn) (Dffn)
- 4 index length dup % {} b [dl] (templ) (ffn) ldffn (Dffn) (Dffn) templL templL
- 2 index length % {} b [dl] (templ) (ffn) ldffn (Dffn) (Dffn) templL templL DffnL
- exch sub % {} b [dl] (templ) (ffn) ldffn (Dffn) (Dffn) templL i
- exch getinterval % {} b [dl] (templ) (ffn) ldffn (Dffn) (suffix)
- 4 index exch copy pop % {} b [dl] (templ) (ffn) ldffn (dt)
- 5 index {
- exch % {} b [dl] (templ) (ffn) (dt) ldffn
- 7 2 roll % (dt) ldffn {} b [dl] (templ) (ffn)
- } {
- exch pop % {} b [dl] (templ) (ffn) (dt)
- 6 1 roll % (dt) {} b [dl] (templ) (ffn)
- } ifelse
- }
- 5 1 roll % {} b [dl] (templ) (ffn)
-
- % Generate templates :
- dup .file_name_is_absolute {
- dup % {} b [dl] (templ) (ffn) (ffn)
- 5 index exec % (t1) {} b [dl] (templ) (ffn)
- } {
- 2 index { % ... {} b [dl] (templ) (ffn) (d)
- 1 index % ... {} b [dl] (templ) (ffn) (d) (ffn)
- false .file_name_combine { % ... {} b [dl] (templ) (ffn) (dffn)
- 5 index exec % ... (t1) ?l1 {} b [dl] (templ) (ffn)
- } { % ... {} b [dl] (templ) (ffn) (d) (ffn)
- pop pop % ... {} b [dl] (templ) (ffn)
- } ifelse
- } forall
- } ifelse % (t1) ?l1 (t2) ?l2 ... (tN) ?ln {} b [dl] (templ) (ffn)
- pop pop pop pop pop % (t1) ?l1 (t2) ?l2 ... (tN) ?ln
-} bind def
-
-% <dir_list> <template> .generate_dir_list_templates <t1> ... <tN>
-%
-% Generates various valid templates combining a directory list with a given template.
-% It's the 'false' case of the function above.
-%
-/.generate_dir_list_templates
-{ //false 3 1 roll //.generate_dir_list_templates_with_length exec
-} bind def
-
-% Load the initialization files for optional features.
-%% Replace 4 INITFILES
-systemdict /INITFILES known
- { INITFILES { dup runlibfile VMDEBUG } forall
- }
-if
-
-% If Level 2 (or higher) functionality is implemented, enable it now.
-/.setlanguagelevel where {
- pop 2 .setlanguagelevel
- % If the resource machinery is loaded, fix up some things now.
- /.fixresources where { pop .fixresources } if
-} if
-/ll3dict where {
- pop 3 .setlanguagelevel
-} if
-
-(END INITFILES) VMDEBUG
-
-% Create a null font. This is the initial font.
-8 dict dup begin
- /FontMatrix [ 1 0 0 1 0 0 ] readonly def
- /FontType 3 def
- /FontName () def
- /Encoding StandardEncoding def
- /FontBBox { 0 0 0 0 } readonly def % executable is bogus, but customary ...
- /BuildChar { pop pop 0 0 setcharwidth } bind def
- /PaintType 0 def % shouldn't be needed!
-end
-/NullFont exch definefont setfont
-
-% Define NullFont as the font.
-/NullFont currentfont def
-
-% Load initial fonts from FONTPATH directories, Fontmap file,
-% and/or .getccfont as appropriate.
-.loadinitialfonts
-
-% Remove NullFont from FontDirectory, so it can't be accessed by mistake.
-/undefinefont where {
- pop /NullFont undefinefont
-} {
- FontDirectory /NullFont .undef
-} ifelse
-
-(END FONTS) VMDEBUG
-
-% Restore the real definition of runlibfile.
-/runlibfile /.runlibfile load def
-currentdict /.runlibfile .undef
-
-% Bind all the operators defined as procedures.
-/.bindoperators % binds operators in currentdict
- { % Temporarily disable the typecheck error.
- errordict /typecheck 2 copy get
- errordict /typecheck { pop } put % pop the command
- currentdict
- { dup type /operatortype eq
- { % This might be a real operator, so bind might cause a typecheck,
- % but we've made the error a no-op temporarily.
- .bind % do a real bind even if NOBIND is set
- }
- if pop pop
- } forall
- put
- } def
-NOBIND DELAYBIND or not { .bindoperators } if
-
-% Establish a default environment.
-
-defaultdevice
-% The following line used to skip setting of page size and resolution if
-% NODISPLAY was selected. We think this was only to save time and memory,
-% and it is a bad idea because it prevents setting the resolution in this
-% situation, which pstoedit (among other programs) relies on.
-%DISPLAYING not { setdevice (%END DISPLAYING) .skipeof } if
-
-% If the paper size is not specifed and the device defaults to
-% letter or A4 paper, select the DEFAULTPAPERSIZE.
-systemdict /DEFAULTPAPERSIZE known
-systemdict /PAPERSIZE known not and
-systemdict /DEVICEWIDTH known not and
-systemdict /DEVICEHEIGHT known not and
-systemdict /DEVICEWIDTHPOINTS known not and
-systemdict /DEVICEHEIGHTPOINTS known not and
- {
- defaultdevice mark /PageSize //null .dicttomark .getdeviceparams
- .dicttomark /PageSize get
- dup 0 get 0.5 add cvi 612 eq 1 index 1 get 0.5 add cvi 792 eq and
- 1 index 0 get 0.5 add cvi 595 eq 2 index 1 get 0.5 add cvi 842 eq and
- or exch pop
- {
- % the default paper size was letter, so replace it with DEFAULTPAPERSIZE
- /PAPERSIZE DEFAULTPAPERSIZE def
- } if
- }
-if
-
-systemdict /DEVICEWIDTH known
-systemdict /DEVICEHEIGHT known or
-systemdict /DEVICEWIDTHPOINTS known or
-systemdict /DEVICEHEIGHTPOINTS known or
-systemdict /DEVICEXRESOLUTION known or
-systemdict /DEVICEYRESOLUTION known or
-systemdict /PAPERSIZE known or
-not { (%END DEVICE) .skipeof } if
-% Let DEVICE{WIDTH,HEIGHT}[POINTS] override PAPERSIZE.
-systemdict /PAPERSIZE known
-systemdict /DEVICEWIDTH known not and
-systemdict /DEVICEHEIGHT known not and
-systemdict /DEVICEWIDTHPOINTS known not and
-systemdict /DEVICEHEIGHTPOINTS known not and
- { % Convert the paper size to device dimensions.
- true statusdict /.pagetypenames get
- { PAPERSIZE eq
- { PAPERSIZE load
- dup 0 get /DEVICEWIDTHPOINTS exch def
- 1 get /DEVICEHEIGHTPOINTS exch def
- pop false exit
- }
- if
- }
- forall
- { (Unknown paper size: ) print PAPERSIZE ==only (.) =
- }
- if
- }
-if
-% Adjust the device parameters per the command line.
-% It is possible to specify resolution, pixel size, and page size;
-% since any two of these determine the third, conflicts are possible.
-% We simply pass them to .setdeviceparams and let it sort things out.
- mark /HWResolution //null /HWSize //null /PageSize //null .dicttomark
- .getdeviceparams .dicttomark begin
- mark
- % Check for resolution.
- /DEVICEXRESOLUTION where dup
- { exch pop HWResolution 0 DEVICEXRESOLUTION put }
- if
- /DEVICEYRESOLUTION where dup
- { exch pop HWResolution 1 DEVICEYRESOLUTION put }
- if
- or { /HWResolution HWResolution } if
- % Check for device sizes specified in pixels.
- /DEVICEWIDTH where dup
- { exch pop HWSize 0 DEVICEWIDTH put }
- if
- /DEVICEHEIGHT where dup
- { exch pop HWSize 1 DEVICEHEIGHT put }
- if
- or { /HWSize HWSize } if
- % Check for device sizes specified in points.
- /DEVICEWIDTHPOINTS where dup
- { exch pop PageSize 0 DEVICEWIDTHPOINTS put }
- if
- /DEVICEHEIGHTPOINTS where dup
- { exch pop PageSize 1 DEVICEHEIGHTPOINTS put }
- if
- or { /PageSize PageSize } if
- % Check whether any parameters were set.
- dup mark eq { pop } { defaultdevice putdeviceprops } ifelse
- end
-%END DEVICE
-% Set any device properties defined on the command line.
-% If BufferSpace is defined but not MaxBitmap, set MaxBitmap to BufferSpace.
-systemdict /BufferSpace known
-systemdict /MaxBitmap known not and
- { systemdict /MaxBitmap BufferSpace put
- } if
-dup getdeviceprops
-counttomark 2 idiv
- { systemdict 2 index known
- { pop dup load counttomark 2 roll }
- { pop pop }
- ifelse
- } repeat
-counttomark dup 0 ne
- { 2 add -1 roll putdeviceprops }
- { pop pop }
-ifelse
-% If the initial device parameters are invalid, the setdevice may fail.
-% Trap this and produce a reasonable error message.
-{ setdevice } % does an erasepage
-INITDEBUG { exec false } { .internalstopped } ifelse {
- (**** Unable to open the initial device, quitting.) = flush 1 .quit
-} if
-
-% If the media size is fixed, update the current page device dictionary.
-FIXEDMEDIA
-dup { pop systemdict /.currentpagedevice known } if
-dup { pop .currentpagedevice exch pop } if
-not { (%END MEDIA) .skipeof } if
-currentpagedevice dup length dict .copydict
-dup /Policies
- % Stack: <pagedevice> <pagedevice> /Policies
-1 index /InputAttributes
-2 copy get dup length dict .copydict
- % Stack: <pagedevice> <pagedevice> /Policies <pagedevice>
- % /InputAttributes <inputattrs'>
-dup 0 2 copy get dup length dict .copydict
- % Stack: <pagedevice> <pagedevice> /Policies <pagedevice>
- % /InputAttributes <inputattrs'> <inputattrs'> 0 <attrs0'>
-dup /PageSize 7 index /PageSize get
-put % PageSize in 0
-put % 0 in InputAttributes
-put % InputAttributes in pagedevice
-% Also change the page size policy so we don't get an error.
- % Stack: <pagedevice> <pagedevice> /Policies
-2 copy get dup length dict .copydict
- % Stack: <pagedevice> <pagedevice> /Policies <policies'>
-dup /PageSize 7 put % PageSize in Policies
-put % Policies in pagedevice
-.setpagedevice
-%END MEDIA
-
-% Set up the interpreter context version of -dUSeCIEColor option
-% so that .getuseciecolor has the correct value (see gs_setpd.ps)
-/setpagedevice where {
- pop systemdict /UseCIEColor known {
- mark /UseCIEColor UseCIEColor .dicttomark setpagedevice
- } if
-} if
-
-%END DISPLAYING
-
-(END DEVICE) VMDEBUG
-
-% Establish a default upper limit in the character cache,
-% namely, enough room for a 18-point character at the resolution
-% of the default device, or for a character consuming 1% of the
-% maximum cache size, whichever is larger.
-mark
- % Compute limit based on character size.
- 18 dup dtransform
- exch abs cvi 31 add 32 idiv 4 mul % X raster
- exch abs cvi mul % Y
- % Compute limit based on allocated space.
- cachestatus pop pop pop pop pop exch pop 0.01 mul cvi
- .max dup 10 idiv exch
-setcacheparams
-% Conditionally disable the character cache.
-NOCACHE { 0 setcachelimit } if
-
-(END CONFIG) VMDEBUG
-
-% Initialize graphics.
-
-.setdefaultscreen
-initgraphics
-
-% The interpreter relies on there being at least 2 entries
-% on the graphics stack. Establish the second one now.
-gsave
-
-% Define some control sequences as no-ops.
-% This is a hack to get around problems
-% in some common PostScript-generating applications.
-<04> cvn JOBSERVER {
- { { clear cleardictstack //false 0 .startnewjob } 2 .stop } bind
- } {
- { }
- } ifelse def
-<1b> cvn { % UEL is <esc>%-12345X and acts the same as ^D
- currentfile (%-12345X) .peekstring pop (%-12345X) eq <04> cvn load if
-} bind def
-<1b45> cvn { } def % PJL reset prologue (ESC E)
-<1b451b> cvn <1b> cvn load def % PJL reset epilogue (ESC E + UEL)
-(\001M) cvn % TBCP initiator
- { currentfile /TBCPDecode filter cvx exec
- } bind def
-/@PJL % H-P job control
- {
- % Windows 2000 driver includes PJL into %%BeginFeature block.
- % Identify this from the pattern on the stack: countdictstack lucas mark
- % and fail the feature request.
-
- count 3 ge {
- dup mark eq {
- 2 index countdictstack eq {
- 1 index /lucas where { /lucas get eq } { pop false } ifelse {
- stop
- } if
- } if
- } if
- } if
- currentfile //=string readline pop pop
- } bind def
-
-% Install the EPS handler if needed
-systemdict /EPSBoundingBoxInit known { EPSBoundingBoxInit } if
-
-% If we want a "safer" system, disable some obvious ways to cause havoc.
-.currentglobal true .setglobal
-/SAFETY 2 dict
- dup /safe false put
- dup /tempfiles 10 dict readonly put
-readonly def
-.setglobal
-
-/.locksafe {
- SAFETY /safe get not {
- <<
- /PermitFileReading [
- currentuserparams /PermitFileReading get aload pop
- /FONTPATH .systemvar (*) .generate_dir_list_templates
- % Library files :
- /LIBPATH .systemvar (*) .generate_dir_list_templates
- % Resource files on OpenVMS requires a separate template (gs:[dir.*]*)
- % because the (gs:[dir]*) doesn't cover them.
- /LIBPATH .systemvar (*) .file_name_separator (*)
- concatstrings concatstrings .generate_dir_list_templates
- .languagelevel 2 ge {
- % Default resources :
- [ currentsystemparams /GenericResourceDir get] (*) .generate_dir_list_templates
- % Default resources (OpenVMS, see comment above.) :
- [ currentsystemparams /GenericResourceDir get] (*) .file_name_separator (*)
- concatstrings concatstrings .generate_dir_list_templates
- } if
- ]
- /LockFilePermissions true
- >> setuserparams
- }
- if
- % setpagedevice has the side effect of clearing the page, but
- % we will just document that. Using setpagedevice keeps the device
- % properties and pagedevice .LockSafetyParams in agreement even
- % after a restore that changes the value to false.
- currentglobal currentpagedevice gcheck setglobal % use correct VM space
- << /.LockSafetyParams true >> setpagedevice
- setglobal
- //SAFETY /safe //true .forceput % overrides readonly
-} .bind executeonly odef
-
-/.setsafe
-{
- SAFETY /safe get not {
- <<
- /PermitFileReading [ ]
- /PermitFileWriting [ ]
- /PermitFileControl [ ]
- >> setuserparams
- }
- if
- .locksafe
-} .bind executeonly odef
-
-/deletefile {
- dup { deletefile } stopped {
- pop //deletefile $error /errorname get signalerror
- } {
- % deletefile succeeded. Remove from tempfile list if present
- //SAFETY /tempfiles get exch cvn 2 copy known {
- .forceundef
- } {
- pop pop
- }
- ifelse
- }
- ifelse
-} .bind executeonly odef
-
-% If a file is opened with .tempfile with SAFER not (yet) set,
-% the file can be deleted later, even if SAFER is set.
-/.tempfile {
- .tempfile % filename file
- //SAFETY /tempfiles get 2 .argindex true .forceput
-} .bind executeonly odef
-
-% If we are running in SAFER mode, lock things down
-SAFER { .setsafe } if
-
-% If we delayed binding, make it possible to do it later.
-/.bindnow {
- currentuserparams /IdiomRecognition .knownget {
- 1 dict dup /IdiomRecognition //false put setuserparams
- } if
- //systemdict begin .bindoperators end
- % Temporarily disable the typecheck error.
- errordict /typecheck 2 copy get
- errordict /typecheck { pop } put % pop the command
- 0 1 .delaycount 1 sub { .delaybind exch get .bind pop } for
- //systemdict /.delaybind {} .forceput % reclaim the space
- //systemdict /.bindnow .forceundef % ditto
- put
- //systemdict /.forcecopynew .forceundef % remove temptation
- //systemdict /.forcedef .forceundef % ditto
- //systemdict /.forceput .forceundef % ditto
- //systemdict /.forceundef .forceundef % ditto
- currentuserparams /IdiomRecognition known {
- 1 dict dup /IdiomRecognition 4 -1 roll put setuserparams
- } if
-} .bind odef
-
-% Turn off array packing, since some PostScript code assumes that
-% procedures are writable.
-false setpacking
-
-(END INIT) VMDEBUG
-
-/.currentuserparams where {
- pop
- % Remove real user params from psuserparams.
- mark .currentuserparams counttomark 2 idiv {
- pop psuserparams exch undef
- } repeat pop
- % Update the copy of the user parameters.
- mark .currentuserparams counttomark 2 idiv {
- userparams 3 1 roll .forceput % userparams is read-only
- } repeat pop
- % Turn on idiom recognition, if available.
- currentuserparams /IdiomRecognition known {
- /IdiomRecognition true .definepsuserparam
- } if
- psuserparams readonly pop
- systemdict /.definepsuserparam undef
- % Save a copy of userparams for use with save/restore
- % (and, if implemented, context switching).
- .currentglobal false .setglobal
- mark userparams { } forall .dicttomark readonly
- /userparams exch .forcedef % systemdict is read-only
- .setglobal
-} if
-/.currentsystemparams where {
- pop
- % Remove real system params from pssystemparams.
- mark .currentsystemparams counttomark 2 idiv {
- pop pssystemparams exch .forceundef
- } repeat pop
-} if
-
-% Set up AlignToPixels :
-
-/AlignToPixels where {
- mark /AlignToPixels 2 index /AlignToPixels get .dicttomark setuserparams
- /AlignToPixels undef
-} if
-
-% Set up GridFitTT :
-
-/GridFitTT where {
- mark /GridFitTT 2 index /GridFitTT get .dicttomark setuserparams
- /GridFitTT undef
-} if
-
-% Establish local VM as the default.
-false /setglobal where { pop setglobal } { .setglobal } ifelse
-$error /.nosetlocal false put
-
-(END GLOBAL) VMDEBUG
-
-/.savelocalstate where {
- % If we might create new contexts, save away copies of all dictionaries
- % referenced from systemdict that are stored in local VM,
- % and also save a copy of the initial gstate.
- pop .savelocalstate
-} {
- % If we're *not* running in a multi-context system and FAKEFONTS is
- % defined, add the fake fonts to LocalFontDirectory.
- .definefakefonts % current VM is local
-} ifelse
-
-% Execute scheduled inits :
-//.execute_scheduled_inits exec
-currentdict /.execute_scheduled_inits undef
-currentdict /.delayed_init_queue undef
-
-% Make global and local FontDirectory read-only.
-FontDirectory readonly pop
-/GlobalFontDirectory where { pop GlobalFontDirectory readonly pop } if
-
-% Remove systemdict entries for things that have been bound in where used
-% and that shouldn't be accessible by name, and close up systemdict.
-currentdict /filterdict .undef
-currentdict /.cidfonttypes .undef
-currentdict /.colorrenderingtypes .undef
-currentdict /.formtypes .undef
-currentdict /.halftonetypes .undef
-currentdict /.imagetypes .undef
-currentdict /.imagemasktypes .undef
-currentdict /.patterntypes .undef
-currentdict /.shadingtypes .undef
-currentdict /.wheredict .undef
-currentdict /.renderingintentdict .undef
-end
-
-% Clean up VM, and enable GC.
-/vmreclaim where
- { pop NOGC not { 2 vmreclaim 0 vmreclaim } if
- } if
-DELAYBIND not {
- systemdict /.forcecopynew .undef % remove temptation
- systemdict /.forcedef .undef % ditto
- systemdict /.forceput .undef % ditto
- systemdict /.forceundef .undef % ditto
-} if
-% Move superexec to internaldict if superexec is defined.
-currentdict /superexec .knownget {
- 1183615869 internaldict /superexec 3 -1 roll put
- currentdict /superexec .undef
-} if
-WRITESYSTEMDICT not { systemdict readonly pop } if
-(END GC) VMDEBUG
-
-% The Adobe AGM_Core used by Illustrator 9 has some code that breaks
-% if the 'product' is not (Adobe PostScript Parser). A bug has been
-% submitted to Adobe since this also fails with Acrobat Distiller.
-% As a temporary work around, the following HACK will work for
-% devices without spot color support. Once Ghostscript can
-% support DeviceN and spot color separations this will need to
-% be 'true' in some cases.
-userdict /AGM_preserve_spots false put
-
-% The interpreter will run the initial procedure (start).
diff --git a/Master/tlpkg/tlgs/lib/gs_kanji.ps b/Master/tlpkg/tlgs/lib/gs_kanji.ps deleted file mode 100644 index db7e83acbba..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_kanji.ps +++ /dev/null @@ -1,158 +0,0 @@ -% Copyright (C) 1994, 1995, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_kanji.ps 6300 2005-12-28 19:56:24Z giles $
-% Scaffolding for Kanji fonts. This is based on the Wadalab free font
-% from the University of Tokyo; it may not be appropriate for other
-% Kanji fonts.
-
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-
-% Define the encoding for the root font.
-
-/KanjiEncoding
-% \x00
- 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0
-% \x20
- 0 1 2 3 4 5 6 7
- 8 0 0 0 0 0 0 0
- 9 10 11 12 13 14 15 16
- 17 18 19 20 21 22 23 24
-% \x40
- 25 26 27 28 29 30 31 32
- 33 34 35 36 37 38 39 40
- 41 42 43 44 45 46 47 48
- 49 50 51 52 53 54 55 56
-% \x60
- 57 58 59 60 61 62 63 64
- 65 66 67 68 69 70 71 72
- 73 74 75 76 77 0 0 0
- 0 0 0 0 0 0 0 0
-% \x80
- 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0
-% \xA0
- 0 1 2 3 4 5 6 7
- 8 0 0 0 0 0 0 0
- 9 10 11 12 13 14 15 16
- 17 18 19 20 21 22 23 24
-% \xC0
- 25 26 27 28 29 30 31 32
- 33 34 35 36 37 38 39 40
- 41 42 43 44 45 46 47 48
- 49 50 51 52 53 54 55 56
-% \xE0
- 57 58 59 60 61 62 63 64
- 65 66 67 68 69 70 71 72
- 73 74 75 76 77 0 0 0
- 0 0 0 0 0 0 0 0
-256 packedarray def
-
-% Define a stub for the base font encoding.
-
- /KanjiSubEncoding { /KanjiSubEncoding .findencoding } bind def
-%% Replace 3 (gs_ksb_e.ps)
- EncodingDirectory /KanjiSubEncoding
- { (gs_ksb_e.ps) //systemdict begin runlibfile KanjiSubEncoding end }
- bind put
-
-% Support procedures and data.
-
-/T1FontInfo 8 dict begin
- /version (001.001) readonly def
- /FullName (KanjiBase) readonly def
- /FamilyName (KanjiBase) readonly def
- /Weight (Medium) readonly def
- /ItalicAngle 0 def
- /isFixedPitch false def
- /UnderlinePosition 0 def
- /UnderlineThickness 0 def
-currentdict end readonly def
-
-/T1NF % <fontname> T1NF <font>
-{
-20 dict begin
- /FontName exch def
- /FontType 1 def
- /FontInfo T1FontInfo def
- /FontMatrix [.001 0 0 .001 0 0] def
- /FontBBox [0 0 1000 1000] def
- /Encoding KanjiSubEncoding def
- /CharStrings 150 dict def
- /PaintType 0 def
- /Private 2 dict def
- Private begin
- /BlueValues [] def
- /password 5839 def
- end
-FontName currentdict end definefont
-} def
-
-/T0NF % <fontname> T0NF <font>
-{
-20 dict begin
- /FontName exch def
- /FDepVector exch def
- /FontType 0 def
- /FontMatrix [1 0 0 1 0 0] def
- /FMapType 2 def
- /Encoding KanjiEncoding def
-FontName currentdict end definefont
-} def
-
-% Define the composite font and all the base fonts.
-
-/CompNF % <fontname> CompNF <font>
-{
-/newname1 exch def
-newname1 dup length string cvs /str exch def
-str length /len exch def
-/fdepvector 78 array def
-/j 1 def
-16#21 1 16#74 {
-/i exch def
-KanjiEncoding i get 0 gt {
-len 4 add string /newstr exch def
-newstr 0 str putinterval
-newstr len (.r) putinterval
-newstr len 2 add i 16 2 string cvrs putinterval
-newstr cvn /newlit exch def
-newlit T1NF /newfont exch def
-fdepvector j newfont put
-/j j 1 add def
-} if
-} for
-fdepvector 0 fdepvector 1 get put
-/j 0 def
-fdepvector newname1 T0NF
-} def
-
-% Define an individual character in a composite font.
-/CompD % <charstring> <(HL)> CompD -
- { currentfont /Encoding get 1 index 0 get get % FDepVector index
- currentfont /FDepVector get exch get % base font
- dup /Encoding get 3 -1 roll 1 get get % base font character name
- exch /CharStrings get exch 3 -1 roll put
- } bind def
-
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_ksb_e.ps b/Master/tlpkg/tlgs/lib/gs_ksb_e.ps deleted file mode 100644 index cba2f588f2b..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_ksb_e.ps +++ /dev/null @@ -1,64 +0,0 @@ -% Copyright (C) 1994 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_ksb_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the KanjiSub encoding vector.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/KanjiSubEncoding
-%\x00
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-%\x20
- /.notdef /c21 /c22 /c23 /c24 /c25 /c26 /c27
- /c28 /c29 /c2A /c2B /c2C /c2D /c2E /c2F
- /c30 /c31 /c32 /c33 /c34 /c35 /c36 /c37
- /c38 /c39 /c3A /c3B /c3C /c3D /c3E /c3F
-%\x40
- /c40 /c41 /c42 /c43 /c44 /c45 /c46 /c47
- /c48 /c49 /c4A /c4B /c4C /c4D /c4E /c4F
- /c50 /c51 /c52 /c53 /c54 /c55 /c56 /c57
- /c58 /c59 /c5A /c5B /c5C /c5D /c5E /c5F
-%\x60
- /c60 /c61 /c62 /c63 /c64 /c65 /c66 /c67
- /c68 /c69 /c6A /c6B /c6C /c6D /c6E /c6F
- /c70 /c71 /c72 /c73 /c74 /c75 /c76 /c77
- /c78 /c79 /c7A /c7B /c7C /c7D /c7E /.notdef
-%\x80
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-%\xA0
- /.notdef /c21 /c22 /c23 /c24 /c25 /c26 /c27
- /c28 /c29 /c2A /c2B /c2C /c2D /c2E /c2F
- /c30 /c31 /c32 /c33 /c34 /c35 /c36 /c37
- /c38 /c39 /c3A /c3B /c3C /c3D /c3E /c3F
-%\xC0
- /c40 /c41 /c42 /c43 /c44 /c45 /c46 /c47
- /c48 /c49 /c4A /c4B /c4C /c4D /c4E /c4F
- /c50 /c51 /c52 /c53 /c54 /c55 /c56 /c57
- /c58 /c59 /c5A /c5B /c5C /c5D /c5E /c5F
-%\xE0
- /c60 /c61 /c62 /c63 /c64 /c65 /c66 /c67
- /c68 /c69 /c6A /c6B /c6C /c6D /c6E /c6F
- /c70 /c71 /c72 /c73 /c74 /c75 /c76 /c77
- /c78 /c79 /c7A /c7B /c7C /c7D /c7E /.notdef
-256 packedarray .defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_l.xbm b/Master/tlpkg/tlgs/lib/gs_l.xbm deleted file mode 100644 index 4f9de445487..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_l.xbm +++ /dev/null @@ -1,29 +0,0 @@ -#define gs_l.xbm_width 48
-#define gs_l.xbm_height 48
-#define gs_l.xbm_x_hot 0
-#define gs_l.xbm_y_hot 0
-static unsigned char gs_l.xbm_bits[] = {
- 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd0, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0xa0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x20, 0x03, 0x00,
- 0x00, 0x00, 0x00, 0x3e, 0x03, 0x00, 0x00, 0x00, 0xff, 0x1f, 0x07, 0x00,
- 0x00, 0xe0, 0xff, 0x0f, 0x07, 0x00, 0x00, 0xf8, 0xff, 0x81, 0x07, 0x00,
- 0x00, 0xfc, 0x1f, 0xc0, 0x0f, 0x00, 0x00, 0xfe, 0x07, 0xf0, 0x1f, 0x00,
- 0x00, 0xff, 0x01, 0xf8, 0x1f, 0x00, 0x00, 0xff, 0x41, 0xfc, 0x3f, 0x00,
- 0x80, 0xff, 0xc8, 0xfc, 0x3f, 0x00, 0x80, 0xff, 0xd8, 0xf8, 0x3f, 0x00,
- 0x80, 0xff, 0x98, 0xf0, 0x3f, 0x00, 0x80, 0xff, 0x10, 0xe0, 0x3f, 0x00,
- 0x00, 0xff, 0x01, 0xc0, 0x3f, 0x00, 0x00, 0xff, 0x81, 0x81, 0x1f, 0x00,
- 0x00, 0xfe, 0x83, 0x83, 0x1f, 0x00, 0x00, 0xfc, 0x0f, 0x83, 0x0f, 0x00,
- 0x00, 0xf8, 0x1f, 0xc3, 0x03, 0x00, 0x00, 0xe0, 0x1f, 0xe0, 0x01, 0x00,
- 0x00, 0xf0, 0x1f, 0x38, 0x00, 0x00, 0x00, 0xfc, 0x0f, 0x00, 0x00, 0x00,
- 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x80, 0x7f, 0x00, 0x00, 0x00, 0x00,
- 0xc0, 0xff, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0xff, 0x00, 0x00, 0x00,
- 0xc0, 0xff, 0xff, 0xff, 0x01, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x0f, 0x00,
- 0x80, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0x00,
- 0x00, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x03,
- 0x00, 0xc0, 0xff, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x03,
- 0xc0, 0x3f, 0x00, 0x00, 0xff, 0x03, 0xe0, 0x0f, 0x00, 0x00, 0xfe, 0x03,
- 0xf0, 0x07, 0xfc, 0x00, 0xfc, 0x01, 0xf0, 0x07, 0x0e, 0x00, 0xff, 0x04,
- 0xf0, 0x07, 0x7e, 0xe0, 0x7f, 0x02, 0xf0, 0x0f, 0xfc, 0xff, 0x1f, 0x01,
- 0xe0, 0x1f, 0xf0, 0xff, 0xc3, 0x00, 0xc0, 0xff, 0x00, 0x00, 0x78, 0x00,
- 0x80, 0xff, 0x0f, 0xf8, 0x3f, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00,
- 0x00, 0xe0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/Master/tlpkg/tlgs/lib/gs_l.xpm b/Master/tlpkg/tlgs/lib/gs_l.xpm deleted file mode 100644 index ef898c29c8c..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_l.xpm +++ /dev/null @@ -1,58 +0,0 @@ -/* XPM */
-static char * gs_l_xpm[] = {
-/* width height ncolors cpp [x_hot y_hot] */
-"48 48 4 1 0 0",
-/* colors */
-" s none m none c none",
-". s iconColor1 m black c black",
-"X s iconColor2 m white c white",
-"o s iconColor5 m black c blue",
-/* pixels */
-" . ",
-" .X.. ",
-" .X.. ",
-" .XX.. ",
-" .....XX.. ",
-" .............XXX... ",
-" ...............XXXX... ",
-" ..............XXXXXX.... ",
-" ...........XXXXXXXXX...... ",
-" ..........XXXXXXXXX......... ",
-" .........XXXXXXXXXX.......... ",
-" .........XXXXXoXXX............ ",
-" .........XXXoXXooXX............ ",
-" .........XXXooXooXXX........... ",
-" .........XXXooXXoXXXX.......... ",
-" .........XXXXoXXXXXXXX......... ",
-" .........XXXXXXXXXXXXX........ ",
-" .........XXXXXXooXXXXXX...... ",
-" .........XXXXXoooXXXXX...... ",
-" ..........XXXXooXXXXX..... ",
-" ..........XXXooXXXX.... ",
-" ........XXXXXXXX.... ",
-" .........XXXXXX... ",
-" ..........XXXXXXX ",
-" ........XXXXXXXXXXXX ",
-" ........XXXXXXXXXXXXXX ",
-" ..........XXXXXXXXXXXXXXX ",
-" ..................XXXXXXXXX ",
-" ...........................X ",
-" .............................. ",
-" ................................ ",
-" ................................. ",
-" ................................. ",
-" ................................ ",
-" ............................ ",
-" XXXXXXXXXXXXX.............. ",
-" ........XXXXXXXXXXXXXXXXXX.......... ",
-" .......XXXXXXXXXXXXXXXXXXXXX......... ",
-" .......XXXXXXX......XXXXXXXXXX.......X ",
-" .......XXXXXX...XXXXXXXXXXXX........XX. ",
-" .......XXXXXX......XXXXXX..........XX. ",
-" ........XXXXXX...................XXX. ",
-" ........XXXXXXX..............XXXX.. ",
-" ..........XXXXXXXXXXXXXXXXXXX.... ",
-" .............XXXXXXX........... ",
-" .......................... ",
-" ................... ",
-" "};
diff --git a/Master/tlpkg/tlgs/lib/gs_l2img.ps b/Master/tlpkg/tlgs/lib/gs_l2img.ps deleted file mode 100644 index 877044e6f9b..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_l2img.ps +++ /dev/null @@ -1,184 +0,0 @@ -% Copyright (C) 1995, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_l2img.ps 6300 2005-12-28 19:56:24Z giles $
-% Emulate the Level 2 dictionary-based image operator in Level 1,
-% except for Interpolate (ignored) and MultipleDataSources = true;
-% also, we require that the data source be either a procedure of a
-% particular form or a stream, not a string or a general procedure.
-
-% pdf2ps copies the portion of this file from %BEGIN to %END if Level 1
-% compatible output is requested.
-
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-
-/packedarray where
- { pop }
- { /packedarray { array astore readonly } bind def }
-ifelse
-
-%BEGIN
-
-11 dict /.csncompdict 1 index def begin
- /DeviceGray { 1 /setgray load } bind def
- /DeviceRGB { 3 /setrgbcolor load } bind def
- /DeviceCMYK { 4 /setcmykcolor load } bind def
- /Indexed
- { dup 1 index 1 get //.csncompdict exch get exec
- % Stack: [/Indexed base hival map] ncomp basesetcolor
- 3 -1 roll 3 get mark 3 1 roll
- % Stack: ncomp -mark- basesetcolor map
- dup type /stringtype eq
- { { -
- { exch round cvi get 255 div
- }
- -
- { exch round cvi 3 mul 2 copy 2 copy get 255 div
- 3 1 roll 1 add get 255 div
- 4 2 roll 2 add get 255 div
- }
- { exch round cvi 4 mul 2 copy 2 copy 2 copy get 255 div
- 3 1 roll 1 add get 255 div
- 4 2 roll 2 add get 255 div
- 5 3 roll 3 add get 255 div
- }
- }
- 4 index get aload pop counttomark -1 roll
- }
- { /exec load 3 -1 roll
- % Stack: -mark- mapproc --exec-- basesetcolor
- }
- ifelse .packtomark cvx
- exch pop 1 exch
- } bind def
- /Separation
- { dup 2 index //.csncompdict exch get exec
- % Stack: [/Separation name alt xform] ncomp altsetcolor
- 3 -1 roll 3 get /exec load 3 -1 roll 3 array astore readonly cvx
- exch pop 1 exch
- } bind def
- % Substitute device spaces for CIE spaces.
- /CIEBasedA /DeviceGray load def
- /CIEBasedABC /DeviceRGB load def
- /CIEBasedDEF /DeviceRGB load def
- /CIEBasedDEFG /DeviceCMYK load def
-end
-
-/.packtomark { counttomark packedarray exch pop } bind def
-
-/.csinextbits % - .csinextbits <bits>
- % Uses b, nnb, i, row, mask, BitsPerComponent;
- % sets b, nnb, i.
- { /nnb nnb BitsPerComponent add
- { dup 0 le { exit } if
- /b b 8 bitshift row i get add def
- /i i 1 add def 8 sub
- }
- loop def
- b nnb bitshift mask and
- } bind def
-
-% Note that the ColorSpace key must be present in the image dictionary.
-/.colorspaceimage % <imagedict> .colorspaceimage -
- { save exch
- dup length 15 add dict begin { cvlit def } forall
- ColorSpace dup dup type /nametype ne { 0 get } if
- .csncompdict exch get exec
- /setpixelcolor exch def /ncomp exch def pop
- /row ncomp BitsPerComponent mul Width mul 7 add 8 idiv string def
- /mask 1 BitsPerComponent bitshift 1 sub def
- /nextbits BitsPerComponent 8 eq
- { { row i get /i i 1 add def } }
- { /.csinextbits load }
- ifelse def
- /nextpixel mark 0 2 ncomp 1 sub 2 mul
- { /nextbits cvx exch
- Decode exch 2 getinterval
- dup aload pop exch sub
- dup mask eq { pop } { mask div /mul load 3 -1 roll } ifelse
- 0 get dup 0 eq { pop } { /sub load 3 -1 roll } ifelse
- }
- for
- /setpixelcolor load dup type /operatortype ne { /exec load } if
- .packtomark cvx def
- /readrow
- /DataSource load dup type
- dup /arraytype eq exch /packedarraytype eq or
- { % Must be { <file> <string> ... }
- aload length 1 add array /pop load exch astore
- dup 1 row put cvx
- }
- { pop
- % Adobe requires readstring to signal an error if given
- % an empty string. Work around this nonsense here.
- row length 0 eq
- { { } }
- { { DataSource row readstring pop pop } }
- ifelse
- }
- ifelse def
- ImageMatrix matrix invertmatrix concat
- /imat matrix def
- 0 1 Height 1 sub
- { imat 5 3 -1 roll neg put
- readrow
- /b 0 def /nnb 0 def /i 0 def
- 0 1 Width 1 sub
- { imat 4 3 -1 roll neg put nextpixel
- 1 1 true imat {<80>} imagemask
- }
- for
- }
- for
- end restore
- } bind def
-
-%END
-exec
-currentfile closefile
-
-% Patch for testing.
-/.cincompdict 3 dict begin
- 1 { {0 1} {/DeviceGray} } def
- 3 { {0 1 0 1 0 1} {/DeviceRGB} } def
- 4 { {0 1 0 1 0 1 0 1} {/DeviceCMYK} } def
-currentdict end def
-/.imagekeys [
- /Decode /DataSource /ImageMatrix /BitsPerComponent /Height /Width
-] def
-/colorimage % <width> <height> <bits/comp> <matrix>
- % <datasrc> false <ncomp> colorimage -
- { 1 index { /colorimage .systemvar /rangecheck signalerror } if exch pop
- //.cincompdict exch get exec
- 7 dict begin /ColorSpace exch cvlit def
- .imagekeys { exch cvlit def } forall
- currentdict end .colorspaceimage
- } bind odef
-/image
- { dup type /dicttype ne
- { 7 dict begin /ColorSpace /DeviceGray def [0 1]
- .imagekeys { exch cvlit def } forall
- currentdict end
- }
- { dup length 1 add dict .copydict dup /ColorSpace currentcolorspace put
- }
- ifelse
- .colorspaceimage
- } bind odef
-
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_l_m.xbm b/Master/tlpkg/tlgs/lib/gs_l_m.xbm deleted file mode 100644 index 0253814e7b0..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_l_m.xbm +++ /dev/null @@ -1,29 +0,0 @@ -#define gs_l_m.xbm_width 48
-#define gs_l_m.xbm_height 48
-#define gs_l_m.xbm_x_hot 0
-#define gs_l_m.xbm_y_hot 0
-static unsigned char gs_l_m.xbm_bits[] = {
- 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0xe0, 0x01, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 0x00,
- 0x00, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x00, 0xff, 0xff, 0x07, 0x00,
- 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x07, 0x00,
- 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x1f, 0x00,
- 0x00, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00,
- 0x80, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x80, 0xff, 0xff, 0xff, 0x3f, 0x00,
- 0x80, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x80, 0xff, 0xff, 0xff, 0x3f, 0x00,
- 0x00, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xff, 0xff, 0xff, 0x1f, 0x00,
- 0x00, 0xfe, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xfc, 0xff, 0xff, 0x0f, 0x00,
- 0x00, 0xf8, 0xff, 0xff, 0x03, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x01, 0x00,
- 0x00, 0xf0, 0xff, 0x3f, 0x00, 0x00, 0x00, 0xfc, 0xff, 0x07, 0x00, 0x00,
- 0x00, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x80, 0xff, 0xff, 0x1f, 0x00, 0x00,
- 0xc0, 0xff, 0xff, 0x7f, 0x00, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x01, 0x00,
- 0xc0, 0xff, 0xff, 0xff, 0x03, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x0f, 0x00,
- 0x80, 0xff, 0xff, 0xff, 0x7f, 0x00, 0x80, 0xff, 0xff, 0xff, 0xff, 0x00,
- 0x00, 0xff, 0xff, 0xff, 0xff, 0x01, 0x00, 0xfc, 0xff, 0xff, 0xff, 0x03,
- 0x00, 0xc0, 0xff, 0xff, 0xff, 0x03, 0x00, 0x80, 0xff, 0xff, 0xff, 0x03,
- 0xc0, 0xff, 0xff, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0xff, 0xff, 0x03,
- 0xf0, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x07,
- 0xf0, 0xff, 0xff, 0xff, 0xff, 0x03, 0xf0, 0xff, 0xff, 0xff, 0xff, 0x01,
- 0xe0, 0xff, 0xff, 0xff, 0xff, 0x00, 0xc0, 0xff, 0xff, 0xff, 0x7f, 0x00,
- 0x80, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x00,
- 0x00, 0xe0, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/Master/tlpkg/tlgs/lib/gs_lev2.ps b/Master/tlpkg/tlgs/lib/gs_lev2.ps deleted file mode 100644 index 468ad54d455..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_lev2.ps +++ /dev/null @@ -1,1013 +0,0 @@ -% Copyright (C) 1990, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_lev2.ps 8174 2007-08-04 14:30:04Z alexcher $
-% Initialization file for Level 2 functions.
-% When this is run, systemdict is still writable,
-% but (almost) everything defined here goes into level2dict.
-
-level2dict begin
-
-% ------ System and user parameters ------ %
-
-% User parameters must obey save/restore, and must also be maintained
-% per-context. We implement the former, and some of the latter, here
-% with PostScript code. NOTE: our implementation assumes that user
-% parameters change only as a result of setuserparams -- that there are
-% no user parameters that are ever changed dynamically by the interpreter
-% (although the interpreter may adjust the value presented to setuserparams)
-%
-% There are two types of user parameters: those which are actually
-% maintained in the interpreter, and those which exist only at the
-% PostScript level. We maintain the current state of both types in
-% a read-only local dictionary named userparams, defined in systemdict.
-% In a multi-context system, each context has its own copy of this
-% dictionary. In addition, there is a constant dictionary named
-% psuserparams where each key is the name of a user parameter that exists
-% only in PostScript and the value is a procedure to check that the value
-% is legal: setuserparams uses this for checking the values.
-% setuserparams updates userparams explicitly, in addition to setting
-% any user parameters in the interpreter; thus we can use userparams
-% to reset those parameters after a restore or a context switch.
-% NOTE: the name userparams is known to the interpreter, and in fact
-% the interpreter creates the userparams dictionary.
-
-% Check parameters that are managed at the PostScript level.
-/.checkparamtype { % <newvalue> <type> .checkparamtype <bool>
- exch type eq
-} .bind def
-/.checksetparams { % <newdict> <opname> <checkdict>
- % .checksetparams <newdict>
- 2 .argindex {
- % Stack: newdict opname checkdict key newvalue
- 3 copy 3 1 roll .knownget {
- exec not {
- pop pop pop load /typecheck signalerror
- } if
- dup type /stringtype eq {
- dup rcheck not {
- pop pop pop load /invalidaccess signalerror
- } if
- } if
- } {
- pop
- } ifelse pop pop
- } forall pop pop
-} .bind def % not odef, shouldn't reset stacks
-
-% currentuser/systemparams creates and returns a dictionary in the
-% current VM. The easiest way to make this work is to copy any composite
-% PostScript-level parameters to global VM. Currently we have strings
-% as well as arrays. For arrays, we also need to copy any contents that
-% are in VM. Also copying string parameters insures the contents won't
-% be changed. Also be careful to preserve 'executable' state.
-/.copyparam { % <value> .copyparam <value'>
- dup type /arraytype eq {
- .currentglobal true .setglobal exch
- dup wcheck exch dup xcheck exch % original attributes
- dup length array exch dup { % stack: destination_array original_array original_array
- dup type /arraytype eq {
- dup 2 index ne { % avoid recursion
- .copyparam % recurse to handle composite array elements
- } {
- % this array self referenced, do it again (yuk!)
- pop 1 index % get copy of destination array
- } ifelse
- } {
- dup type /stringtype eq {
- .copyparam
- } if
- }
- ifelse 3 1 roll % keep arrays on top
- } forall pop astore
- exch { cvx } if % set executable state
- exch not { readonly } if % set readonly attribute as original
- exch .setglobal
- } if
- dup type /stringtype eq {
- dup wcheck exch % save attr for setting readonly
- .currentglobal true .setglobal
- 1 index length string exch .setglobal
- copy exch not { readonly } if
- } if
-} .bind def
-
-% Some user parameters are managed entirely at the PostScript level.
-% We take care of that here.
-systemdict begin
-/psuserparams 48 dict def
-/getuserparam { % <name> getuserparam <value>
- /userparams .systemvar 1 .argindex get exch pop
-} odef
-% Fill in userparams (created by the interpreter) with current values.
-mark .currentuserparams
-counttomark 2 idiv {
- userparams 3 1 roll put
-} repeat pop
-/.definepsuserparam { % <name> <value> .definepsuserparam -
- psuserparams 3 copy pop
- type cvlit /.checkparamtype cvx 2 packedarray cvx put
- userparams 3 1 roll put
-} .bind def
-end
-/currentuserparams { % - currentuserparams <dict>
- /userparams .systemvar dup length dict .copydict
-} odef
-% We break out setuserparams into a separate procedure so that setvmxxx
-% can use it without affecting the command in case of an error.
-/.setuserparams2 {
- % Check that we will be able to set the PostScript-level
- % user parameters.
- /setuserparams /psuserparams .systemvar .checksetparams
- % Set the C-level user params. If this succeeds, we know that
- % the password check succeeded.
- dup .setuserparams
- % Now set the PostScript-level params.
- % The interpreter may have adjusted the values of some of the
- % parameters, so we have to read them back.
- dup {
- /userparams .systemvar 2 index known {
- psuserparams 2 index known not {
- pop dup .getuserparam
- } if
- .copyparam
- % special protection for the security related parameters
- [ /PermitFileReading /PermitFileWriting /PermitFileControl ]
- { 2 index eq { % force all strings to readonly but make sure the
- % array is in the correct VM space (local/global).
- currentglobal exch dup gcheck setglobal
- dup length array exch { readonly exch } forall astore
- exch setglobal
- } if
- } forall
- % protect top level of parameters that we copied
- dup type dup /arraytype eq exch /stringtype eq or { readonly } if
- /userparams .systemvar 3 1 roll .forceput % userparams is read-only
- } {
- pop pop
- } ifelse
- } forall
- % A context switch might have occurred during the above loop,
- % causing the interpreter-level parameters to be reset.
- % Set them again to the new values. From here on, we are safe,
- % since a context switch will consult userparams.
- .setuserparams
-} .bind def
-/setuserparams { % <dict> setuserparams -
- .setuserparams2
-} .bind odef
-% Initialize user parameters managed here.
-/JobName () .definepsuserparam
-
-% Restore must restore the user parameters.
-% (Since userparams is in local VM, save takes care of saving them.)
-/restore { % <save> restore -
- //restore /userparams .systemvar .setuserparams
-} .bind odef
-
-% The pssystemparams dictionary holds some system parameters that
-% are managed entirely at the PostScript level.
-systemdict begin
-currentdict /pssystemparams known not {
- /pssystemparams 40 dict readonly def
-} if
-/getsystemparam { % <name> getsystemparam <value>
- //pssystemparams 1 .argindex .knownget { exch pop } { .getsystemparam } ifelse
-} odef
-end
-/currentsystemparams { % - currentsystemparams <dict>
- mark .currentsystemparams //pssystemparams { } forall .dicttomark
-} odef
-/setsystemparams { % <dict> setsystemparams -
- % Check that we will be able to set the PostScript-level
- % system parameters.
- dup pop % check # of args
- /SAFETY .systemvar /safe get {
- % SAFER mode disallows some changes
- [ /GenericResourceDir /FontResourceDir /GenericResourcePathSep ] {
- 2 copy .knownget {
- exch //pssystemparams exch .knownget {
- ne { /setsystemparams /invalidaccess signalerror } if
- } {
- pop
- } ifelse
- } {
- pop
- } ifelse
- } forall
- } if
- /setsystemparams //pssystemparams mark exch {
- type cvlit /.checkparamtype cvx 2 packedarray cvx
- } forall .dicttomark .checksetparams
- % Set the C-level system params. If this succeeds, we know that
- % the password check succeeded.
- dup .setsystemparams
- % Now set the PostScript-level params. We must copy local strings
- % into global VM.
- dup
- { //pssystemparams 2 index known
- { % Stack: key newvalue
- .copyparam
- % protect top level parameters that we copied
- dup type dup /arraytype eq exch /stringtype eq or { readonly } if
- //pssystemparams 3 1 roll .forceput % pssystemparams is read-only
- }
- { pop pop
- }
- ifelse
- }
- forall pop
-} .bind odef
-
-% Initialize the passwords.
-% NOTE: the names StartJobPassword and SystemParamsPassword are known to
-% the interpreter, and must be bound to noaccess strings.
-% The length of these strings must be max_password (iutil2.h) + 1.
-/StartJobPassword 65 string noaccess def
-/SystemParamsPassword 65 string noaccess def
-
-% Redefine cache parameter setting to interact properly with userparams.
-/setcachelimit {
- { mark /MaxFontItem 2 .argindex .dicttomark setuserparams pop }
- stopped
- { /setcachelimit .systemvar $error /errorname get signalerror
- } if
-} .bind odef
-/setcacheparams {
- % The MaxFontCache parameter is a system parameter, which we might
- % not be able to set. Fortunately, this doesn't matter, because
- % system parameters don't have to be synchronized between this code
- % and the VM.
- counttomark 1 add copy setcacheparams
- currentcacheparams % mark size lower upper
- 3 -1 roll pop
- /MinFontCompress 3 1 roll
- /MaxFontItem exch
- .dicttomark { setuserparams cleartomark } stopped {
- /setcacheparams .systemvar $error /errorname get signalerror
- } if
-} .bind odef
-
-% Add bogus user and system parameters to satisfy badly written PostScript
-% programs that incorrectly assume the existence of all the parameters
-% listed in Appendix C of the Red Book. Note that some of these may become
-% real parameters later: code near the end of gs_init.ps takes care of
-% removing any such parameters from ps{user,system}params.
-
-% psuserparams
- /MaxFormItem 100000 .definepsuserparam
- /MaxPatternItem 20000 .definepsuserparam
- /MaxScreenItem 48000 .definepsuserparam
- /MaxUPathItem 0 .definepsuserparam
-
-% File Access Permission parameters
- .currentglobal true .setglobal
- /.checkFilePermitparams {
- type /arraytype eq {
- currentuserparams /LockFilePermissions get {
- 5 { pop } repeat /setuserparams /invalidaccess signalerror
- }{
- % in addition to validating the value, ensure the value is read/only
- dup { readonly exch } forall
- .currentglobal exch dup gcheck .setglobal length array exch .setglobal
- astore readonly
- }
- ifelse
- } {
- 5 { pop } repeat /setuserparams /typecheck signalerror
- }
- ifelse
- true
- } .bind def
-% Initialize the File Permission access control to wide open
-% These will only be accessed via current/set userparams.
-% Values are a string containing multiple nul terminated path strings
- /PermitFileReading dup [ (*) ] .definepsuserparam
- psuserparams exch /.checkFilePermitparams load put
- /PermitFileWriting dup [ (*) ] .definepsuserparam
- psuserparams exch /.checkFilePermitparams load put
- /PermitFileControl dup [ (*) ] .definepsuserparam
- psuserparams exch /.checkFilePermitparams load put
- .setglobal
-
-pssystemparams begin
- /CurDisplayList 0 .forcedef
- /CurFormCache 0 .forcedef
- /CurInputDevice () .forcedef
- /CurOutlineCache 0 .forcedef
- /CurOutputDevice () .forcedef
- /CurPatternCache 0 .forcedef
- /CurUPathCache 0 .forcedef
- /CurScreenStorage 0 .forcedef
- /CurSourceList 0 .forcedef
- /DoPrintErrors false .forcedef
- /JobTimeout 0 .forcedef
- /LicenseID (LN-001) .forcedef % bogus
- /MaxDisplayList 140000 .forcedef
- /MaxFormCache 100000 .forcedef
- /MaxImageBuffer 524288 .forcedef
- /MaxOutlineCache 65000 .forcedef
- /MaxPatternCache 100000 .forcedef
- /MaxUPathCache 300000 .forcedef
- /MaxScreenStorage 84000 .forcedef
- /MaxSourceList 25000 .forcedef
- /PrinterName product .forcedef
- /RamSize 4194304 .forcedef
- /WaitTimeout 40 .forcedef
-end
-
-% Define the procedures for handling comment scanning. The names
-% %ProcessComment and %ProcessDSCComment are known to the interpreter.
-% These procedures take the file and comment string and file as operands.
-/.checkprocesscomment {
- dup null eq {
- pop true
- } {
- dup xcheck {
- type dup /arraytype eq exch /packedarraytype eq or
- } {
- pop false
- } ifelse
- } ifelse
-} .bind def
-/ProcessComment null .definepsuserparam
-psuserparams /ProcessComment {.checkprocesscomment} put
-(%ProcessComment) cvn {
- /ProcessComment getuserparam
- dup null eq { pop pop pop } { exec } ifelse
-} bind def
-/ProcessDSCComment null .definepsuserparam
-psuserparams /ProcessDSCComment {.checkprocesscomment} put
-/.loadingfont false def
-(%ProcessDSCComment) cvn {
- /ProcessDSCComment getuserparam
- dup null eq .loadingfont or { pop pop pop } { exec } ifelse
-} bind def
-
-% ------ Miscellaneous ------ %
-
-(<<) cvn % - << -mark-
- /mark load def
-% (>> is defined primitively.)
-/languagelevel 2 def
-% When running in Level 2 mode, this interpreter is supposed to be
-% compatible with Adobe version 2017.
-/version (2017) readonly def
-
-% If binary tokens are supported by this interpreter,
-% set an appropriate default binary object format.
-/setobjectformat where
- { pop
- /RealFormat getsystemparam (IEEE) eq { 1 } { 3 } ifelse
- /ByteOrder getsystemparam { 1 add } if
- setobjectformat
- } if
-
-% Aldus Freehand versions 2.x check for the presence of the
-% setcolor operator, and if it is missing, substitute a procedure.
-% Unfortunately, the procedure takes different parameters from
-% the operator. As a result, files produced by this application
-% cause an error if the setcolor operator is actually defined
-% and 'bind' is ever used. Aldus fixed this bug in Freehand 3.0,
-% but there are a lot of files created by the older versions
-% still floating around. Therefore, at Adobe's suggestion,
-% we implement the following dreadful hack in the 'where' operator:
-% If the key is /setcolor, and
-% there is a dictionary named FreeHandDict, and
-% currentdict is that dictionary,
-% then "where" consults only that dictionary and not any other
-% dictionaries on the dictionary stack.
-.wheredict /setcolor {
- /FreeHandDict .where {
- /FreeHandDict get currentdict eq {
- pop currentdict /setcolor known { currentdict true } { false } ifelse
- } {
- .where
- } ifelse
- } {
- .where
- } ifelse
-} bind put
-
-% ------ Virtual memory ------ %
-
-/currentglobal % - currentglobal <bool>
- /currentshared load def
-/gcheck % <obj> gcheck <bool>
- /scheck load def
-/setglobal % <bool> setglobal -
- /setshared load def
-% We can make the global dictionaries very small, because they auto-expand.
-/globaldict currentdict /shareddict .knownget not { 4 dict } if def
-/GlobalFontDirectory SharedFontDirectory def
-
-% VMReclaim and VMThreshold are user parameters.
-/setvmthreshold { % <int> setvmthreshold -
- mark /VMThreshold 2 .argindex .dicttomark .setuserparams2 pop
-} odef
-/vmreclaim { % <int> vmreclaim -
- dup 0 gt {
- .vmreclaim
- } {
- mark /VMReclaim 2 index .dicttomark .setuserparams2 pop
- } ifelse
-} odef
--1 setvmthreshold
-
-% ------ IODevices ------ %
-
-/.getdevparams where {
- pop /currentdevparams { % <iodevice> currentdevparams <dict>
- .getdevparams .dicttomark
- } odef
-} if
-/.putdevparams where {
- pop /setdevparams { % <iodevice> <dict> setdevparams -
- dup type /dicttype ne { /setdevparams .systemvar /typecheck signalerror } if
- mark 1 index { } forall counttomark 2 add index
- .putdevparams pop pop
- } odef
-} if
-
-% ------ Job control ------ %
-
-serverdict begin
-
-% We could protect the job information better, but we aren't attempting
-% (currently) to protect ourselves against maliciousness.
-
-/.jobsave //null def % top-level save object
-/.jobsavelevel 0 def % save depth of job (0 if .jobsave is null,
- % 1 otherwise)
-/.adminjob //true def % status of current unencapsulated job
-
-end % serverdict
-
-% Because there may be objects on the e-stack created since the job save,
-% we have to clear the e-stack before doing the end-of-job restore.
-% We do this by executing a 2 .stop, which is caught by the 2 .stopped
-% in .runexec; we leave on the o-stack a procedure to execute aftewards.
-%
-%**************** The definition of startjob is not complete yet, since
-% it doesn't reset stdin/stdout.
-/.startnewjob { % <exit_bool> <password_level>
- % .startnewjob -
- serverdict /.jobsave get dup //null eq { pop } { restore } ifelse
- exch {
- % Unencapsulated job
- serverdict /.jobsave //null put
- serverdict /.jobsavelevel 0 put
- serverdict /.adminjob 3 -1 roll 1 gt put
- } {
- % Encapsulated job
- pop
- serverdict /.jobsave save put
- serverdict /.jobsavelevel 1 put
- .userdict /quit { stop } .bind put % CET 28-10 requires a procedure
- } ifelse
- % Reset the interpreter state.
- clear cleardictstack
- initgraphics
- //false setglobal
- 2 vmreclaim % Make sure GC'ed memory is reclaimed and freed.
-} bind def
-/.startjob { % <exit_bool> <password> <finish_proc>
- % .startjob <ok_bool>
- vmstatus pop pop serverdict /.jobsavelevel get eq
- 2 .argindex .checkpassword 0 gt and {
- exch .checkpassword exch count 3 roll count 3 sub { pop } repeat
- cleardictstack
- % Reset the e-stack back to the 2 .stopped in .runexec,
- % passing the finish_proc to be executed afterwards.
- 2 .stop
- } { % Password check failed
- pop pop pop //false
- } ifelse
-} odef
-/startjob { % <exit_bool> <password> startjob <ok_bool>
- % This is a hack. We really need some way to indicate explicitly
- % to the interpreter that we are under control of a job server.
- 1 .argindex type /booleantype ne {
- /startjob .systemvar /typecheck signalerror
- } if
- { .startnewjob //true } .startjob
-} odef
-
-% The procedure to undo the job encapsulation
-/.endjob {
- clear cleardictstack
- serverdict /.jobsave get dup //null eq { pop } { restore } ifelse
- serverdict /.jobsave //null put
- 2 vmreclaim % recover local and global VM
-} odef
-
-systemdict begin
-/quit { % - quit -
- //systemdict begin serverdict /.jobsave get null eq
- { end //quit }
- { /quit .systemvar /invalidaccess /signalerror load end exec }
- ifelse
-} bind odef
-end
-
-% We would like to define exitserver as a procedure, using the code
-% that the Red Book says is equivalent to it. However, since startjob
-% resets the exec stack, we can't do this, because control would never
-% proceed past the call on startjob if the exitserver is successful.
-% Instead, we need to construct exitserver out of pieces of startjob.
-
-serverdict begin
-
-/exitserver { % <password> exitserver -
- //true exch { .startnewjob } .startjob not {
- /exitserver /invalidaccess signalerror
- } if
-} bind def
-
-end % serverdict
-
-% ------ Compatibility ------ %
-
-% In Level 2 mode, the following replace the definitions that gs_statd.ps
-% installs in statusdict and serverdict.
-% Note that statusdict must be allocated in local VM.
-% We don't bother with many of these yet.
-
-/.dict1 { exch mark 3 1 roll .dicttomark } bind def
-
-currentglobal false setglobal 25 dict exch setglobal begin
-currentsystemparams
-
-% The following do not depend on the presence of setpagedevice.
-/buildtime 1 index /BuildTime get def
-% Also define /buildtime in systemdict because Adobe does so and some fonts use it as ID
-systemdict /buildtime dup load put
-/byteorder 1 index /ByteOrder get def
-/checkpassword { .checkpassword 0 gt } bind def
-dup /DoStartPage known
- { /dostartpage { /DoStartPage getsystemparam } bind def
- /setdostartpage { /DoStartPage .dict1 setsystemparams } bind def
- } if
-dup /StartupMode known
- { /dosysstart { /StartupMode getsystemparam 0 ne } bind def
- /setdosysstart { { 1 } { 0 } ifelse /StartupMode .dict1 setsystemparams } bind def
- } if
-%****** Setting jobname is supposed to set userparams.JobName, too.
-/jobname { /JobName getuserparam } bind def
-/jobtimeout { /JobTimeout getuserparam } bind def
-/ramsize { /RamSize getsystemparam } bind def
-/realformat 1 index /RealFormat get def
-dup /PrinterName known
- { /setprintername { /PrinterName .dict1 setsystemparams } bind def
- } if
-/printername
- { currentsystemparams /PrinterName .knownget not { () } if exch copy
- } bind def
-currentuserparams /WaitTimeout known
- { /waittimeout { /WaitTimeout getuserparam } bind def
- } if
-
-% The following do require setpagedevice.
-/.setpagedevice where { pop } { (%END PAGEDEVICE) .skipeof } ifelse
-/defaulttimeouts
- { currentsystemparams dup
- /JobTimeout .knownget not { 0 } if
- exch /WaitTimeout .knownget not { 0 } if
- currentpagedevice /ManualFeedTimeout .knownget not { 0 } if
- } bind def
-/margins
- { currentpagedevice /Margins .knownget { exch } { [0 0] } ifelse
- } bind def
-/pagemargin
- { currentpagedevice /PageOffset .knownget { 0 get } { 0 } ifelse
- } bind def
-/pageparams
- { currentpagedevice
- dup /Orientation .knownget { 1 and ORIENT1 { 1 xor } if } { 0 } ifelse exch
- dup /PageSize get aload pop 3 index 0 ne { exch } if 3 2 roll
- /PageOffset .knownget { 0 get } { 0 } ifelse 4 -1 roll
- } bind def
-/setdefaulttimeouts
- { exch mark /ManualFeedTimeout 3 -1 roll
- /Policies mark /ManualFeedTimeout 1 .dicttomark
- .dicttomark setpagedevice
- /WaitTimeout exch mark /JobTimeout 5 2 roll .dicttomark setsystemparams
- } bind def
-/.setpagesize { 2 array astore /PageSize .dict1 setpagedevice } bind def
-/setduplexmode { /Duplex .dict1 setpagedevice } bind def
-/setmargins
- { exch 2 array astore /Margins .dict1 setpagedevice
- } bind def
-/setpagemargin { 0 2 array astore /PageOffset .dict1 setpagedevice } bind def
-/setpageparams
- { mark /PageSize 6 -2 roll
- 4 index 1 and ORIENT1 { 1 } { 0 } ifelse ne { exch } if 2 array astore
- /Orientation 5 -1 roll ORIENT1 { 1 xor } if
- /PageOffset counttomark 2 add -1 roll 0 2 array astore
- .dicttomark setpagedevice
- } bind def
-/setresolution
- { dup 2 array astore /HWResolution .dict1 setpagedevice
- } bind def
-%END PAGEDEVICE
-
-% The following are not implemented yet.
-%manualfeed
-%manualfeedtimeout
-%pagecount
-%pagestackorder
-%setpagestackorder
-
-pop % currentsystemparams
-
-% Flag the current dictionary so it will be swapped when we
-% change language levels. (See zmisc2.c for more information.)
-/statusdict currentdict def
-
-currentdict end
-/statusdict exch .forcedef % statusdict is local, systemdict is global
-
-% The following compatibility operators are in systemdict. They are
-% defined here, rather than in gs_init.ps, because they require the
-% resource machinery.
-
-/devforall { % <proc> <scratch> devforall -
- exch {
- 1 index currentdevparams
- /Type .knownget { /FileSystem eq } { false } ifelse
- { exec } { pop pop } ifelse
- } /exec load 3 packedarray cvx exch
- (*) 3 1 roll /IODevice resourceforall
-} odef
-/devstatus { % <(%disk*%)> devstatus <searchable> <writable>
- % <hasNames> <mounted> <removable> <searchOrder>
- % <freePages> <size> true
- % <string> devstatus false
- dup length 5 ge {
- dup 0 5 getinterval (%disk) eq {
- dup /IODevice resourcestatus {
- pop pop dup currentdevparams
- dup /Searchable get
- exch dup /Writeable get
- exch dup /HasNames get
- exch dup /Mounted get
- exch dup /Removable get
- exch dup /SearchOrder get
- exch dup /Free get
- exch /LogicalSize get
- 9 -1 roll pop true
- } {
- pop false
- } ifelse
- } {
- pop false
- } ifelse
- } {
- pop false
- } ifelse
-} odef
-
-% ------ Color spaces ------ %
-
-% Move setcolorspace, setcolor, and colorspacedict to level2dict
-level2dict /setcolorspace .cspace_util 1 index get put
-level2dict /setcolor .cspace_util 1 index get put
-level2dict /colorspacedict .cspace_util 1 index get put
-
-% Add the level 2 color spaces
-% DevicePixel is actually a LanguageLevel 3 feature; it is here for
-% historical reasons.
-%% Replace 1 (gs_devpxl.ps)
-(gs_devpxl.ps) runlibfile
-
-%% Replace 1 (gs_ciecs2.ps)
-(gs_ciecs2.ps) runlibfile
-
-%% Replace 1 (gs_indxd.ps)
-(gs_indxd.ps) runlibfile
-
-%% Replace 1 (gs_sepr.ps)
-(gs_sepr.ps) runlibfile
-
-%% Replace 1 (gs_patrn.ps)
-(gs_patrn.ps) runlibfile
-
-
-
-% ------ CIE color rendering ------ %
-
-% Define findcolorrendering and a default ColorRendering ProcSet.
-
-/findcolorrendering { % <intentname> findcolorrendering
- % <crdname> <found>
- % Adobe interpreters report /findcolorrendering (literal name), not the
- % operator itself, if an error occurs in findcolorrendering.
- /findcolorrendering {
- /ColorRendering /ProcSet findresource
- 1 .argindex dup type /nametype eq { .namestring } if (.) concatstrings
- 1 index /GetPageDeviceName get exec dup type /nametype eq { .namestring } if (.) concatstrings
- 2 index /GetHalftoneName get exec dup type /nametype eq { .namestring } if
- concatstrings concatstrings cvn % stack: intentname procset crdname
- dup /ColorRendering resourcestatus {
- pop pop exch pop exch pop true
- } {
- pop /GetSubstituteCRD get exec false
- } ifelse
- } .errorexec
-} odef
-
-5 dict dup begin
-
-/GetPageDeviceName { % - GetPageDeviceName <name>
- currentpagedevice dup /PageDeviceName .knownget {
- exch pop dup null eq { pop /none } if
- } {
- pop /none
- } ifelse
-} bind def
-
-/GetHalftoneName { % - GetHalftoneName <name>
- currenthalftone /HalftoneName .knownget not { /none } if
-} bind def
-
-/GetSubstituteCRD { % <intentname> GetSubstituteCRD <crdname>
- pop /DefaultColorRendering
-} bind def
-
-end
-% The resource machinery hasn't been activated, so just save the ProcSet
-% and let .fixresources finish the installation process.
-/ColorRendering exch def
-
-% Define setcolorrendering.
-
-/.colorrenderingtypes 5 dict def
-
-/setcolorrendering { % <crd> setcolorrendering -
- dup /ColorRenderingType get
- dup type /integertype ne {
- /setcolorrendering .systemvar /typecheck signalerror
- } if
- //.colorrenderingtypes exch .knownget {
- exec
- } {
- /setcolorrendering .systemvar /rangecheck signalerror
- } ifelse
-} odef
-
-/.setcolorrendering1 where { pop } { (%END CRD) .skipeof } ifelse
-
-.colorrenderingtypes 1 {
- % Adobe ProcSet "Adobe_AGM_Core 2.0 0" places an /Intent key into CRD's
- dup /Intent .knownget {
- //.renderingintentdict exch .knownget { .setrenderingintent } if
- } if
- dup .buildcolorrendering1 .setcolorrendering1
-} .bind put
-
-% Note: the value 101 in the next line must be the same as the value of
-% GX_DEVICE_CRD1_TYPE in gscrdp.h.
-.colorrenderingtypes 101 {
- dup .builddevicecolorrendering1 .setdevicecolorrendering1
-} .bind put
-
-% sRGB output CRD, D65 white point
-mark
-/ColorRenderingType 1
-/RangePQR [ -0.5 2 -0.5 2 -0.5 2 ] readonly
-
-% Bradford Cone Space
-/MatrixPQR [ 0.8951 -0.7502 0.0389
- 0.2664 1.7135 -0.0685
- -0.1614 0.0367 1.0296] readonly
-
-/MatrixLMN [ 3.240449 -0.969265 0.055643
- -1.537136 1.876011 -0.204026
- -0.498531 0.041556 1.057229 ] readonly
-
-% Inverse sRGB gamma transform
-/EncodeABC [ { dup 0.00304 le
- { 12.92321 mul }
- { 1 2.4 div exp 1.055 mul 0.055 sub }
- ifelse
- } bind dup dup
- ] readonly
-
-/WhitePoint [ 0.9505 1 1.0890 ] readonly % D65
-/BlackPoint [ 0 0 0 ] readonly
-
-% VonKries-like transform in Bradford Cone Space
- /TransformPQR
- % The implementations have been moved to C for performance.
- [ { .TransformPQR_scale_WB0 } bind
- { .TransformPQR_scale_WB1 } bind
- { .TransformPQR_scale_WB2 } bind
- ] readonly
-.dicttomark setcolorrendering
-
-%END CRD
-
-% Initialize a CIEBased color space for sRGB.
-/CIEsRGB [ /CIEBasedABC
- mark
- /DecodeLMN [ {
- dup 0.03928 le { 12.92321 div } { 0.055 add 1.055 div 2.4 exp } ifelse
- } bind dup dup ] readonly
- /MatrixLMN [
- 0.412457 0.212673 0.019334
- 0.357576 0.715152 0.119192
- 0.180437 0.072175 0.950301
- ] readonly
- /WhitePoint [0.9505 1.0 1.0890] readonly
- .dicttomark readonly
-] readonly def
-
-% ------ Painting ------ %
-
-% A straightforward definition of execform that doesn't actually
-% do any caching.
-/.execform1 {
- % This is a separate operator so that the stacks will be restored
- % properly if an error occurs.
- dup /Matrix get concat
- dup /BBox get aload pop
- exch 3 index sub exch 2 index sub rectclip
- dup /PaintProc get
- 1 index /Implementation known not {
- 1 index dup /Implementation null .forceput readonly pop
- } if
- exec
-} .bind odef % must bind .forceput
-
-/.formtypes 5 dict
- dup 1 /.execform1 load put
-def
-
-/execform { % <form> execform -
- gsave {
- dup /FormType get //.formtypes exch get exec
- } stopped grestore { stop } if
-} odef
-
-/.patterntypes 5 dict
- dup 1 /.buildpattern1 load put
-def
-
-/makepattern { % <proto_dict> <matrix> makepattern <pattern>
- dup type /dicttype eq {
- % "<dict> makepattern" reports /typecheck on Adobe
- /makepattern .systemvar /typecheck signalerror
- } if
- //.patterntypes 2 .argindex /PatternType get .knownget not {
- /makepattern .systemvar /rangecheck signalerror
- } if
- .currentglobal false .setglobal exch
- % Stack: proto matrix global buildproc
- 3 index dup length 1 add dict .copydict
- % Stack: proto matrix global buildproc newdict
- 3 index 3 -1 roll exec
- % Stack: proto matrix global newdict instance
- % Create an 'Implementation' entry for the pattern dict. The PRLM 3rd says
- % this about the contents of Implementation: "The type and value of this
- % entry are implementation-dependent." The CET (page 2 of 18-02f) expects
- % that this entry be an array and that the second element of the array be a
- % gstate. We put our pattern instance struct into the first element of the
- % array.
- 1 index /Implementation 3 -1 roll gstate 2 array astore
- put % put Implementation into the pattern dict.
- % Stack: proto matrix global newdict
- readonly exch .setglobal exch pop exch pop
-} odef
-
-/setpattern { % [<comp1> ...] <pattern> setpattern -
- { currentcolorspace 0 get /Pattern ne {
- [ /Pattern currentcolorspace ] setcolorspace
- } if setcolor
- } stopped {
- /setpattern .systemvar $error /errorname get signalerror
- } if
-} odef
-
-% The following functions emulate the actions of findcmykcustomcolor and
-% setcustomcolor. These functions are described in Adobe's TN 5044. That
-% same document also says "The following “operators” are not defined in the
-% PostScript Language Reference Manual, but should be used as pseudo-operators
-% in your PostScript language output. Separation applications from Adobe
-% Systems and other vendors will redefine these convention operators to
-% separate your documents. Your application should conditionally define
-% procedures with these special names, as shown later in this document."
-%
-% We are providing these functions because we have found files created by
-% "QuarkXPress: pictwpstops filter 1.0" which produce bad shading dictionaries
-% if these operators are not defined.
-
-% Conditionally disable the TN 5044 psuedo-ops if NO_TN5044 specified
-/NO_TN5044 where { pop (%END TN 5044 psuedo-ops) .skipeof } if
-
-% TN 5044 does not define the contents of the array. We are simply putting
-% the values given into an array. This is consistent with what we see when
-% testing with Adobe Distiller 6.0.
-% <cyan> <magenta> <yellow> <black> <key> findcmykcustomcolor <array>
-/findcmykcustomcolor { 5 array astore } bind def
-
-% Build a tint transform function for use by setcustomcolor. This function
-% is for a Separation color space which has a DeviceCMYK base color space
-% (i.e. 1 input and 4 outputs). The input to buildcustomtinttransform is the
-% array created by findcmykcustomcolor. The resulting function is:
-% { dup cyan mul exch dup magenta mul exch dup yellow mul exch black mul }
-% Where cyan, magenta, yellow, and black are values from the array.
-/buildcustomtinttransform % <array> buildcustomtinttransform <function>
-{ [ /dup load 2 index 0 get /mul load
- /exch load /dup load 6 index 1 get /mul load
- /exch load /dup load 10 index 2 get /mul load
- /exch load 13 index 3 get /mul load
- ] cvx bind
- exch pop % Remove the input array
-} bind def
-
-% Set a custom color based upon a tint and array which describes the custom
-% color. See findcmykcustomcolor. First we create and then set a Separation
-% colorspace. Then we set the specified color.
-% Note that older Adobe ProcSets apparently allow for 'null' as the tint
-% for some reason, so an alternate operational mode is tolerated:
-% null setcustomcolor -
-/setcustomcolor % <array> <tint> setcustomcolor -
-{ dup //null ne {
- % Start building Separation colorspace
- [ /Separation 3 index 4 get % Get separation name from array's key
- /DeviceCMYK
- 5 index //buildcustomtinttransform exec] % build the tint transform function
- setcolorspace % Set the Separation color space as current
- setcolor % Set the tint as the current color
- pop % Remove the input array
- }
- { pop } % 'null' as the tint is ignored
- ifelse
-} bind def
-
-% This proc is supposed to implement a version of overprinting. TN 5044 says
-% that this proc is not used by any shipping host-based application. We have
-% only found it being used in a proc set in files by Canvas from Deneba Systems.
-% Even their proc set does not actually do any overprinting. However their
-% files crash if this is not defined. Thus we have a copy of this proc but
-% we are simply checking for inputs being -1 and if so then we set the value
-% to 0.
-/setcmykoverprint {
- 4 { dup -1 eq { pop 0 } if 4 1 roll } repeat setcmykcolor
-} bind def
-
-/separation_all [/Separation /All /DeviceCMYK { dup dup dup } bind ] readonly def
-
-% Collect the arguments into the image dictionary
-% <width> <height> <bits/sample> <matrix> <proc> args2dict <dict>
-/args2dict {
- 10 dict begin
- {1 0} 1
- { /ImageType /Decode /DataSource /ImageMatrix /BitsPerComponent /Height /Width
- } { exch def } forall
- currentdict end
-} bind def
-
-% Prints (1-gray) on all separations.
-% <gray> setseparationgray -
-/setseparationgray {
- //separation_all setcolorspace
- 1 exch sub setcolor
-} bind def
-
-% Renders an image whose sample values specify the amount of the custom color.
-% <width> <height> <bits/sample> <matrix> <proc> <array> customcolorimage -
-/customcolorimage {
- gsave
- [ /Separation 2 index 4 get /DeviceCMYK 5 -1 roll //buildcustomtinttransform exec] setcolorspace
- //args2dict exec image
- grestore
-} bind def
-
-% Renders an image on all process and custom color plates.
-% <width> <height> <bits/sample> <matrix> <proc>
-/separationimage {
- gsave
- //separation_all setcolorspace
- //args2dict exec image
- grestore
-} bind def
-
-{ /buildcustomtinttransform /separation_all /args2dict }
-{ currentdict exch undef } forall
-
-%END TN 5044 psuedo-ops
-
-end % level2dict
diff --git a/Master/tlpkg/tlgs/lib/gs_lgo_e.ps b/Master/tlpkg/tlgs/lib/gs_lgo_e.ps deleted file mode 100644 index 19a3d2f3312..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_lgo_e.ps +++ /dev/null @@ -1,91 +0,0 @@ -% Copyright (C) 1999, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_lgo_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Adobe "original" Latin glyph set.
-% This is not an Encoding strictly speaking, but we treat it like one.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/AdobeLatinOriginalGlyphEncoding mark
-
-/.notdef
-/A /AE /Aacute /Acircumflex /Adieresis /Agrave /Aring /Atilde
-/B
-/C /Ccedilla
-/D
-/E /Eacute /Ecircumflex /Edieresis /Egrave /Eth
-/F
-/G
-/H
-/I /Iacute /Icircumflex /Idieresis /Igrave
-/J
-/K
-/L /Lslash
-/M
-/N /Ntilde
-/O /OE /Oacute /Ocircumflex /Odieresis /Ograve /Oslash /Otilde
-/P
-/Q
-/R
-/S /Scaron
-/T /Thorn
-/U /Uacute /Ucircumflex /Udieresis /Ugrave
-/V
-/W
-/X
-/Y /Yacute /Ydieresis
-/Z /Zcaron
-/a /aacute /acircumflex /acute /adieresis /ae /agrave /ampersand /aring
- /asciicircum /asciitilde /asterisk /at /atilde
-/b /backslash /bar /braceleft /braceright /bracketleft /bracketright /breve
- /brokenbar /bullet
-/c /caron /ccedilla /cedilla /cent /circumflex /colon /comma /copyright
- /currency
-/d /dagger /daggerdbl /degree /dieresis /divide /dollar /dotaccent /dotlessi
-/e /eacute /ecircumflex /edieresis /egrave /eight /ellipsis /emdash /endash
- /equal /eth /exclam /exclamdown
-/f /fi /five /fl /florin /four /fraction
-/g /germandbls /grave /greater /guillemotleft /guillemotright /guilsinglleft
- /guilsinglright
-/h /hungarumlaut /hyphen
-/i /iacute /icircumflex /idieresis /igrave
-/j
-/k
-/l /less /logicalnot /lslash
-/m /macron /minus /mu /multiply
-/n /nine /ntilde /numbersign
-/o /oacute /ocircumflex /odieresis /oe /ogonek /ograve /one /onehalf
- /onequarter /onesuperior /ordfeminine /ordmasculine /oslash /otilde
-/p /paragraph /parenleft /parenright /percent /period /periodcentered
- /perthousand /plus /plusminus
-/q /question /questiondown /quotedbl /quotedblbase /quotedblleft
- /quotedblright /quoteleft /quoteright /quotesinglbase /quotesingle
-/r /registered /ring
-/s /scaron /section /semicolon /seven /six /slash /space /sterling
-/t /thorn /three /threequarters /threesuperior /tilde /trademark /two
- /twosuperior
-/u /uacute /ucircumflex /udieresis /ugrave /underscore
-/v
-/w
-/x
-/y /yacute /ydieresis /yen
-/z /zcaron /zero
-
-counttomark packedarray exch pop
-8 1 index .registerencoding
-.defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_lgx_e.ps b/Master/tlpkg/tlgs/lib/gs_lgx_e.ps deleted file mode 100644 index cbc270b1d56..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_lgx_e.ps +++ /dev/null @@ -1,60 +0,0 @@ -% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_lgx_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Adobe "extension" Latin glyph set.
-% This is not an Encoding strictly speaking, but we treat it like one.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/AdobeLatinExtensionGlyphEncoding mark
-
-/Abreve /Amacron /Aogonek
-/Cacute /Ccaron /Dcaron
-/Dcroat /Delta
-/Ecaron /Edotaccent /Emacron /Eogonek
-/Gbreve /Gcommaaccent
-/Idotaccent /Imacron /Iogonek
-/Kcommaaccent
-/Lacute /Lcaron /Lcommaaccent
-/Nacute /Ncaron /Ncommaaccent
-/Ohungarumlaut /Omacron
-/Racute /Rcaron /Rcommaaccent
-/Sacute /Scedilla /Scommaaccent
-/Tcaron /Tcommaaccent
-/Uhungarumlaut /Umacron /Uogonek /Uring
-/Zacute /Zdotaccent
-/abreve /amacron /aogonek
-/cacute /ccaron /commaaccent
-/dcaron /dcroat
-/ecaron /edotaccent /emacron /eogonek
-/gbreve /gcommaaccent /greaterequal
-/imacron /iogonek
-/kcommaaccent
-/lacute /lcaron /lcommaaccent /lessequal /lozenge
-/nacute /ncaron /ncommaaccent /notequal
-/ohungarumlaut /omacron
-/partialdiff
-/racute /radical /rcaron /rcommaaccent
-/sacute /scedilla /scommaaccent /summation
-/tcaron /tcommaaccent
-/uhungarumlaut /umacron /uogonek /uring
-/zacute /zdotaccent
-
-counttomark packedarray exch pop
-9 1 index .registerencoding
-.defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_ll3.ps b/Master/tlpkg/tlgs/lib/gs_ll3.ps deleted file mode 100644 index a7d7df86737..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_ll3.ps +++ /dev/null @@ -1,379 +0,0 @@ -% Copyright (C) 1997, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_ll3.ps 8111 2007-07-06 16:42:18Z alexcher $
-% Initialization file for PostScript LanguageLevel 3 functions.
-% This file must be loaded after gs_lev2.ps and gs_res.ps.
-% These definitions go into ll3dict or various ProcSets.
-% NOTE: the interpreter creates ll3dict.
-
-ll3dict begin
-
-% We need LanguageLevel 2 or higher in order to have setuserparams and
-% defineresource.
-languagelevel dup 2 .max .setlanguagelevel
-
-% ------ Idiom recognition ------ %
-
-/IdiomRecognition false .definepsuserparam
-
-% Modify `bind' to apply idiom recognition afterwards.
-/.bindscratch 128 string def
-% Note that since this definition of `bind' may get bound in,
-% it has to function properly even at lower language levels,
-% where IdiomRecognition may not be defined.
-/.bind_ { % <proc> .bind <proc'>
- //.bind currentuserparams /IdiomRecognition
- .knownget not { false } if {
- (*) {
- /IdiomSet findresource
- false exch {
- % Stack: proc false dummykey [template substitute]
- exch pop dup 1 get exch 0 get
- % Stack: proc false substitute template
- 3 index .eqproc {
- 2 index gcheck 1 index gcheck not and {
- pop
- } {
- 3 -1 roll pop exch not exit
- } ifelse
- } {
- pop
- } ifelse
- } forall { exit } if
- } //.bindscratch /IdiomSet resourceforall
- } if
-} def
-/.bind /.bind_ load odef % note that .bind_ will get bound
-currentdict /.bindscratch .undef
-
-DELAYBIND NOBIND or not {
-% We can't just do
-% /bind /.bind load def
-% because then /bind load == prints --.bind-- .
- /bind {//.bind_ exec} odef
-} if
-currentdict /.bind_ undef
-
-% ------ HalftoneTypes 6, 10, 16 and HalftoneMode ------ %
-
-% This code depends on an internal HalftoneType 7 with the following keys:
-% Width, Height, Width2, Height2, TransferFunction:
-% as for HalftoneType 16.
-% Thresholds: a string or bytestring holding the thresholds,
-% (Width x Height + Width2 x Height2) x BitsPerSample / 8 bytes,
-% as for HalftoneType 16 except that the samples may be either
-% 8 or 16 bits wide.
-% BitsPerSample: 8 or 16.
-
-% Note that this HalftoneType never appears in halftone dictionaries given
-% to sethalftone, only as a component in those given to .sethalftone5,
-% so its numeric value can be chosen ad lib as long as it differs from the
-% other values that are legal in component dictionaries for .sethalftone5
-% (currently only 1 and 3).
-
-/.makehalftone7 { % <dict> <dict> <source> <Width> <Height>
- % (<Width2> <Height2> | null) <BPS> .makehalftone7
- % <setdict> <dict5> { .sethalftone5 }
- 8 dict begin
- /HalftoneType 7 def
- /BitsPerSample exch def
- dup null eq {
- pop 0
- } {
- /Height2 1 index def /Width2 2 index def mul
- } ifelse 3 1 roll
- /Height 1 index def
- /Width 2 index def
- mul add BitsPerSample 8 idiv mul .bigstring
- % Stack: dict dict source str
- dup type /stringtype eq { readstring } { .readbytestring } ifelse
- not { /sethalftone .systemvar /rangecheck signalerror exit } if
- readonly /Thresholds exch def
- /TransferFunction .knownget { /TransferFunction exch def } if
- % If the original Thresholds was a file, replace it with
- % a new one.
- dup /Thresholds get type /filetype eq {
- dup /Thresholds [ Thresholds ] cvx 0 () .subfiledecode put
- } if
- mark /HalftoneType 5 /Default currentdict end .dicttomark
- { .sethalftone5 }
-} bind def
-
-/.bigstring { % <size> .bigstring <string|bytestring>
- dup 65400 gt { .bytestring } { string } ifelse
-} bind def
-
-/.readbytestring { % <source> <bytestring> .readbytestring
- % <bytestring> <filled>
- % Note that since bytestrings don't implement getinterval,
- % if filled is false, there is no way to tell how much
- % was read.
- true exch 0 1 2 index length 1 sub {
- % Stack: source true str index
- 3 index read not { pop exch not exch exit } if
- 3 copy put pop pop
- } for 3 -1 roll pop exch
-} bind def
-
-/.sethalftone6 { % <dict> <dict> .sethalftone6 <setdict> <dict5>
- % { .sethalftone5 }
- % Keys: Width, Height, Thresholds, T'Function
- dup /Thresholds get
- 1 index /Width get 2 index /Height get
- null 8 .makehalftone7
-} bind def
-
-/.sethalftone10 { % <dict> <dict> .sethalftone10 <setdict> <dict5>
- % { .sethalftone5 }
- % Keys: Xsquare, Ysquare, Thresholds, T'Function
- % Note that this is the only one of these three HalftoneTypes
- % that allows either a file or a string for Thresholds.
- dup /Thresholds get dup type /stringtype eq { 0 () .subfiledecode } if
- 1 index /Xsquare get dup 3 index /Ysquare get dup
- 8 .makehalftone7
-} bind def
-
-/.sethalftone16 { % <dict> <dict> .sethalftone16 <setdict> <dict5>
- % { .sethalftone5 }
- % Keys: Width, Height, Width2, Height2,
- % Thresholds, T'Function
- dup /Thresholds get
- 1 index /Width get 2 index /Height get
- 3 index /Width2 .knownget { % 2-rectangle case
- 4 index /Height2 get
- } { % 1-rectangle case
- null
- } ifelse 16 .makehalftone7
-} bind def
-
-.halftonetypes begin
- 6 /.sethalftone6 load def
- 10 /.sethalftone10 load def
- 16 /.sethalftone16 load def
-end
-
-% Redefine the halftone-setting operators to honor HalftoneMode.
-/setcolorscreen {
- /HalftoneMode getuserparam 0 eq {
- //setcolorscreen
- } {
- 12 { pop } repeat .getdefaulthalftone
- { //sethalftone }
- { .setdefaulthalftone }
- ifelse
- } ifelse
-} odef
-/setscreen {
- /HalftoneMode getuserparam 0 eq {
- //setscreen
- } {
- pop pop pop .getdefaulthalftone
- { //sethalftone }
- { .setdefaulthalftone }
- ifelse
- } ifelse
-} odef
-/sethalftone {
- /HalftoneMode getuserparam 0 eq {
- //sethalftone
- } {
- gsave //sethalftone grestore
- .getdefaulthalftone
- { //sethalftone }
- { .setdefaulthalftone }
- ifelse
- } ifelse
-} odef
-
-% ------ ImageTypes 3 and 4 (masked images) ------ %
-
-.imagetypes
- dup 3 /.image3 load put
- dup 4 /.image4 load put
-% We also detect ImageType 103 here: it isn't worth making a separate file
-% just for this.
- /.image3x where { pop dup 103 /.image3x load put } if
-pop
-
-% ------ Functions ------ %
-
-% Define the FunctionType resource category.
-/Generic /Category findresource dup maxlength 3 add dict .copydict begin
- /InstanceType /integertype def
-/FunctionType currentdict end /Category defineresource pop
-
-{0 2 3} { dup /FunctionType defineresource pop } forall
-
-% ------ Smooth shading ------ %
-
-% Define the ShadingType resource category.
-/Generic /Category findresource dup maxlength 3 add dict .copydict begin
- /InstanceType /integertype def
-/ShadingType currentdict end /Category defineresource pop
-
-systemdict /.shadingtypes mark % not ll3dict
- 1 /.buildshading1 load
- 2 /.buildshading2 load
- 3 /.buildshading3 load
- 4 /.buildshading4 load
- 5 /.buildshading5 load
- 6 /.buildshading6 load
- 7 /.buildshading7 load
-.dicttomark put
-
-systemdict /.reuseparamdict mark
- /Intent 2
- /AsyncRead false
- /CloseSource true
-.dicttomark readonly put
-/.buildshading { % <shadingdict> .buildshading <shading>
- dup rcheck not {
- % Adobe seems to access ColorSpace first and CET 12-14c checks this.
- /$error .systemvar /errorinfo [ /ColorSpace null ] put
- /shfill .systemvar /invalidaccess signalerror
- } if
- % Unfortunately, we always need to make the DataSource reusable,
- % because if clipping is involved, even shfill may need to read
- % the source data multiple times. If it weren't for this,
- % we would only need to create a reusable stream if the ultimate
- % source of the data is a procedure (since the library can't
- % suspend shading to do a procedure callout).
- dup /DataSource .knownget {
- dup type /filetype eq {
- //.reuseparamdict /ReusableStreamDecode filter
- % Copy the dictionary to replace the DataSource, but make sure the
- % copy is in the same VM as the original.
- .currentglobal 2 index gcheck .setglobal
- % Stack: shdict rsdfile saveglobal
- 2 index dup length dict copy exch .setglobal
- dup /DataSource 4 -1 roll put exch pop
- } {
- pop
- } ifelse
- } if
- % The .buildshading operators use the current color space
- % for ColorSpace.
- dup /ShadingType .knownget not { % error handling for CET 12-14b conformance
- /$error .systemvar /errorinfo [ /ShadingType //null ] put
- /shfill .systemvar /undefined signalerror
- } if
- dup type /integertype ne {
- /$error .systemvar /errorinfo [ /ShadingType 4 index ] put
- /shfill .systemvar /typecheck signalerror
- } if
- //.shadingtypes 1 index .knownget not {
- /$error .systemvar /errorinfo [ /ShadingType 4 index ] put
- /shfill .systemvar /rangecheck signalerror
- } if
- exch pop 1 index /ColorSpace .knownget {
- { setcolorspace } stopped {
- /$error .systemvar /errorinfo [ /ColorSpace 4 index ] put
- /shfill .systemvar /$error .systemvar /errorname get signalerror
- } if
- exec
- } {
- /$error .systemvar /errorinfo [ /ColorSpace //null ] put
- /shfill .systemvar /undefined signalerror
- } ifelse
-} bind def
-systemdict /.reuseparamdict undef
-
-/.buildpattern2 { % <template> <matrix> .buildpattern2
- % <template> <pattern>
- % We want to build the pattern without doing gsave/grestore,
- % since we want it to load the CIE caches.
- 1 index /Shading get
- mark currentcolor currentcolorspace
- counttomark 4 add -3 roll mark 4 1 roll
- % Stack: -mark- ..color.. cspace -mark- template matrix shadingdict
- { .buildshading } stopped {
- cleartomark setcolorspace setcolor pop stop
- } if
- .buildshadingpattern
- 3 -1 roll pop counttomark 1 add 2 roll setcolorspace setcolor pop
-} bind def
-
-.patterntypes
- 2 /.buildpattern2 load put
-
-/shfill { % <shadingdict> shfill -
- % Currently, .shfill requires that the color space
- % in the pattern be the current color space.
- % Disable overprintmode for shfill
- { dup gsave 0 .setoverprintmode .buildshading .shfill } stopped
- grestore {
- /$error .systemvar /errorinfo 2 copy known {
- pop pop
- } {
- //null put % CET 12-14c
- } ifelse
- stop
- } if
- pop
-} odef
-
-% Establish an initial smoothness value that matches Adobe RIPs.
-0.02 setsmoothness
-
-% ------ DeviceN color space ------ %
-
-%% Replace 1 (gs_ciecs3.ps)
-(gs_ciecs3.ps) runlibfile
-
-%% Replace 1 (gs_devn.ps)
-(gs_devn.ps) runlibfile
-
-% ------ Miscellaneous ------ %
-
-% Make the setoverprintmode and currentoverprintmode operators visible (3015)
-% Because of the requirements of PDF, the .currentoverprintmode and
-% .setoverprintmode operators have integer parameters. Thus we need to
-% convert the Postscript bool parameters to integers.
-%
-/setoverprintmode % bool setoverprint -
-{
- { 1 } { 0 } ifelse % convert bool to integer
- //.setoverprintmode
-} odef
-
-/currentoverprintmode % - currentoverprintmode bool
-{
- //.currentoverprintmode
- 0 ne % convert integers to bool
-} odef
-
-% Define additional user and system parameters.
-/HalftoneMode 0 .definepsuserparam
-/MaxSuperScreen 1016 .definepsuserparam
-pssystemparams begin % read-only, so use .forcedef
- /MaxDisplayAndSourceList 160000 .forcedef
-end
-
-% Define the IdiomSet resource category.
-{ /IdiomSet } {
- /Generic /Category findresource dup maxlength 3 add dict .copydict begin
- /InstanceType /dicttype def
- currentdict end /Category defineresource pop
-} forall
-
-/languagelevel 3 def
-% When running in LanguageLevel 3 mode, this interpreter is supposed to be
-% compatible with Adobe version 3010.
-/version (3010) readonly def
-
-.setlanguagelevel
-
-end % ll3dict
diff --git a/Master/tlpkg/tlgs/lib/gs_m.xbm b/Master/tlpkg/tlgs/lib/gs_m.xbm deleted file mode 100644 index a94e079e257..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_m.xbm +++ /dev/null @@ -1,16 +0,0 @@ -#define gs_m.xbm_width 32
-#define gs_m.xbm_height 32
-#define gs_m.xbm_x_hot 0
-#define gs_m.xbm_y_hot 0
-static unsigned char gs.m.bm_bits[] = {
- 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, 0x48, 0x00,
- 0x00, 0xf8, 0xc7, 0x00, 0x00, 0xff, 0xc1, 0x00, 0x80, 0x3f, 0xf0, 0x00,
- 0xc0, 0x0f, 0xf8, 0x01, 0xc0, 0x87, 0xfc, 0x03, 0xe0, 0xa7, 0xfc, 0x03,
- 0xe0, 0x27, 0xf8, 0x03, 0xe0, 0x07, 0xf0, 0x03, 0xc0, 0x0f, 0xe3, 0x01,
- 0x80, 0x1f, 0xe3, 0x00, 0x00, 0x3f, 0x60, 0x00, 0x00, 0x7c, 0x10, 0x00,
- 0xc0, 0x3f, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00,
- 0xf0, 0xff, 0x7f, 0x00, 0xf0, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0x07,
- 0xc0, 0xff, 0xff, 0x0f, 0x00, 0xff, 0xff, 0x1f, 0x00, 0x00, 0xe0, 0x1f,
- 0xf0, 0x00, 0x80, 0x0f, 0x78, 0x10, 0x80, 0x07, 0x78, 0x10, 0xc0, 0x13,
- 0x70, 0xe0, 0xff, 0x08, 0xf0, 0x00, 0x00, 0x06, 0xc0, 0x03, 0xe0, 0x01,
- 0x00, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/Master/tlpkg/tlgs/lib/gs_m.xpm b/Master/tlpkg/tlgs/lib/gs_m.xpm deleted file mode 100644 index d99770097a9..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_m.xpm +++ /dev/null @@ -1,44 +0,0 @@ -/* XPM */
-static char * gs_m_xpm[] = {
-/* width height ncolors cpp [x_hot y_hot] */
-"32 32 6 1 0 0",
-/* colors */
-" s none m none c none",
-". s iconColor1 m black c black",
-"X s iconColor2 m white c white",
-"o c #C0C0C0C0C0C0",
-"O c #808080808080",
-"+ c #00000000FFFF",
-/* pixels */
-" .X ",
-" .X. ",
-" .XX. ",
-" ........XXX.. ",
-" .........oXXXo.. ",
-" .......XXXXXXO... ",
-" ......XXXXXXX...... ",
-" .....XXXX+XX........ ",
-" ......XX+X+XX........ ",
-" ......XX+XXXXX....... ",
-" ......XXXXXXXXX...... ",
-" ......XXXX++XXX.... ",
-" .....OXXX++XXX... ",
-" ......XXXXXXX.. ",
-" .....XXXXX. ",
-" ........XXXXXXX ",
-" .....XXXXXXXXXXXX ",
-" .......XXXXXXXXXXXX ",
-" ...................X ",
-" ...................... ",
-" ...................... ",
-" ...................... ",
-" ..................... ",
-" XXXXXXXXXXXX........ ",
-" ....XXXXXXXXXXXXXXX.....X ",
-" ....XXXXX.XXXXXXXXXX....XX ",
-" ....XXXXX.XXXXXXXXX....XX. ",
-" ...XXXXXX...........XXX. ",
-" ....XXXXXXXXXXXXXXXXX.. ",
-" ....XXXXXXXXXXX.... ",
-" ............. ",
-" "};
diff --git a/Master/tlpkg/tlgs/lib/gs_m_m.xbm b/Master/tlpkg/tlgs/lib/gs_m_m.xbm deleted file mode 100644 index c792a4f5239..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_m_m.xbm +++ /dev/null @@ -1,16 +0,0 @@ -#define gs_m_m.xbm_width 32
-#define gs_m_m.xbm_height 32
-#define gs_m_m.xbm_x_hot 0
-#define gs_m_m.xbm_y_hot 0
-static unsigned char gs.m_m.bm_bits[] = {
- 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x78, 0x00,
- 0x00, 0xf8, 0xff, 0x00, 0x00, 0xff, 0xff, 0x00, 0x80, 0xff, 0xff, 0x00,
- 0xc0, 0xff, 0xff, 0x01, 0xc0, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0x03,
- 0xe0, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0x03, 0xc0, 0xff, 0xff, 0x01,
- 0x80, 0xff, 0xff, 0x00, 0x00, 0xff, 0x7f, 0x00, 0x00, 0xfc, 0x1f, 0x00,
- 0xc0, 0xff, 0x1f, 0x00, 0xe0, 0xff, 0x3f, 0x00, 0xf0, 0xff, 0x7f, 0x00,
- 0xf0, 0xff, 0xff, 0x00, 0xf0, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0x07,
- 0xc0, 0xff, 0xff, 0x0f, 0x00, 0xff, 0xff, 0x1f, 0x00, 0xfe, 0xff, 0x1f,
- 0xf0, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f,
- 0xf0, 0xff, 0xff, 0x0f, 0xf0, 0xff, 0xff, 0x07, 0xc0, 0xff, 0xff, 0x01,
- 0x00, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00};
diff --git a/Master/tlpkg/tlgs/lib/gs_mex_e.ps b/Master/tlpkg/tlgs/lib/gs_mex_e.ps deleted file mode 100644 index 94711299faf..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_mex_e.ps +++ /dev/null @@ -1,66 +0,0 @@ -% Copyright (C) 1994, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_mex_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the MacExpert encoding vector.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/MacExpertEncoding
-% \00x
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-% \04x
- /space /exclamsmall /Hungarumlautsmall /centoldstyle /dollaroldstyle /dollarsuperior /ampersandsmall /Acutesmall
- /parenleftsuperior /parenrightsuperior /twodotenleader /onedotenleader /comma /hyphen /period /fraction
- /zerooldstyle /oneoldstyle /twooldstyle /threeoldstyle /fouroldstyle /fiveoldstyle /sixoldstyle /sevenoldstyle
- /eightoldstyle /nineoldstyle /colon /semicolon /.notdef /threequartersemdash /.notdef /questionsmall
-% \10x
- /.notdef /.notdef /.notdef /.notdef /Ethsmall /.notdef /.notdef /onequarter
- /onehalf /threequarters /oneeighth /threeeighths /fiveeighths /seveneighths /onethird /twothirds
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /ff /fi
- /fl /ffi /ffl /parenleftinferior /.notdef /parenrightinferior /Circumflexsmall /hypheninferior
-% \14x
- /Gravesmall /Asmall /Bsmall /Csmall /Dsmall /Esmall /Fsmall /Gsmall
- /Hsmall /Ismall /Jsmall /Ksmall /Lsmall /Msmall /Nsmall /Osmall
- /Psmall /Qsmall /Rsmall /Ssmall /Tsmall /Usmall /Vsmall /Wsmall
- /Xsmall /Ysmall /Zsmall /colonmonetary /onefitted /rupiah /Tildesmall /.notdef
-% \20x
- /.notdef /asuperior /centsuperior /.notdef /.notdef /.notdef /.notdef /Aacutesmall
- /Agravesmall /Acircumflexsmall /Adieresissmall /Atildesmall /Aringsmall /Ccedillasmall /Eacutesmall /Egravesmall
- /Ecircumflexsmall /Edieresissmall /Iacutesmall /Igravesmall /Icircumflexsmall /Idieresissmall /Ntildesmall /Oacutesmall
- /Ogravesmall /Ocircumflexsmall /Odieresissmall /Otildesmall /Uacutesmall /Ugravesmall /Ucircumflexsmall /Udieresissmall
-% \24x
- /.notdef /eightsuperior /fourinferior /threeinferior /sixinferior /eightinferior /seveninferior /Scaronsmall
- /.notdef /centinferior /twoinferior /.notdef /Dieresissmall /.notdef /Caronsmall /osuperior
- /fiveinferior /.notdef /commainferior /periodinferior /Yacutesmall /.notdef /dollarinferior /.notdef
- /.notdef /Thornsmall /.notdef /nineinferior /zeroinferior /Zcaronsmall /AEsmall /Oslashsmall
-% \30x
- /questiondownsmall /oneinferior /Lslashsmall /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /Cedillasmall /.notdef /.notdef /.notdef /.notdef /.notdef /OEsmall
- /figuredash /hyphensuperior /.notdef /.notdef /.notdef /.notdef /exclamdownsmall /.notdef
- /Ydieresissmall /.notdef /onesuperior /twosuperior /threesuperior /foursuperior /fivesuperior /sixsuperior
-% \34x
- /sevensuperior /ninesuperior /zerosuperior /.notdef /esuperior /rsuperior /tsuperior /.notdef
- /.notdef /isuperior /ssuperior /dsuperior /.notdef /.notdef /.notdef /.notdef
- /.notdef /lsuperior /Ogoneksmall /Brevesmall /Macronsmall /bsuperior /nsuperior /msuperior
- /commasuperior /periodsuperior /Dotaccentsmall /Ringsmall /.notdef /.notdef /.notdef /.notdef
-256 packedarray
-6 1 index .registerencoding
-.defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_mgl_e.ps b/Master/tlpkg/tlgs/lib/gs_mgl_e.ps deleted file mode 100644 index cb6cefe9795..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_mgl_e.ps +++ /dev/null @@ -1,64 +0,0 @@ -% Copyright (C) 1999, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_mgl_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Macintosh standard glyph encoding vector.
-% This is not an Encoding strictly speaking, but we treat it like one.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/MacRomanEncoding .findencoding
-/MacGlyphEncoding
- /.notdef /.null /CR
-% 3
-4 index 32 95 getinterval aload pop
-% 98
-99 index 128 45 getinterval aload pop
-% 143
- /notequal /AE
- /Oslash /infinity /plusminus /lessequal /greaterequal
- /yen /mu1 /partialdiff /summation /product
- /pi /integral /ordfeminine /ordmasculine /Ohm
- /ae /oslash /questiondown /exclamdown /logicalnot
- /radical /florin /approxequal /increment /guillemotleft
- /guillemotright /ellipsis /nbspace
-% 173
-174 index 203 12 getinterval aload pop
- /lozenge
-% 186
-187 index 216 24 getinterval aload pop
- /applelogo
-% 211
-212 index 241 7 getinterval aload pop
- /overscore
-% 219
-220 index 249 7 getinterval aload pop
-% 226
- /Lslash /lslash /Scaron /scaron
- /Zcaron /zcaron /brokenbar /Eth /eth
- /Yacute /yacute /Thorn /thorn /minus
- /multiply /onesuperior /twosuperior /threesuperior /onehalf
- /onequarter /threequarters /franc /Gbreve /gbreve
- % The TrueType documentation says the next glyph is named
- % Idot, but the Adobe standard name for this glyph is
- % Idotaccent.
- /Idotaccent /Scedilla /scedilla /Cacute /cacute
- /Ccaron /ccaron /dmacron
-260 -1 roll pop % delete MacRomanEncoding
-258 packedarray
-7 1 index .registerencoding
-.defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_mro_e.ps b/Master/tlpkg/tlgs/lib/gs_mro_e.ps deleted file mode 100644 index ed44fbd7bb9..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_mro_e.ps +++ /dev/null @@ -1,61 +0,0 @@ -% Copyright (C) 1994, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_mro_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the MacRoman encoding vector.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/MacRomanEncoding
-StandardEncoding 0 39 getinterval aload pop
- /quotesingle
-StandardEncoding 40 56 getinterval aload pop
- /grave
-StandardEncoding 97 31 getinterval aload pop
-% \20x
- /Adieresis /Aring /Ccedilla /Eacute /Ntilde /Odieresis /Udieresis /aacute
- /agrave /acircumflex /adieresis /atilde /aring /ccedilla /eacute /egrave
- /ecircumflex /edieresis /iacute /igrave
- /icircumflex /idieresis /ntilde /oacute
- /ograve /ocircumflex /odieresis /otilde
- /uacute /ugrave /ucircumflex /udieresis
-% \24x
- /dagger /degree /cent /sterling /section /bullet /paragraph /germandbls
- /registered /copyright /trademark /acute /dieresis /.notdef /AE /Oslash
- /.notdef /plusminus /.notdef /.notdef /yen /mu /.notdef /.notdef
- /.notdef /.notdef /.notdef /ordfeminine /ordmasculine /.notdef /ae /oslash
-% \30x
- /questiondown /exclamdown /logicalnot /.notdef
- /florin /.notdef /.notdef /guillemotleft
- /guillemotright /ellipsis /space /Agrave /Atilde /Otilde /OE /oe
- /endash /emdash /quotedblleft /quotedblright
- /quoteleft /quoteright /divide /.notdef
- % NOTE: Euro should replace currency, but the PDF 1.3 documentation
- % explicitly says it does not.
- /ydieresis /Ydieresis /fraction /currency
- /guilsinglleft /guilsinglright /fi /fl
-% \34x
- /daggerdbl /periodcentered /quotesinglbase /quotedblbase
- /perthousand /Acircumflex /Ecircumflex /Aacute
- /Edieresis /Egrave /Iacute /Icircumflex
- /Idieresis /Igrave /Oacute /Ocircumflex
- /.notdef /Ograve /Uacute /Ucircumflex
- /Ugrave /dotlessi /circumflex /tilde
- /macron /breve /dotaccent /ring /cedilla /hungarumlaut /ogonek /caron
-256 packedarray
-5 1 index .registerencoding
-.defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_patrn.ps b/Master/tlpkg/tlgs/lib/gs_patrn.ps deleted file mode 100644 index 6f1e9dd5e57..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_patrn.ps +++ /dev/null @@ -1,309 +0,0 @@ -% Copyright (C) 2001, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_patrn.ps 7186 2006-11-10 12:18:42Z alexcher $
-% Pattern color space method dictionary.
-
-
-% verify that Pattern color spaces are supported
-/.setpatternspace where
- { pop }
- { currentfile closefile }
-ifelse
-
-.currentglobal true .setglobal
-.cspace_util begin
-
-%
-% <name1 | array1> get_pattern_base_cspace <null | name2 | array2>
-%
-% If the Pattern color space has a base color space, push that base
-% color space onto the stack. Otherwise, push a null object.
-%
-/get_pattern_base_cspace
- {
- dup type /nametype eq
- { pop //null }
- {
- dup length 1 gt
- { 1 get }
- { pop //null }
- ifelse
- }
- ifelse
- }
-bind def
-
-
-%
-% <dict> has_base_color <bool>
-%
-% Determine if a Pattern "color" includes a base color. This is the case
-% if the pattern dictionary has PatternType 1 and PaintType 2.
-%
-/has_base_color
- {
- dup //null eq
- { pop //false }
- {
- dup /PatternType get 1 eq
- { /PaintType get 2 eq }
- { pop //false }
- ifelse
- }
- ifelse
- }
-bind def
-
-%
-% <c1> ... <cn> <pattern_dict> <pattern_cspace>
-% get_pattern_base_color
-% <c1> ... <cn> <base_cspace> true
-% or
-% <?c1?> ... <?cn?> <dict> <pattern>
-% get_pattern_base_color
-% false
-%
-% If a pattern dictionary has a base color, set up that base color and
-% color space, and push true. Otherwise, just push false. It is assumed
-% that if the pattern includes a base color, the Pattern color space
-% has a base color space.
-%
-/get_pattern_base_color
- {
- exch //has_base_color exec
- { 1 get //true }
- { pop //false }
- ifelse
- }
-bind def
-
-
-colorspacedict
-/Pattern
- mark
- /cs_potential_indexed_base false
- /cs_potential_pattern_base false
- /cs_potential_alternate false
- /cs_potential_icc_alternate false
-
- %
- % We employ the same convention for describing the number of
- % components in a Pattern color space as is used by the graphic
- % library. For pattern spaces with no underlying color space,
- % the result is -1. If a Pattern space has an underlying color
- % space with n components, the result is -(n + 1).
- %
- /cs_get_ncomps
- {
- //get_pattern_base_cspace exec dup //null eq
- { pop 0 }
- //.cs_get_ncomps
- ifelse
- 1 add neg
- }
- bind
-
- % there is no "range" for a Pattern color space
- /cs_get_range { {} cvlit } bind
-
- /cs_get_default_color { pop //null } bind
-
- /cs_get_currentgray
- {
- //get_pattern_base_color exec
- //.cs_get_currentgray
- { 0. }
- ifelse
- }
- bind
-
- /cs_get_currentrgb
- {
- //get_pattern_base_color exec
- //.cs_get_currentrgb
- { 0. 0. 0. }
- ifelse
- }
- bind
-
- /cs_get_currentcmyk
- {
- //get_pattern_base_color exec
- //.cs_get_currentcmyk
- { 0. 0. 0. 1. }
- ifelse
- }
- bind
-
- /cs_validate
- {
- dup //get_pattern_base_cspace exec dup //null eq
- { pop }
- {
- //.cs_validate exec //.cs_potential_pattern_base exec not
- //setcspace_rangecheck
- if
- }
- ifelse
- }
- bind
-
- % substitute the base space if appropriate
- /cs_substitute
- {
- dup //get_pattern_base_cspace exec dup //null eq
- { pop dup }
- {
- //.cs_substitute exec 2 copy eq
- { pop pop dup }
- {
- % retain only the new alternate space
- exch pop
-
- % build all new structures in local VM
- .currentglobal 3 1 roll //false .setglobal
-
- % construct a new array and insert the new base color space
- 1 index dup length array copy dup 1 4 -1 roll put
-
- % restore VM mode
- 3 -1 roll .setglobal
- }
- ifelse
- }
- ifelse
- }
- bind
-
- /cs_prepare {}
-
- %
- % Install the current color space.
- %
- % The current Ghostscript color space implementation requires that
- % color spaces that provide a base or alternative color space set
- % that base/alternative color space to be the current color space
- % before attempting to set the original color space.
- %
- % In principle, the only errors that are possible for .setpatternspace
- % (given that setcolorspace itself is legal) are limitcheck and/or
- % VMerror. The Ghostscript implementation allows a few others, so
- % we go through the full code to restore the current color space in
- % the event of an error.
- %
- /cs_install
- {
- dup //get_pattern_base_cspace exec dup //null eq
- {
- pop
- dup type /nametype eq
- { pop { /Pattern } cvlit }
- if
- .setpatternspace
- }
- {
- % save the current color space
- currentcolorspace
-
- % set the base color space as the current color space
- exch //forcesetcolorspace
-
- % set the pattern color space; restore the earlier space on error
- mark 2 index
- { .setpatternspace }
- stopped
- { cleartomark setcolorspace stop }
- { pop pop pop }
- ifelse
- }
- ifelse
- }
- bind
-
-
- %
- % Pattern dictionaries generated by makepattern will include an
- % Implementation entry whose value is an internal data structure.
- % Such structures are given executable type names that match their
- % internal structure names. The names used for pattern
- % implementations are gs_pattern1_instance_t and
- % gs_pattern2_instance_t. It is unfortunate to have to expose such
- % internal names at this level, but not easily avoided.
- % For CPSI/CET compatibility we 'hide' this inside an array
- %
- /cs_prepare_color
- {
- % verify that the topmost operand is a pattern dictionary
- 1 index dup type /dicttype ne
- {
- //null ne
- //setcspace_typecheck
- if
- pop
- }
- {
- dup /Implementation .knownget
- { 0 get type dup dup
- /gs_pattern1_instance_t ne exch /gs_pattern2_instance_t ne and
- exch xcheck not
- or
- //setcspace_typecheck
- if
- }
- //setcspace_typecheck
- ifelse
-
- % check if base color space operands are present
- dup /PatternType get 1 eq
- {
- /PaintType get 2 eq
- {
- % verify that a base color space exists
- //get_pattern_base_cspace exec dup //null eq
- //setcspace_rangecheck
- if
- //.cs_get_ncomps exec
- % We cannot use check_num_stack since it does not
- % properly clean the stack. The CET test 09-47n.ps has
- % a very bad test case with a faulty setpattern call with
- % no color values. To properly handle that case and to
- % ensure that the stack is properly cleaned, we are
- % testing the type of the color values inline.
- 1 exch 1 exch
- {
- index type dup /integertype ne exch /realtype ne and
- //setcolor_typecheck
- if
- }
- for
- }
- { pop }
- ifelse
- }
- { pop pop }
- ifelse
- }
- ifelse
- }
- bind
-
- /cs_complete_setcolor //pop_1
-
- .dicttomark
-put
-
-end % .cspace_util
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_pdf_e.ps b/Master/tlpkg/tlgs/lib/gs_pdf_e.ps deleted file mode 100644 index 6ea63a66922..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_pdf_e.ps +++ /dev/null @@ -1,44 +0,0 @@ -% Copyright (C) 1994, 1997, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_pdf_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the PDFDoc encoding vector.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/PDFDocEncoding
-ISOLatin1Encoding 0 24 getinterval aload pop
- /breve /caron /circumflex /dotaccent /hungarumlaut /ogonek /ring /tilde
-ISOLatin1Encoding 32 7 getinterval aload pop
- /quotesingle
-ISOLatin1Encoding 40 5 getinterval aload pop
- /hyphen
-ISOLatin1Encoding 46 50 getinterval aload pop
- /grave
-ISOLatin1Encoding 97 31 getinterval aload pop
-% \20x
- /bullet /dagger /daggerdbl /ellipsis /emdash /endash /florin /fraction
- /guilsinglleft /guilsinglright /minus /perthousand
- /quotedblbase /quotedblleft /quotedblright /quoteleft
- /quoteright /quotesinglbase /trademark /fi /fl /Lslash /OE /Scaron
- /Ydieresis /Zcaron /dotlessi /lslash /oe /scaron /zcaron /.notdef
-% \24x
- /Euro
-ISOLatin1Encoding 161 12 getinterval aload pop
- /.notdef
-ISOLatin1Encoding 174 82 getinterval aload pop
-256 packedarray .defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_pdfwr.ps b/Master/tlpkg/tlgs/lib/gs_pdfwr.ps deleted file mode 100644 index acd5b73a83b..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_pdfwr.ps +++ /dev/null @@ -1,874 +0,0 @@ -% Copyright (C) 1996, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_pdfwr.ps 8178 2007-08-05 13:55:26Z leonardo $
-% PDF writer additions to systemdict.
-
-% This file should be included iff the pdfwrite "device" is included
-% in the executable.
-
-% ---------------- Predefined configurations ---------------- %
-
-% These correspond to the 4 predefined settings in Acrobat Distiller 5,
-% plus a "default" setting that doesn't downsample images.
-
-/.a2112 [2 1 1 2] readonly def
-/.a1111 [1 1 1 1] readonly def
-/.standardfonts [
- /Courier /Courier-Bold /Courier-Oblique /Courier-BoldOblique
- /Helvetica /Helvetica-Bold /Helvetica-Oblique /Helvetica-BoldOblique
- /Times-Roman /Times-Bold /Times-Italic /Times-BoldItalic
- /Symbol /ZapfDingbats
-] readonly def
-
-% Parameters common to all non-default configurations.
-% Note that the default configuration overrides a few of these.
-/.defaultImageDict mark
- /QFactor 0.9 /Blend 1
- /HSamples .a2112 /VSamples .a2112
-.dicttomark readonly def
-/.distillercommon mark
- /AlwaysEmbed []
- /AntiAliasColorImages false
- /AntiAliasGrayImages false
- /AntiAliasMonoImages false
- /ASCII85EncodePages false
- /AutoFilterColorImages true
- /AutoFilterGrayImages true
- /AutoPositionEPSFiles true
- /Binding /Left
- /CalCMYKProfile (None) % (U.S. Web Coated (SWOP) v2)
- /CalGrayProfile (None) % (Dot Gain 20%)
- /CalRGBProfile (None) % (sRGB IEC61966-2.1)
- /ColorImageDepth -1
- /ColorImageDict .defaultImageDict
- /ColorImageDownsampleThreshold 1.5
- /ColorImageFilter /DCTEncode
- /CompressPages true
- /ConvertImagesToIndexed true
- /DefaultRenderingIntent /Default
- /DetectBlends true
- /DownsampleColorImages true
- /DownsampleGrayImages true
- /DownsampleMonoImages true
- /EmitDSCWarnings false
- /EncodeColorImages true
- /EncodeGrayImages true
- /EncodeMonoImages true
- /EndPage -1
- /GrayImageDepth -1
- /GrayImageDict .defaultImageDict
- /GrayImageDownsampleThreshold 1.5
- /GrayImageFilter /DCTEncode
- /ImageMemory 524288
- /LockDistillerParams false
- /MaxSubsetPct 100
- /MonoImageDepth -1
- /MonoImageDict mark
- /K -1
- .dicttomark readonly
- /MonoImageDownsampleThreshold 1.5
- /MonoImageFilter /CCITTFaxEncode
- /OffOptimizations 0
- /OPM 1
- /Optimize true
- /ParseDSCComments true
- /ParseDSCCommentsForDocInfo true
- /PDFXTrimBoxToMediaBoxOffset [0 0 0 0]
- /PDFXSetBleedBoxToMediaBox true
- /PDFXBleedBoxToTrimBoxOffset [0 0 0 0]
- /PreserveCopyPage true
- /PreserveHalftoneInfo false
- /sRGBProfile (None) % (sRGB IEC61966-2.1)
- /StartPage 1
- /SubsetFonts true
- /TransferFunctionInfo /Preserve
- /UseFlateCompression true
- /UsePrologue false
-.dicttomark readonly def
-
-/.distillersettings mark
-
-/default mark
- /AutoRotatePages /PageByPage
- /CannotEmbedFontPolicy /Warning
- /ColorACSImageDict .defaultImageDict
- /ColorConversionStrategy /LeaveColorUnchanged
-% /ColorImageDownsampleType
-% /ColorImageResolution
-% /CompatibilityLevel
- /CreateJobTicket false
- /DoThumbnails false
- /DownsampleColorImages false % override
- /DownsampleGrayImages false % override
- /DownsampleMonoImages false % override
- /EmbedAllFonts true
- /GrayACSImageDict .defaultImageDict
-% /GrayImageDownsampleType
-% /GrayImageResolution
-% /MonoImageDownsampleType
-% /MonoImageResolution
- /NeverEmbed .standardfonts
- /Optimize false % override
- /PreserveEPSInfo true
- /PreserveOPIComments true
- /PreserveOverprintSettings true
- /UCRandBGInfo /Preserve
-.dicttomark readonly
-
-/.screenACSImageDict mark
- /QFactor 0.76 /Blend 1 /ColorTransform 1
- /HSamples .a2112 /VSamples .a2112
-.dicttomark readonly def
-/screen mark
- /AutoRotatePages /PageByPage
-% /CalGrayProfile (None)
- /CannotEmbedFontPolicy /Warning
- /ColorACSImageDict .screenACSImageDict
- /ColorConversionStrategy /sRGB
- /ColorImageDownsampleType /Average
- /ColorImageResolution 72
- /CompatibilityLevel 1.3
- /CreateJobTicket false
- /DoThumbnails false
- /EmbedAllFonts true
- /GrayACSImageDict .screenACSImageDict
- /GrayImageDownsampleType /Average
- /GrayImageResolution 72
- /MonoImageDownsampleType /Average
- /MonoImageResolution 300
- /NeverEmbed .standardfonts
- /PreserveEPSInfo false
- /PreserveOPIComments false
- /PreserveOverprintSettings false
- /UCRandBGInfo /Remove
-.dicttomark readonly
-
-/ebook mark
- /AutoRotatePages /All
-% /CalGrayProfile (None)
- /CannotEmbedFontPolicy /Warning
- /ColorACSImageDict .screenACSImageDict
- /ColorConversionStrategy /sRGB
- /ColorImageDownsampleType /Bicubic
- /ColorImageResolution 150
- /CompatibilityLevel 1.4
- /CreateJobTicket false
- /DoThumbnails false
- /EmbedAllFonts true
- /GrayACSImageDict .screenACSImageDict
- /GrayImageDownsampleType /Bicubic
- /GrayImageResolution 150
- /MonoImageDownsampleType /Bicubic
- /MonoImageResolution 300
- /NeverEmbed .standardfonts
- /PreserveEPSInfo false
- /PreserveOPIComments false
- /PreserveOverprintSettings false
- /UCRandBGInfo /Remove
-.dicttomark readonly
-
-/.printerACSImageDict mark
- /QFactor 0.4 /Blend 1 /ColorTransform 1
- /HSamples .a1111 /VSamples .a1111
-.dicttomark readonly def
-/printer mark
- /AutoRotatePages /None
-% /CalGrayProfile (None)
- /CannotEmbedFontPolicy /Warning
- /ColorACSImageDict .printerACSImageDict
- /ColorConversionStrategy /UseDeviceIndependentColor
- /ColorImageDownsampleType /Bicubic
- /ColorImageResolution 300
- /CompatibilityLevel 1.4
- /CreateJobTicket true
- /DoThumbnails false
- /EmbedAllFonts true
- /GrayACSImageDict .printerACSImageDict
- /GrayImageDownsampleType /Bicubic
- /GrayImageResolution 300
- /MonoImageDownsampleType /Bicubic
- /MonoImageResolution 1200
- /NeverEmbed []
- /PreserveEPSInfo true
- /PreserveOPIComments true
- /PreserveOverprintSettings true
- /UCRandBGInfo /Preserve
-.dicttomark readonly
-
-/.prepressACSImageDict mark
- /QFactor 0.15 /Blend 1 /ColorTransform 1
- /HSamples .a1111 /VSamples .a1111
-.dicttomark readonly def
-/prepress mark
- /AutoRotatePages /None
- /CannotEmbedFontPolicy /Error
- /ColorACSImageDict .prepressACSImageDict
- /ColorConversionStrategy /LeaveColorUnchanged
- /ColorImageDownsampleType /Bicubic
- /ColorImageResolution 300
- /CompatibilityLevel 1.4
- /CreateJobTicket true
- /DoThumbnails true
- /EmbedAllFonts true
- /GrayACSImageDict .prepressACSImageDict
- /GrayImageDownsampleType /Bicubic
- /GrayImageResolution 300
- /MonoImageDownsampleType /Bicubic
- /MonoImageResolution 1200
- /NeverEmbed []
- /PreserveEPSInfo true
- /PreserveOPIComments true
- /PreserveOverprintSettings true
- /UCRandBGInfo /Preserve
-.dicttomark readonly
-
-% Define distiller settings for the ps2write device and for the ps2ps2 script :
-/PSL2Printer mark
- /AutoRotatePages /None
- /CannotEmbedFontPolicy /Error
- /ColorACSImageDict .prepressACSImageDict
- /ColorConversionStrategy /LeaveColorUnchanged
- /ColorImageDownsampleType /Bicubic
- /ColorImageResolution 600
- /CompatibilityLevel 1.2 % Always 1.2 with ps2write.
- % /CreateJobTicket true % Not sure
- /DoThumbnails false
- /EmbedAllFonts true
- /GrayACSImageDict .prepressACSImageDict
- /GrayImageDownsampleType /Bicubic
- /GrayImageResolution 600
- /MonoImageDownsampleType /Bicubic
- /MonoImageResolution 1200
- /NeverEmbed []
- /PreserveEPSInfo true
- /PreserveOPIComments true
- /PreserveOverprintSettings true
- /UCRandBGInfo /Preserve
-
- /PreserveHalftoneInfo true
- /TransferFunctionInfo /Preserve
- /MaxViewerMemorySize 8000000
- /CompressPages false
- /CompressFonts false
- /ASCII85EncodePages true
-.dicttomark readonly
-
-.dicttomark readonly def
-
-% ---------------- End of predefined configurations ---------------- %
-
-% Set optimizations for converting PostScript to PDF.
-% The ps2pdf* scripts invoke this.
-/.setpdfwrite { % - .setpdfwrite -
- % Set a large VM threshold to reduce garbage collection.
- currentuserparams /VMThreshold get 3000000 .max setvmthreshold
-} bind def
-
-% ---------------- pdfmark and DSC processing ---------------- %
-
-/.write_small_positive_real % <file> <real> .write_small_positive_real -
-{ % The argument must be grater than 0 and must be strongly samller than 0.1.
- % The conversion isn't simple due to the low (24 bits) precision
- % of the floating point arithmetics in Postscript.
- % For best result we first use the 1e8 factor since its binary
- % representation 101111101011110000100000000 well rounds into 14 significant
- % bits : 101111101011110000000000000 .
- 1 index (.) writestring
- { dup 100000000 mul
- dup 10 mul 1 ge {
- % Will need not greater than 0.1 due to a rounding below.
- pop exit
- } if
- exch pop
- 1 index (00000000) writestring
- } loop
- % Now it is not smaller than 1e-9, use simple digitizing.
- { dup 10 mul
- dup 10 mul 1 ge {
- pop exit
- } if
- exch pop
- 1 index (0) writestring
- } loop
- % Now 0.01 <= n < 0.1, but rounding may give 0.1 .
- % Convert to integer with 7 digits precision :
- 100000000 % precision factor 1e8 % f n r
- dup 10 idiv 3 1 roll mul 0.5 add cvi % f r' N
- 2 copy le {
- % The rounding overflows, suppress it.
- % Note it carries out an additional digit,
- % that's why we needed <0.1 above.
- pop pop (1) writestring
- } {
- % Didn't cary out, put 0.
- 2 index (0) writestring
- exch % f N r
- % Continue the simple digitizing :
- { 10 idiv dup % f N r' r'
- 2 index exch idiv % f N r' d
- (0123456789) exch 1 getinterval % f N r' (d)
- 3 index exch writestring % f N r'
- dup 3 2 roll exch mod % f r' N'
- dup 0 eq {
- % Don't write trailing zeros.
- exit
- } if
- exch % f N' r'
- } loop
- pop pop pop
- } ifelse
-} bind def
-
-% Encode values to pass for the /pdfmark or /DSC pseudo-parameter.
-/.pdf===dict mark
- /arraytype
- { dup xcheck { ({) (}) } { ([) (]) } ifelse
- % Stack: file obj left right
- 4 1 roll 2 index exch writestring () exch
- { exch 2 index exch writestring
- 1 index exch pdf===only ( )
- }
- forall pop exch writestring
- } bind
- /packedarraytype 1 index
- /dicttype
- { 1 index (<<\n) writestring
- { 2 index 3 -1 roll pdf===only 1 index ( ) writestring
- 1 index exch pdf===only dup (\n) writestring
- }
- forall (>>) writestring
- } bind
- /nametype {
- % If the name string includes any non-regular characters,
- % write it with two preceding and one following null character(s).
- % (Null characters in the name itself are not allowed.)
- % This non-standard escape convention is required for passing names
- % that include non-regular characters, because PostScript provides
- % no way to do this. The pdf_scan_token procedure in the C code of
- % the pdfwrite driver is currently the only place that recognizes
- % this convention.
- % Note that \004 may be self-delimiting in gs, but is not in standard PS.
- dup .namestring (\000\004\011\012\014\015 %()/<>[]{}) .stringbreak null ne {
- dup .namestring (\000) .stringbreak null ne {
- /rangecheck signalerror
- } if
- 1 index <0000> writestring 1 index exch write===only 0 write
- } {
- write===only
- } ifelse
- } bind
- /realtype {
- % Prevent using floating point format - see Bug 688167.
- dup dup 0 lt { neg } if 0.01 lt {
- dup 0 eq {
- pop (0) writestring
- } {
- dup 0 lt {
- 1 index (-) writestring neg
- } if
- .write_small_positive_real
- } ifelse
- } {
- write===only
- } ifelse
- } bind
-.dicttomark readonly def
-/pdf===only { % <file> <obj> pdf===only -
- .pdf===dict 1 index type .knownget { exec } { write===only } ifelse
-} bind def
-/.pdfcvbuf 30 string def % enough for most arguments
-userdict /.pdfcvstring () put
-/.pdfcvs { % <obj> .pdfcvs <string>
- currentglobal exch false .setglobal
- /.pdfcvstring () store
- % We can't handle long values yet.
- { pop dup length 0 eq { pop } {
- /.pdfcvstring .pdfcvstring 3 -1 roll concatstrings store
- } ifelse //.pdfcvbuf
- } /NullEncode filter dup 3 -1 roll pdf===only
- closefile
- .setglobal .pdfcvstring
-} bind def
-
-% Redefine pdfmark to pass the data to the driver.
-% We use a pseudo-parameter named /pdfmark whose value is an array:
-% /key1 (value1) ... (CTM) /type
-/.pdfputparams { % -mark- <key1> <value1> ... .pdfputparams <result...>
- currentdevice null false counttomark 1 add 3 roll
- % Don't allow the page device to get cleared....
- {.putdeviceparams} .currentpagedevice pop {.setpagedevice} 3 .execn
-} bind def
-% Convert relevant operands to strings in an array.
-/.pdfcvsloop { % -mark- values ... markname start step .pdfcvsloop
- % [values ... ctm markname]
- matrix currentmatrix .pdfcvs 4 1 roll
- counttomark 1 add 2 roll
- counttomark .localvmarray astore exch pop
- 3 1 roll
- % Stack: values start step
- 2 index length 3 sub { 2 copy 2 copy get .pdfcvs put pop } for
-} bind def
-/.pdfcvsall { % -mark- values ... markname .pdfcvsall <<same>>
- 0 1 .pdfcvsloop
-} bind def
-/.pdfcvseven { % -mark- key value ... markname .pdfcvseven <<same>>
- 1 2 .pdfcvsloop
-} bind def
-/.pdfcvsnone { % -mark- values ... markname .pdfcvsnone <<same>>
- 100000 1 .pdfcvsloop
-} bind def
-/.pdfcvsfirst { % -mark- first values ... markname .pdfcvsfirst<<same>>
- .pdfcvsnone
- dup 0 2 copy get .pdfcvs put
-} bind def
-% The procedures in the following dictionary are called with the entire
-% pdfmark operand list (including the pdfmark name) on the stack;
-% they may modify this ad lib. They must call .pdfcvsxxx.
-/.pdfmarkparams mark
- % Unpack a dictionary for PUT, and don't convert stream data.
- /PUT {
- counttomark 3 eq {
- 1 index type /dicttype eq {
- pop { } forall /.PUTDICT .pdfcvsall
- } {
- pop dup type /filetype eq {
- % Read the file into a sequence of strings.
- % This isn't great, but it's simple.
- {
- dup 64000 string readstring not { exch exit } if
- exch
- } loop closefile
- } if
- /.PUTSTREAM .pdfcvsfirst
- } ifelse
- } {
- .pdfcvsall
- } ifelse
- } bind
- % Unpack the array for PUTINTERVAL.
- /PUTINTERVAL {
- pop aload pop /.PUTINTERVAL .pdfcvsall
- } bind
-.dicttomark readonly def
-/.pdfparamerror { % ? ? ? -mark- ... <errname> <opname> .pdfparamerror -
- counttomark 4 add 2 roll cleartomark pop pop pop
- .systemvar exch signalerror
-} bind def
-/pdfmark { % -mark- <key> <value> ... <markname> pdfmark -
- dup /SP eq {
- % A hack for synchronizing the clipping path.
- gsave
- [1 0 0 1 0 0] setmatrix 0 setlinewidth
- newpath -3 -3 moveto closepath stroke % Paints outside the device bbox.
- grestore
- } if
- dup /PS eq systemdict /PDFX .knownget not { false } if
- systemdict /PDFA .knownget not { false } if or and {
- % Execute it since PDF/X doesn't allow to embed it.
- pop
- { dup mark eq {
- pop exit
- } if
- 1 index /DataSource eq {
- exch pop
- cvx exec
- } {
- pop pop
- } ifelse
- } loop
- } {
- counttomark 1 add copy
- //.pdfmarkparams 1 index .knownget { exec } { .pdfcvsall } ifelse
- mark /pdfmark 3 -1 roll .pdfputparams
- dup type /booleantype ne {
- /pdfmark .pdfparamerror
- } if cleartomark
- } ifelse
-} odef
-userdict /pdfmark .undef
-currentdict /.pdfmarkparams .undef
-
-
-% <dict> .hook_DSC_Creator -
-/.pdf_hook_DSC_Creator
-{
- % If the Creator is PScript5.dll, disable the 32 /FontType resource for
- % handling GlyphNames2Unicode. Since /FontType category can't redefine,
- % we can do only with redefining the operator 'resourcestatus'.
- currentdevice .devicename /pdfwrite eq {
- /Creator .knownget {
- (PScript5.dll) search {
- pop pop
- systemdict /resourcestatus dup
- { dup /FontType eq 2 index 32 eq and {
- pop pop false
- } {
- resourcestatus
- } ifelse
- } bind .makeoperator .forceput
- } if
- pop
- } if
- } {
- pop
- } ifelse
-}
-bind def
-
-% Use the DSC processing hook to pass DSC comments to the driver.
-% We use a pseudo-parameter named DSC whose value is an array:
-% /key1 (value1) ... /type
-/.pdfdsc_dict 2 dict def
-/.pdfdsc { % <file> <DSC string> <dsc dict> [<prev proc>] .pdfdsc -
- 0 get dup null ne { 4 copy exch pop exec pop } { pop } ifelse 3 -1 roll pop
- % Stack: <dsc string> <dsc dict>
- 20 .localvmdict 1 index { 3 copy put pop pop } forall
- 3 -1 roll .parse_dsc_comments % <dsc dict> <dict> <type>
- 1 index //.pdf_hook_DSC_Creator exec
- dup /NOP ne 2 index length 1 gt or { % Skip unparsed comments
- PDFWRDEBUG { (**** DSC comment: ) print dup == 1 index === flush } if
- exch mark 4 1 roll {
- % mark <key1> <value1> ... <dsc dict> <type> <key> <value>
- 3 index 2 index known { % Skip the DSC_struct entry
- pop pop
- } {
- .pdfcvs 4 -2 roll
- } ifelse
- } forall exch pop counttomark .localvmarray astore
- mark /DSC 3 -1 roll .pdfputparams
- dup type /booleantype ne {
- /DSC .pdfparamerror
- } {
- cleartomark
- } ifelse
- } {
- pop pop pop
- } ifelse
-} bind def
-currentdict /.pdf_hook_DSC_Creator undef
-/.initialize_dsc_parser where {
- pop
- 3000 % priority
- {
- currentglobal true setglobal
- 2 dict dup .initialize_dsc_parser readonly
- currentuserparams /ProcessDSCComment get
- 1 array astore % in case the value is executable
- //.pdfdsc /exec load 4 array astore cvx readonly
- << /ProcessDSCComment 3 -1 roll >> setuserparams
- setglobal
- } bind .schedule_init
-} if
-
-% ---------------- {set,current}distillerparams ---------------- %
-
-% Define setdistillerparams / currentdistillerparams.
-% Distiller parameters are currently treated as device parameters.
-/.distillerparamkeys mark
- % General parameters -- all distillers
- /ASCII85EncodePages { }
- /AutoRotatePages { }
- /Binding { }
- /CompressPages { }
- /DefaultRenderingIntent { }
- /DetectBlends { }
- /DoThumbnails { }
- /ImageMemory { }
- /LockDistillerParams { }
- /LZWEncodePages { }
- /OPM { }
- /PreserveHalftoneInfo { }
- /PreserveOPIComments { }
- /PreserveOverprintSettings { }
- /TransferFunctionInfo { }
- /UCRandBGInfo { }
- /UseFlateCompression { }
- % General parameters -- PDF writer
- % StartPage and EndPage are renamed because EndPage
- % clashes with a page device parameter.
- /CoreDistVersion { }
- /CompatibilityLevel { }
- % ****** NOTE: StartPage and EndPage are disabled because
- % ****** EndPage clashes with a page device parameter.
-% /EndPage { exch pop /PDFEndPage exch }
- /PDFEndPage { pop pop }
-% /StartPage { exch pop /PDFStartPage exch }
- /PDFStartPage { pop pop }
- /Optimize { }
- /ParseDSCCommentsForDocInfo { }
- /ParseDSCComments { }
- /EmitDSCWarnings { }
- /CreateJobTicket { }
- /PreserveEPSInfo { }
- /AutoPositionEPSFiles { }
- /PreserveCopyPage { }
- /UsePrologue { }
- /OffOptimizations { }
- % PDF/X parameters
- /PDFXTrimBoxToMediaBoxOffset { }
- /PDFXSetBleedBoxToMediaBox { }
- /PDFXBleedBoxToTrimBoxOffset { }
- % Color sampled image parameters
- /ColorACSImageDict { }
- /AntiAliasColorImages { }
- /AutoFilterColorImages { }
- /ColorImageDepth { }
- /ColorImageDict { }
- /DownsampleColorImages { }
- /ColorImageDownsampleThreshold { }
- /ColorImageDownsampleType { }
- /EncodeColorImages { }
- /ColorImageFilter { }
- /ColorImageResolution { }
- % Color processing parameters
- /CalCMYKProfile { }
- /CalGrayProfile { }
- /CalRGBProfile { }
- /sRGBProfile { }
- /ColorConversionStrategy { }
- /ConvertCMYKImagesToRGB { }
- /ConvertImagesToIndexed { }
- % Grayscale sampled image parameters
- /GrayACSImageDict { }
- /AntiAliasGrayImages { }
- /AutoFilterGrayImages { }
- /GrayImageDepth { }
- /GrayImageDict { }
- /DownsampleGrayImages { }
- /GrayImageDownsampleThreshold { }
- /GrayImageDownsampleType { }
- /EncodeGrayImages { }
- /GrayImageFilter { }
- /GrayImageResolution { }
- % Monochrome sampled image parameters
- /AntiAliasMonoImages { }
- /MonoImageDepth { }
- /MonoImageDict { }
- /DownsampleMonoImages { }
- /MonoImageDownsampleThreshold { }
- /MonoImageDownsampleType { }
- /EncodeMonoImages { }
- /MonoImageFilter { }
- /MonoImageResolution { }
- % Font embedding parameters
- /AlwaysEmbed
- { dup length 0 gt
- { dup 0 get false eq
- { dup length 1 sub 1 exch getinterval exch pop /~AlwaysEmbed exch
- } if
- } if
- }
- /NeverEmbed
- { dup length 0 gt
- { dup 0 get false eq
- { dup length 1 sub 1 exch getinterval exch pop /~NeverEmbed exch
- } if
- } if
- }
- /CannotEmbedFontPolicy { }
- /EmbedAllFonts { }
- /MaxSubsetPct { }
- /SubsetFonts { }
- /DSCEncodingToUnicode { }
-.dicttomark readonly def
-/.distillerdevice
- { currentdevice .devicename dup /pdfwrite eq exch /ps2write eq or
- { currentdevice }
- { /pdfwrite finddevice }
- ifelse
- } bind def
-
-% Some badly designed PostScript files only expect the current/set
-% distillerparams operators to exist in a distiller. Since we have
-% this as a runtime option, we enable these operators IFF the
-% currentdevice is pdfwrite. Also, we mask their existence in
-% systemdict so that 'where' and 'known' don't show them unless
-% the currentdevice is pdfwrite.
-/.setdistillerparams { % <dict> setdistillerparams -
- .distillerdevice //null false mark 4 index {
- //.distillerparamkeys 2 index .knownget { exec } { pop pop } ifelse
- } forall .putdeviceparamsonly
- dup type /booleantype ne {
- /setdistillerparams .pdfparamerror
- } {
- pop pop pop
- } ifelse
-} odef
-/.currentdistillerparams { % - currentdistillerparams <dict>
- .distillerdevice //.distillerparamkeys .getdeviceparams .dicttomark
- % Patch StartPage and EndPage
- % ****** NOTE: StartPage and EndPage are disabled because
- % ****** EndPage clashes with a page device parameter.
-% begin /StartPage PDFStartPage /EndPage PDFEndPage
-% currentdict dup /PDFStartPage undef /PDFEndPage undef
-% def def currentdict end
-} odef
-/setdistillerparams {
- currentdevice .devicename dup /pdfwrite ne exch /ps2write ne and {
- /setdistillerparams /undefined signalerror
- } if
- .setdistillerparams
-} bind odef
-/currentdistillerparams {
- currentdevice .devicename dup /pdfwrite ne exch /ps2write ne and {
- /currentdistillerparams /undefined signalerror
- } if
- .currentdistillerparams
-} bind odef
-
-% Patch 'where' so that the distiller operators are only visible
-% if the pdfwrite device is the current one.
-{ currentdevice .devicename dup /pdfwrite eq exch /ps2write eq or{
- .where
- } {
- .where pop dup //systemdict eq { pop false } { true } ifelse
- } ifelse
-} bind
-{ /currentdistillerparams /setdistillerparams /pdfmark }
-{ .wheredict exch 2 index put } forall pop
-
-% Patch 'known' to hide the systemdict version of distiller operators
-% unless the currentdevice is pdfwrite.
-/known {
- /currentdistillerparams 1 index eq /setdistillerparams 2 index eq or
- /pdfmark 2 index eq or {
- systemdict 2 index eq { % only mask the operator in systemdict
- known currentdevice .devicename dup /pdfwrite ne exch /ps2write ne and { pop false } if
- } {
- known
- } ifelse
- } {
- known
- } ifelse
-} .bind odef
-
-% Create a table for translation DSC comments into Unicode UTF-16
-/.make_DSC_translation_table { % <encoding> .make_DSC_translation_table <array>
- dup type /stringtype eq {
- cvn
- } if
- dup type /nametype eq {
- /Encoding findresource
- } if
- dup length array exch % [out] [in]
- 0 1 2 index length 1 sub { % [out] [in] i
- dup 2 index exch get % [out] [in] i n
- dup dup null eq exch /.notdef eq or {
- pop -1
- } {
- dup //AdobeGlyphList exch .knownget { % [out] [in] i n c
- dup type dup /arraytype eq exch /packedarraytype eq or {
- 0 get % fixme: using the 1st char
- } if
- exch pop % [out] [in] i c
- } { % [out] [in] i n
- (DSCEncoding defines a character that is not in AdobeGlyphList : )
- exch .namestring concatstrings =
- /.make_DSC_translation_table cvx /undefined signalerror
- } ifelse
- } ifelse
- 3 index % [out] [in] i c [out]
- 3 1 roll put % [out] [in]
- } for
- pop % [out]
-} bind def
-
-1000 % priority
-{
- % Note, this may not work if the initial device is not pdfwrite
- % and may require the use of -dProvideUnicode on the command line.
- currentdevice .devicename /pdfwrite eq
- systemdict /ProvideUnicode .knownget not { false } if or {
- currentglobal true setglobal
- systemdict /.setupUnicodeDecoder known {
- /Unicode /Decoding resourcestatus {
- pop pop
- /Unicode /Decoding findresource
- .setupUnicodeDecoder
- } {
- QUIET not {
- (WARNING: /Unicode /Decoding resource is not accessible but it is useful for generating ToUnicode CMap.) =
- } if
- } ifelse
- } if
- setglobal
- } if
-} bind .schedule_init
-
-1010 % priority
-{
- % Set a predefined configuration in the distiller device (pdfwrite)
- /PDFSETTINGS where {
- pop /PDFSETTINGS load
- } {
- currentdevice .devicename /ps2write eq { /PSL2Printer } { /default } ifelse
- } ifelse
- .distillersettings exch get
- % Don't override parameters defined on the command line.
- dup length .distillercommon length add dict begin
- .distillercommon 2 {
- {
- systemdict 2 index known { pop pop } { def } ifelse
- } forall
- } repeat
- currentdevice .devicename /pdfwrite eq {
- systemdict /PDFX known systemdict /PDFA known or {
- /DSCEncoding where {
- /DSCEncoding get .make_DSC_translation_table
- /DSCEncodingToUnicode exch def
- } if
- } if
- } if
- currentdict end .setdistillerparams
- .distillerdevice //null false mark .putdeviceparams
- dup type /booleantype eq not { cleartomark pop } if pop pop
-} bind .schedule_init
-
-% Set a path to library files (ps2write)
-.defaultdevicename /ps2write eq {
- mark
- /OPDFReadProcsetPath
- systemdict /OPDFReadProcsetPath .knownget dup { % check for a value on the command-line
- 1 index () eq {
- (Configuration warning : empty OPDFReadProcsetPath, will use defaults.) =
- systemdict /OPDFReadProcsetPath undef
- pop pop false
- } if
- } if
- not { % if necessary, compute a default
- mark
- (gs_mgl_e.ps) (gs_mro_e.ps) (gs_agl.ps) (opdfread.ps) % Reverse order !
- () counttomark 1 sub {
- exch
- .libfile { .filename } { false } ifelse not {
- (Configuration error : library file opdfread.ps not found !) =
- (opdfread.ps) /undefinedfilename signalerror
- } if
- .filenamelistseparator concatstrings concatstrings
- } repeat
- exch pop
- } if
- %stack: mark /OPDFReadProcsetPath <filelist>
- /ps2write finddevice putdeviceprops pop % set the default instance's procset path
-} if
-
-2000 % priority
-{ % Note, this may not work if the initial device is not pdfwrite
- currentdevice .devicename dup /pdfwrite eq exch /ps2write eq or {
- % Inform the device with initial graphic state. See gdev_pdf_fill_path.
- newpath fill
- } if
-} bind .schedule_init
diff --git a/Master/tlpkg/tlgs/lib/gs_pfile.ps b/Master/tlpkg/tlgs/lib/gs_pfile.ps deleted file mode 100644 index 1f119e69260..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_pfile.ps +++ /dev/null @@ -1,127 +0,0 @@ -% Copyright (C) 1994, 1995 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_pfile.ps 6300 2005-12-28 19:56:24Z giles $
-% Runtime support for minimum-space fonts and packed files.
-
-% ****** NOTE: This file must be kept consistent with
-% ****** packfile.ps and wrfont.ps.
-
-% ---------------- Packed file support ---------------- %
-
-% A packed file is the concatenation of several file groups, each of which
-% is the result of compressing several files concatenated together.
-% The packed file begins with a procedure that creates an appropriate
-% decoding filter for each file group, as follows:
-% <group-subfile-filter> -proc- <group-decode-filter>
-% Thus, accessing an individual file requires 4 parameters:
-% the starting address and length of the outer compressed file,
-% and the starting address and length of the inner file.
-/.packedfilefilter % <file> <ostart> <olength> <istart> <ilength>
- % .packedfilefilter <filter>
- { 4 index systemdict begin token pop end 6 1 roll
- % Stack: fproc file ostart olength istart ilength
- 4 index 5 -1 roll setfileposition
- % Stack: fproc file olength istart ilength
- 4 -2 roll () /SubFileDecode filter
- % Stack: fproc istart ilength ofilter
- 4 -1 roll exec
- % Filters don't support setfileposition, so we must skip data
- % by reading it into a buffer. We rely on the fact that
- % save/restore don't affect file positions.
- % Stack: istart ilength dfilter
- save exch 64000 string
- % Stack: istart ilength save dfilter scratch
- 4 index 1 index length idiv { 2 copy readstring pop pop } repeat
- 2 copy 0 8 -1 roll 2 index length mod getinterval readstring pop pop pop
- % Stack: ilength save dfilter
- exch restore exch () /SubFileDecode filter
- } bind def
-
-% Run a packed library file.
-/.runpackedlibfile % <filename> <ostart> <olength> <istart> <ilength>
- % .runpackedlibfile
- { 5 -1 roll findlibfile
- { exch pop dup 6 2 roll .packedfilefilter
- currentobjectformat exch 1 setobjectformat run
- setobjectformat closefile
- }
- { 5 1 roll /findlibfile .systemvar /undefinedfilename signalerror
- }
- ifelse
- } bind def
-
-% ---------------- Compacted font support ---------------- %
-
-% Compacted fonts written by wrfont.ps depend on the existence and
-% specifications of the procedures and data in this section.
-
-/.compactfontdefault mark
- /PaintType 0
- /FontMatrix [0.001 0 0 0.001 0 0] readonly
- /FontType 1
- /Encoding StandardEncoding
-.dicttomark readonly def
-
-/.checkexistingfont % <fontname> <uid> <privatesize> <fontsize>
- % .checkexistingfont
- % {} (<font> on d-stack)
- % <fontname> <uid> <privatesize> <fontsize>
- % .checkexistingfont
- % -save- --restore-- (<font> on d-stack)
- { FontDirectory 4 index .knownget
- { dup /UniqueID .knownget
- { 4 index eq exch /FontType get 1 eq and }
- { pop false }
- ifelse
- }
- { false
- }
- ifelse
- { save /restore load 6 2 roll }
- { {} 5 1 roll }
- ifelse
- dict //.compactfontdefault exch .copydict begin
- dict /Private exch def
- Private begin
- /MinFeature {16 16} def
- /Password 5839 def
- /UniqueID 1 index def
- end
- /UniqueID exch def
- /FontName exch def
- } bind def
-
-/.knownEncodings [
- ISOLatin1Encoding
- StandardEncoding
- SymbolEncoding
-] readonly def
-
-/.readCharStrings % <count> <encrypt> .readCharStrings <dict>
- { exch dup dict dup 3 -1 roll
- { currentfile token pop dup type /integertype eq
- { dup -8 bitshift //.knownEncodings exch get exch 255 and get } if
- currentfile token pop dup type /nametype eq
- { 2 index exch get
- }
- { % Stack: encrypt dict dict key value
- 4 index { 4330 exch dup .type1encrypt exch pop } if
- readonly
- }
- ifelse put dup
- }
- repeat pop exch pop
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/gs_rdlin.ps b/Master/tlpkg/tlgs/lib/gs_rdlin.ps deleted file mode 100644 index e330f686c73..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_rdlin.ps +++ /dev/null @@ -1,20 +0,0 @@ -% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_rdlin.ps 6300 2005-12-28 19:56:24Z giles $
-% Patch for systems with readline support in the interpreter.
-
-% Disable the prompt message, since readline will generate it.
-/.promptmsg { } def
diff --git a/Master/tlpkg/tlgs/lib/gs_res.ps b/Master/tlpkg/tlgs/lib/gs_res.ps deleted file mode 100644 index 5ad6e404f09..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_res.ps +++ /dev/null @@ -1,1119 +0,0 @@ -% Copyright (C) 1994, 1996, 1997, 1998, 1999, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_res.ps 7724 2007-02-20 23:54:19Z alexcher $
-% Initialization file for Level 2 resource machinery.
-% When this is run, systemdict is still writable,
-% but (almost) everything defined here goes into level2dict.
-
-level2dict begin
-
-(BEGIN RESOURCES) VMDEBUG
-
-% We keep track of (global) instances with another entry in the resource
-% dictionary, an .Instances dictionary. For categories with implicit
-% instances, the values in .Instances are the same as the keys;
-% for other categories, the values are [instance status size].
-
-% Note that the dictionary that defines a resource category is stored
-% in global VM. The PostScript manual says that each category must
-% manage global and local instances separately. However, objects in
-% global VM other than systemdict can't reference objects in local VM.
-% This means that the resource category dictionary, which would otherwise be
-% the obvious place to keep track of the instances, can't be used to keep
-% track of local instances. Instead, we define a dictionary in local VM
-% called localinstancedict, in which the key is the category name and
-% the value is the analogue of .Instances for local instances.
-
-% We don't currently implement automatic resource unloading.
-% When and if we do, it should be hooked to the garbage collector.
-% However, Ed Taft of Adobe says their interpreters don't implement this
-% either, so we aren't going to worry about it for a while.
-
-currentglobal false setglobal systemdict begin
- /localinstancedict 5 dict
- .forcedef % localinstancedict is local, systemdict is global
-end true setglobal
-/.emptydict 0 dict readonly def
-setglobal
-
-% Resource category dictionaries have the following keys (those marked with
-% * are optional):
-% Standard, defined in the Red Book:
-% Category (name)
-% *InstanceType (name)
-% DefineResource
-% <key> <instance> DefineResource <instance>
-% UndefineResource
-% <key> UndefineResource -
-% FindResource
-% <key> FindResource <instance>
-% ResourceStatus
-% <key> ResourceStatus <status> <size> true
-% <key> ResourceStatus false
-% ResourceForAll
-% <template> <proc> <scratch> ResourceForAll -
-% *ResourceFileName
-% <key> <scratch> ResourceFileName <filename>
-% Additional, specific to our implementation:
-% .Instances (dictionary)
-% .LocalInstances
-% - .LocalInstances <dict>
-% .GetInstance
-% <key> .GetInstance <instance> -true-
-% <key> .GetInstance -false-
-% .CheckResource
-% <key> <value> .CheckResource <key> <value> <ok>
-% (or may give an error if not OK)
-% .DoLoadResource
-% <key> .DoLoadResource <key> (may give an error)
-% .LoadResource
-% <key> .LoadResource - (may give an error)
-% .ResourceFile
-% <key> .ResourceFile <file> -true-
-% <key> .ResourceFile <key> -false-
-% .ResourceFileStatus
-% <key> .ResourceFileStatus 2 <vmusage> -true-
-% <key> .ResourceFileStatus -false-
-% All the above procedures expect that the top dictionary on the d-stack
-% is the resource dictionary.
-
-% Define enough of the Category category so we can define other categories.
-% The dictionary we're about to create will become the Category
-% category definition dictionary.
-
-% .findcategory and .resourceexec are only called from within the
-% implementation of the resource 'operators', so they don't have to worry
-% about cleaning up the stack if they fail (the interpreter's stack
-% protection machinery for pseudo-operators takes care of this).
-% Note that all places that look up categories must use .findcategory
-% so that the command in case of error will be correct rather than an
-% internal invocation of findresource.
-/.findcategory { % <name> .findcategory -
- % (pushes the category on the dstack)
- /Category .findresource begin % note: *not* findresource
-} bind def
-
-% If an error occurs within the logic of a resource operator (after operand
-% acquisition and checking), the Adobe interpreters report the operator name,
-% not the operator object, as the command in $error. For this reason, and
-% this reason only, all resource operators must wrap their logic code in
-% /<opername> cvx { ...logic... } .errorexec
-
-% The Category resource signals /undefined rather than /undefinedresource,
-% both when referenced implicitly (to look up the category for a general
-% resource operation) and when it is accessed directly (/Category /xxx
-% findresource). Because of this, all resource operators must use
-% .undefinedresource rather than signalling undefinedresource directly.
-/.undefinedresource { % <command> .undefinedresource -
- /Category dup load eq { /undefined } { /undefinedresource } ifelse
- signaloperror
-} bind def
-
-/.resourceexec { % <key> /xxxResource .resourceexec -
- % (also pops the category from the dstack)
- load exec end
-} bind def
-
-% .getvminstance treats instances on disk as undefined.
-/.getvminstance { % <key> .getvminstance <instance> -true-
- % <key> .getvminstance -false-
- .GetInstance {
- dup 1 get 2 ne { true } { pop false } ifelse
- } {
- false
- } ifelse
-} bind def
-
-20 dict begin
-
- % Standard entries
-
-/Category /Category def
-/InstanceType /dicttype def
-
-/DefineResource {
- .CheckResource {
- dup /Category 3 index cvlit .growput
- dup [ exch 0 -1 ] exch
- .Instances 4 2 roll put
- % Make the Category dictionary read-only. We will have to
- % use .forceput / .forcedef later to replace the dummy,
- % empty .Instances dictionary with the real one later.
- readonly
- } {
- /defineresource cvx /typecheck signaloperror
- } ifelse
-} bind def
-/FindResource % (redefined below)
- { .Instances exch get 0 get
- } bind def
-
- % Additional entries
-
-/.Instances 30 dict def
-.Instances /Category [currentdict 0 -1] put
-
-/.LocalInstances 0 dict def
-/.GetInstance
- { .Instances exch .knownget
- } bind def
-/.CheckResource
- { dup gcheck currentglobal and
- { /DefineResource /FindResource /ResourceForAll /ResourceStatus
- /UndefineResource }
- { 2 index exch known and }
- forall
- not { /defineresource cvx /invalidaccess signaloperror } if
- true
- } bind def
-
-.Instances end begin % for the base case of findresource
-
-(END CATEGORY) VMDEBUG
-
-% Define the resource operators. We use the "stack protection" feature of
-% odef to make sure the stacks are restored properly on an error.
-% This requires that the operators not pop anything from the stack until
-% they have executed their logic successfully. We can't make this
-% work for resourceforall, because the procedure it executes mustn't see
-% the operands of resourceforall on the stack, but we can make it work for
-% the others.
-
-% findresource is the only operator that needs to bind //Category.
-% We define its contents as a separate procedure so that .findcategory
-% can use it without entering another level of pseudo-operator.
-/.findresource { % <key> <category> findresource <instance>
- 2 copy dup /Category eq
- { pop //Category 0 get begin } { .findcategory } ifelse
- /FindResource .resourceexec exch pop exch pop
-} bind
-end % .Instances of Category
-def
-/findresource {
- % See above re .errorexec.
- 1 .argindex % also catch stackunderflow
- dup type /stringtype eq { cvn } if % for CET 23-13-04
- 3 1 roll exch pop
- dup type /nametype ne {
- /findresource .systemvar /typecheck signalerror
- } if
- /findresource cvx //.findresource .errorexec
-} odef
-
-/defineresource { % <key> <instance> <category> defineresource <instance>
- 2 .argindex 2 index 2 index % catch stackunderflow
- % See above re .errorexec.
- /defineresource cvx {
- .findcategory
- currentdict /InstanceType known {
- dup type InstanceType ne {
- dup type /packedarraytype eq InstanceType /arraytype eq and
- not { /defineresource cvx /typecheck signaloperror } if
- } if
- } if
- /DefineResource .resourceexec
- 4 1 roll pop pop pop
- } .errorexec
-} bind odef
-% We must prevent resourceforall from automatically restoring the stacks,
-% because we don't want the stacks restored if proc causes an error or
-% executes a 'stop'. On the other hand, resourceforall is defined in the
-% PLRM as an operator, so it must have type /operatortype. We hack this
-% by taking advantage of the fact that the interpreter optimizes tail
-% calls, so stack protection doesn't apply to the very last token of an
-% operator procedure.
-/resourceforall1 { % <template> <proc> <scratch> <category> resourceforall1 -
- dup .findcategory
- /ResourceForAll load
- % Stack: <template> <proc> <scratch> <category> proc
- exch pop % pop the category
- exec end
-} bind def
-/resourceforall { % <template> <proc> <scratch> <category> resourceforall1 -
- //resourceforall1 exec % see above
-} bind odef
-/resourcestatus { % <key> <category> resourcestatus <status> <size> true
- % <key> <category> resourcestatus false
- {
- 0 .argindex type /nametype ne {
- % CET 23-26 wants typecheck here, not undefineresource that happens
- % without the check.
- /resourcestatus cvx /typecheck signalerror
- } if
- 2 copy .findcategory /ResourceStatus .resourceexec
- { 4 2 roll pop pop true } { pop pop false } ifelse
- } stopped {
- % Although resourcestatus is an operator, Adobe uses executable name
- % for error reporting. CET 23-26
- /resourcestatus cvx $error /errorname get signalerror
- } if
-} bind odef
-/undefineresource { % <key> <category> undefineresource -
- 0 .argindex type /nametype ne {
- /undefinedresource cvx /typecheck signaloperror
- } if
- 1 .argindex 1 index % catch stackunderflow
-
- { .findcategory /UndefineResource .resourceexec pop pop
- } stopped {
- % Although undefineresource is an operator, Adobe uses executable name
- % here but uses operator for the errors above. CET 23-33
- /undefineresource cvx $error /errorname get signalerror
- } if
-} bind odef
-
-% Define the system parameters used for the Generic implementation of
-% ResourceFileName.
-systemdict begin
-
-% - .default_resource_dir <string>
-/.default_resource_dir {
- .file_name_parent .file_name_directory_separator concatstrings
- (Resource) concatstrings
- /LIBPATH .systemvar {
- dup .file_name_current eq {
- pop
- } {
- 1 index false .file_name_combine {
- exch pop exit
- } {
- pop pop
- } ifelse
- } ifelse
- } forall
-} bind def
-
-% <path> <name> <string> .resource_dir_name <path> <name> <string>
-/.resource_dir_name
-{ systemdict 2 index .knownget {
- exch pop
- systemdict 1 index undef
- } {
- dup () ne {
- .file_name_directory_separator concatstrings
- } if
- 2 index exch false .file_name_combine not {
- (Error: .default_resource_dir returned ) print exch print ( that can't combine with ) print =
- /.default_resource_dir cvx /configurationerror signalerror
- } if
- } ifelse
-} bind def
-
-currentdict /pssystemparams known not {
- /pssystemparams 10 dict readonly def
-} if
-pssystemparams begin
- .default_resource_dir
- /FontResourceDir (Font) .resource_dir_name
- readonly .forcedef % pssys'params is r-o
- /GenericResourceDir () .resource_dir_name
- readonly .forcedef % pssys'params is r-o
- pop % .default_resource_dir
- /GenericResourcePathSep
- .file_name_separator readonly .forcedef % pssys'params is r-o
- (%diskFontResourceDir) cvn (/Resource/Font/) readonly .forcedef % pssys'params is r-o
- (%diskGenericResourceDir) cvn (/Resource/) readonly .forcedef % pssys'params is r-o
-end
-end
-
-% Check if GenericResourceDir presents in LIBPATH.
-
-% The value of GenericResourceDir must end with directory separator.
-% We use .file_name_combine to check it.
-% Comments use OpenVMS syntax, because it is the most complicated case.
-(x) pssystemparams /GenericResourcePathSep get
-(y) concatstrings concatstrings dup length % (x]y) l1
-pssystemparams /GenericResourceDir get dup length exch % (x]y) l1 l2 (dir)
-3 index true .file_name_combine not {
- exch
- (File name ) print print ( cant combine with ) print =
- /GenericResourceDir cvx /configurationerror signaloperror
-} if
-dup length % (x]y) l1 l2 (dir.x]y) l
-4 2 roll add % (x]y) (dir.x]y) l ll
-ne {
- (GenericResourceDir value does not end with directory separator.\n) =
- /GenericResourceDir cvx /configurationerror signaloperror
-} if
-pop pop
-
-% Define the generic algorithm for computing resource file names.
-/.rfnstring 8192 string def
-/.genericrfn % <key> <scratch> <prefix> .genericrfn <filename>
- { 3 -1 roll //.rfnstring cvs concatstrings exch copy
- } bind def
-
-% Define the Generic category.
-
-/Generic mark
-
- % Standard entries
-
-% We're still running in Level 1 mode, so dictionaries won't expand.
-% Leave room for the /Category entry.
-/Category null
-
-% Implement the body of Generic resourceforall for local, global, and
-% external cases. 'args' is [template proc scratch resdict].
-/.enumerateresource { % <key> [- <proc> <scratch>] .enumerateresource -
- 1 index type dup /stringtype eq exch /nametype eq or {
- exch 1 index 2 get cvs exch
- } if
- % Use .setstackprotect to prevent the stacks from being restored if
- % an error occurs during execution of proc.
- 1 get false .setstackprotect exec true .setstackprotect
-} bind def
-/.localresourceforall { % <key> <value> <args> .localr'forall -
- exch pop
- 2 copy 0 get .stringmatch { .enumerateresource } { pop pop } ifelse
-} bind def
-/.globalresourceforall { % <key> <value> <args> .globalr'forall -
- exch pop
- 2 copy 0 get .stringmatch {
- dup 3 get begin .LocalInstances end 2 index known not {
- .enumerateresource
- } {
- pop pop
- } ifelse
- } {
- pop pop
- } ifelse
-} bind def
-/.externalresourceforall { % <filename> <len> <args> .externalr'forall -
- 3 1 roll 1 index length 1 index sub getinterval exch
- dup 3 get begin .Instances .LocalInstances end
- % Stack: key args insts localinsts
- 3 index known {
- pop pop pop
- } {
- 2 index known { pop pop } { .enumerateresource } ifelse
- } ifelse
-} bind def
-
-/DefineResource {
- .CheckResource
- { dup [ exch 0 -1 ]
- % Stack: key value instance
- currentglobal
- { false setglobal 2 index UndefineResource % remove local def if any
- true setglobal
- .Instances dup //.emptydict eq {
- pop 3 dict
- % As noted above, Category dictionaries are read-only,
- % so we have to use .forcedef here.
- /.Instances 1 index .forcedef % Category dict is read-only
- } if
- }
- { .LocalInstances dup //.emptydict eq
- { pop 3 dict localinstancedict Category 2 index put
- }
- if
- }
- ifelse
- % Stack: key value instance instancedict
- 3 index 2 index .growput
- % Now make the resource value read-only.
- 0 2 copy get { readonly } .internalstopped pop
- dup 4 1 roll put exch pop exch pop
- }
- { /defineresource cvx /typecheck signaloperror
- }
- ifelse
-} .bind executeonly % executeonly to prevent access to .forcedef
-/UndefineResource
- { { dup 2 index .knownget
- { dup 1 get 1 ge
- { dup 0 null put 1 2 put pop pop }
- { pop exch .undef }
- ifelse
- }
- { pop pop
- }
- ifelse
- }
- currentglobal
- { 2 copy .Instances exch exec
- }
- if .LocalInstances exch exec
- } bind
-% Because of some badly designed code in Adobe's CID font downloader that
-% makes findresource and resourcestatus deliberately inconsistent with each
-% other, the default FindResource must not call ResourceStatus if there is
-% an instance of the desired name already defined in VM.
-/FindResource {
- dup //null eq {
- % CET 13-06 wants /typecheck for "null findencoding" but
- % .knownget doesn't fail on null
- /findresource cvx /typecheck signaloperror
- } if
- dup .getvminstance {
- exch pop 0 get
- } {
- dup ResourceStatus {
- pop 1 gt {
- .DoLoadResource .getvminstance not {
- /findresource cvx .undefinedresource
- } if 0 get
- } {
- .GetInstance pop 0 get
- } ifelse
- } {
- /findresource cvx .undefinedresource
- } ifelse
- } ifelse
-} bind
-% Because of some badly designed code in Adobe's CID font downloader, the
-% definition of ResourceStatus for Generic and Font must be the same (!).
-% We patch around this by using an intermediate .ResourceFileStatus procedure.
-/ResourceStatus {
- dup .GetInstance {
- exch pop dup 1 get exch 2 get true
- } {
- .ResourceFileStatus
- } ifelse
-} bind
-/.ResourceFileStatus {
- .ResourceFile { closefile 2 -1 true } { pop false } ifelse
-} bind
-/ResourceForAll {
- % Construct a new procedure to hold the arguments.
- % All objects constructed here must be in local VM to avoid
- % a possible invalidaccess.
- currentdict 4 .localvmpackedarray % [template proc scratch resdict]
- % We must pop the resource dictionary off the dict stack
- % when doing the actual iteration, and restore it afterwards.
- .currentglobal not {
- .LocalInstances length 0 ne {
- % We must do local instances, and do them first.
- //.localresourceforall {exec} 0 get 3 .localvmpackedarray cvx
- .LocalInstances exch {forall} 0 get 1 index 0 get
- currentdict end 3 .execn begin
- } if
- } if
- % Do global instances next.
- //.globalresourceforall {exec} 0 get 3 .localvmpackedarray cvx
- .Instances exch cvx {forall} 0 get 1 index 0 get
- currentdict end 3 .execn begin
- mark % args [
- Category .namestring .file_name_separator concatstrings
- 2 index 0 get % args [ (c/) (t)
- dup length 3 1 roll % args [ l (c/) (t)
- concatstrings % args [ l (c/t)
- [
- true /LIBPATH .systemvar 3 index
- .generate_dir_list_templates_with_length % args (t) [ l [(pt) Lp ...]
- % also add on the Resources as specified by the GenericResourceDir
- true [ currentsystemparams /GenericResourceDir get]
- counttomark 1 add index .generate_dir_list_templates_with_length
- % Resource files on OpenVMS require a separate template (gs:[dir.*]*)
- true [ currentsystemparams /GenericResourceDir get]
- counttomark 1 add index .file_name_separator (*)
- concatstrings concatstrings .generate_dir_list_templates_with_length
- ] exch pop
- dup length 1 sub 0 exch 2 exch { % args [ l [] i
- 2 copy get % args [ l [] i (pt)
- exch 2 index exch 1 add get % args [ l [] (pt) Lp
- exch % args [ l [] Lp (pt)
-
- { % args [ l [] Lp (pf)
- dup length % args [ l [] Lp (pf) Lpf
- 2 index sub % args [ l [] Lp (pf) Lf
- 2 index exch % args [ l [] Lp (pf) Lp Lf
- getinterval cvn dup % args [ l [] Lp /n /n
- 5 2 roll % args [ /n /n l [] Lp
- } //.rfnstring filenameforall
- pop % args [ /n1 /n1 ... /nN /nN l []
- } for % args [ /n1 /n1 ... /nN /nN l []
- pop pop
- .dicttomark % An easy way to exclude duplicates. % args <</n/n>>
- % {
- { pop } 0 get
- 2 index 2 get { cvs 0 } aload pop 5 index
- //.externalresourceforall {exec} 0 get
- % }
- 7 .localvmpackedarray cvx
- 3 2 roll pop % args
- { forall } 0 get
- currentdict end 2 .execn begin
-} bind
-/.file_name_is_iodevice_or_absolute
-{ {
- dup length 0 gt {
- dup 0 get (%) 0 get eq {
- pop true exit
- } if
- } if
- .file_name_is_absolute exit
- } loop
-} bind def
-/ResourceFileName
- { % /in (scr)
- exch //.rfnstring cvs % (scr) (n)
- /GenericResourcePathSep getsystemparam exch % (scr) (/) (n)
- Category .namestring % (scr) (/) (n) (c)
- 3 1 roll % (scr) (c) (/) (n)
- concatstrings concatstrings % (scr) (c/n)
- /GenericResourceDir getsystemparam //.file_name_is_iodevice_or_absolute exec not {
- /GenericResourceDir getsystemparam exch concatstrings
- findlibfile
- { % (scr) (p/c/n) file
- pop exch copy true % (p/c/n) true
- } { % (scr) (c/n)
- false % (scr) (c/n) false
- } ifelse
- } { % (scr) (c/n)
- false % (scr) (c/n) false
- } ifelse
- not { % (scr) (c/n)
- /GenericResourceDir getsystemparam % (scr) (c/n) (d/)
- dup length exch % (scr) (c/n) Ld (d/)
- 3 index copy pop % (scr') (c/n) Ld
- 1 index length % (scr') (c/n) Ld Lcn
- 3 index 3 copy pop % (scr') (c/n) Ld Lcn (scr') Ld Lcn
- getinterval % (scr') (c/n) Ld Lcn (scr[Ld:Lcn])
- 4 3 roll exch % (scr') Ld Lcn (c/n) (scr[Ld:Lcn])
- copy pop % (scr'') Ld Lcn
- add 0 exch getinterval % (scr''[0:Ld+Lcn])
- } if
- } bind
-
- % Additional entries
-
-% Unfortunately, we can't create the real .Instances dictionary now,
-% because if someone copies the Generic category (which pp. 95-96 of the
-% 2nd Edition Red Book says is legitimate), they'll wind up sharing
-% the .Instances. Instead, we have to create .Instances on demand,
-% just like the entry in localinstancedict.
-% We also have to prevent anyone from creating instances of Generic itself.
-/.Instances //.emptydict
-
-/.LocalInstances
- { localinstancedict Category .knownget not { //.emptydict } if
- } bind
-/.GetInstance
- { currentglobal
- { .Instances exch .knownget }
- { .LocalInstances 1 index .knownget
- { exch pop true }
- { .Instances exch .knownget }
- ifelse
- }
- ifelse
- } bind
-/.CheckResource
- { true
- } bind
-/.vmused {
- % - .vmused <usedvalue>
- % usedvalue = vmstatus in global + vmstatus in local.
- 0 2 {
- .currentglobal not .setglobal
- vmstatus pop exch pop add
- } repeat
-} bind def
-/.DoLoadResource {
- % .LoadResource may push entries on the operand stack.
- % It is an undocumented feature of Adobe implementations,
- % which we must match for the sake of some badly written
- % font downloading code, that such entries are popped
- % automatically.
- count 1 index cvlit .vmused
- % Stack: key count litkey memused
- {.LoadResource} 4 1 roll 4 .execn
- % Stack: ... count key memused
- .vmused exch sub
- 1 index .getvminstance not {
- pop dup .undefinedresource % didn't load
- } if
- dup 1 1 put
- 2 3 -1 roll put
- % Stack: ... count key
- exch count 1 sub exch sub {exch pop} repeat
-} bind
-/.LoadResource
- { dup .ResourceFile
- { exch pop currentglobal
- { .runresource }
- { true setglobal { .runresource } stopped false setglobal { stop } if }
- ifelse
- }
- { dup .undefinedresource
- }
- ifelse
- } bind
-/.ResourceFile
- {
- Category //.rfnstring cvs length % key l
- dup //.rfnstring dup length 2 index sub % key l l (buf) L-l
- 3 2 roll exch getinterval % key l ()
- .file_name_directory_separator exch copy length add % key l1
- dup //.rfnstring dup length 2 index sub % key l1 l1 (buf) L-l
- 3 2 roll exch getinterval % key l1 ()
- 2 index exch cvs length add % key l2
- //.rfnstring exch 0 exch getinterval % key (relative_path)
- .libfile {
- exch pop true
- } {
- pop
- currentdict /ResourceFileName known {
- mark 1 index //.rfnstring { ResourceFileName } .internalstopped {
- cleartomark false
- } {
- (r) { file } .internalstopped {
- cleartomark false
- } {
- exch pop exch pop true
- } ifelse
- } ifelse
- } {
- pop false
- } ifelse
- } ifelse
- } bind
-
-
-
-.dicttomark
-/Category defineresource pop
-
-% Fill in the rest of the Category category.
-/Category /Category findresource dup
-/Generic /Category findresource begin {
- /FindResource /ResourceForAll /ResourceStatus /.ResourceFileStatus
- /UndefineResource /ResourceFileName
- /.ResourceFile /.LoadResource /.DoLoadResource
-} { dup load put dup } forall
-pop readonly pop end
-
-(END GENERIC) VMDEBUG
-
-% Define the fixed categories.
-
-mark
- % Non-Type categories with existing entries.
- /ColorSpaceFamily
- { } % These must be deferred, because optional features may add some.
- /Emulator
- mark EMULATORS { cvn } forall .packtomark
- /Filter
- { } % These must be deferred, because optional features may add some.
- /IODevice
- % Loop until the .getiodevice gets a rangecheck.
- errordict /rangecheck 2 copy get
- errordict /rangecheck { pop stop } put % pop the command
- mark 0 { {
- dup .getiodevice dup null eq { pop } { exch } ifelse 1 add
- } loop} .internalstopped
- pop pop pop .packtomark
- 4 1 roll put
- .clearerror
- % Type categories listed in the Red Book.
- /ColorRenderingType
- { } % These must be deferred, because optional features may add some.
- /FMapType
- { } % These must be deferred, because optional features may add some.
- /FontType
- { } % These must be deferred, because optional features may add some.
- /FormType
- { } % These must be deferred, because optional features may add some.
- /HalftoneType
- { } % These must be deferred, because optional features may add some.
- /ImageType
- { } % Deferred, optional features may add some.
- /PatternType
- { } % Deferred, optional features may add some.
- % Type categories added since the Red Book.
- /setsmoothness where {
- pop /ShadingType { } % Deferred, optional features may add some.
- } if
-counttomark 2 idiv
- { mark
-
- % Standard entries
-
- % We'd like to prohibit defineresource,
- % but because optional features may add entries, we can't.
- % We can at least require that the key and value match.
- /DefineResource
- { currentglobal not
- { /defineresource cvx /invalidaccess signaloperror }
- { 2 copy ne
- { /defineresource cvx /rangecheck signaloperror }
- { dup .Instances 4 -2 roll .growput }
- ifelse
- }
- ifelse
- } bind
- /UndefineResource
- { /undefineresource cvx /invalidaccess signaloperror } bind
- /FindResource
- { .Instances 1 index .knownget
- { exch pop }
- { /findresource cvx .undefinedresource }
- ifelse
- } bind
- /ResourceStatus
- { .Instances exch known { 0 0 true } { false } ifelse } bind
- /ResourceForAll
- /Generic .findcategory /ResourceForAll load end
-
- % Additional entries
-
- counttomark 2 add -1 roll
- dup length dict dup begin exch { dup def } forall end
- % We'd like to make the .Instances readonly here,
- % but because optional features may add entries, we can't.
- /.Instances exch
- /.LocalInstances % used by ResourceForAll
- 0 dict def
-
- .dicttomark /Category defineresource pop
- } repeat pop
-
-(END FIXED) VMDEBUG
-
-% Define the other built-in categories.
-
-/.definecategory % <name> -mark- <key1> ... <valuen> .definecategory -
- { counttomark 2 idiv 2 add % .Instances, Category
- /Generic /Category findresource dup maxlength 3 -1 roll add
- dict .copydict begin
- counttomark 2 idiv { def } repeat pop % pop the mark
- currentdict end /Category defineresource pop
- } bind def
-
-/ColorRendering mark /InstanceType /dicttype .definecategory
-% ColorSpace is defined below
-% Encoding is defined below
-% Font is defined below
-/Form mark /InstanceType /dicttype .definecategory
-/Halftone mark /InstanceType /dicttype .definecategory
-/Pattern mark /InstanceType /dicttype .definecategory
-/ProcSet mark /InstanceType /dicttype .definecategory
-% Added since the Red Book:
-/ControlLanguage mark /InstanceType /dicttype .definecategory
-/HWOptions mark /InstanceType /dicttype .definecategory
-/Localization mark /InstanceType /dicttype .definecategory
-/OutputDevice mark /InstanceType /dicttype .definecategory
-/PDL mark /InstanceType /dicttype .definecategory
-% CIDFont, CIDMap, and CMap are defined in gs_cidfn.ps
-% FontSet is defined in gs_cff.ps
-% IdiomSet is defined in gs_ll3.ps
-% InkParams and TrapParams are defined in gs_trap.ps
-
-(END MISC) VMDEBUG
-
-% Define the ColorSpace category.
-
-/.defaultcsnames mark
- /DefaultGray 0
- /DefaultRGB 1
- /DefaultCMYK 2
-.dicttomark readonly def
-
-% The "hooks" are no-ops here, redefined in LL3.
-/.definedefaultcs { % <index> <value> .definedefaultcs -
- pop pop
-} bind def
-/.undefinedefaultcs { % <index> .undefinedefaultcs -
- pop
-} bind def
-
-/ColorSpace mark
-
-/InstanceType /arraytype
-
-% We keep track of whether there are any local definitions for any of
-% the Default keys. This information must get saved and restored in
-% parallel with the local instance dictionary, so it must be stored in
-% local VM.
-userdict /.localcsdefaults false put
-
-/DefineResource {
- 2 copy /Generic /Category findresource /DefineResource get exec
- exch pop
- exch //.defaultcsnames exch .knownget {
- 1 index .definedefaultcs
- currentglobal not { .userdict /.localcsdefaults true put } if
- } if
-} bind
-
-/UndefineResource {
- dup /Generic /Category findresource /UndefineResource get exec
- //.defaultcsnames 1 index .knownget {
- % Stack: resname index
- currentglobal {
- .undefinedefaultcs pop
- } {
- % We removed the local definition, but there might be a global one.
- exch .GetInstance {
- 0 get .definedefaultcs
- } {
- .undefinedefaultcs
- } ifelse
- % Recompute .localcsdefaults by scanning. This is rarely needed.
- .userdict /.localcsdefaults false //.defaultcsnames {
- pop .LocalInstances exch known { pop true exit } if
- } forall put
- } ifelse
- } {
- pop
- } ifelse
-} bind
-
-.definecategory % ColorSpace
-
-% Define the Encoding category.
-
-/Encoding mark
-
-/InstanceType /arraytype
-
-% Handle already-registered encodings, including lazily loaded encodings
-% that aren't loaded yet.
-
-/.Instances mark
- EncodingDirectory
- { dup length 256 eq { [ exch readonly 0 -1 ] } { pop [null 2 -1] } ifelse
- } forall
-.dicttomark
-
-/.ResourceFileDict mark
- EncodingDirectory
- { dup length 256 eq { pop pop } { 0 get } ifelse
- } forall
-.dicttomark
-
-/ResourceFileName
- { .ResourceFileDict 2 index .knownget
- { exch copy exch pop }
- { /Generic /Category findresource /ResourceFileName get exec }
- ifelse
- } bind
-
-.definecategory % Encoding
-
-% Make placeholders in level2dict for the redefined Encoding operators,
-% so that they will be swapped properly when we switch language levels.
-
-/.findencoding /.findencoding load def
-/findencoding /findencoding load def
-/.defineencoding /.defineencoding load def
-
-(END ENCODING) VMDEBUG
-
-% Define the Font category.
-
-/.fontstatus { % <fontname> .fontstatus <fontname> <found>
- { % Create a loop context just so we can exit it early.
- % Check Fontmap.
- Fontmap 1 index .knownget {
- {
- dup type /nametype eq {
- .fontstatus { pop null exit } if
- } {
- dup type /stringtype eq {
- findlibfile { closefile pop null exit } if pop
- } {
- % Procedure, assume success.
- pop null exit
- } ifelse
- } ifelse
- } forall dup null eq { pop true exit } if
- } if
- % Convert names to strings; give up on other types.
- dup type /nametype eq { .namestring } if
- dup type /stringtype ne { false exit } if
- % Check the resource directory.
- dup .fonttempstring /FontResourceDir getsystemparam .genericrfn
- status {
- pop pop pop pop true exit
- } if
- % Check for a file on the search path with the same name
- % as the font.
- findlibfile { closefile true exit } if
- % Scan a FONTPATH directory and try again.
- .scannextfontdir not { false exit } if
- } loop
-} bind def
-
-/Font mark
-
-/InstanceType /dicttype
-
-/DefineResource
- { 2 copy //definefont exch pop
- /Generic /Category findresource /DefineResource get exec
- } bind
-/UndefineResource
- { dup //undefinefont
- /Generic /Category findresource /UndefineResource get exec
- } bind
-/FindResource {
- dup .getvminstance {
- exch pop 0 get
- } {
- dup ResourceStatus {
- pop 1 gt { .loadfontresource } { .GetInstance pop 0 get } ifelse
- } {
- .loadfontresource
- } ifelse
- } ifelse
-} bind
-/ResourceForAll {
- { .scannextfontdir not { exit } if } loop
- /Generic /Category findresource /ResourceForAll get exec
-} bind
-/.ResourceFileStatus {
- .fontstatus { pop 2 -1 true } { pop false } ifelse
-} bind
-
-/.loadfontresource {
- dup vmstatus pop exch pop exch
- % Hack: rebind .currentresourcefile so that all calls of
- % definefont will know these are built-in fonts.
- currentfile {pop //findfont exec} .execasresource % (findfont is a procedure)
- exch vmstatus pop exch pop exch sub
- % stack: name font vmused
- % findfont has the prerogative of not calling definefont
- % in certain obscure cases of font substitution.
- 2 index .getvminstance {
- dup 1 1 put
- 2 3 -1 roll put
- } {
- pop
- } ifelse exch pop
-} bind
-
-/.Instances FontDirectory length 2 mul dict
-
-.definecategory % Font
-
-% Redefine font "operators".
-/.definefontmap
- { /Font /Category findresource /.Instances get
- dup 3 index known
- { pop
- }
- { 2 index
- % Make sure we create the array in global VM.
- .currentglobal true .setglobal
- [null 2 -1] exch .setglobal
- .growput
- }
- ifelse
- //.definefontmap exec
- } bind def
-
-% Make sure the old definitions are still in systemdict so that
-% they will get bound properly.
-systemdict begin
- /.origdefinefont /definefont load def
- /.origundefinefont /undefinefont load def
- /.origfindfont /findfont load def
-end
-/definefont {
- { /Font defineresource } stopped {
- /definefont cvx $error /errorname get signalerror
- } if
-} bind odef
-/undefinefont {
- /Font undefineresource
-} bind odef
-% The Red Book requires that findfont be a procedure, not an operator,
-% but it still needs to restore the stacks reliably if it fails.
-/.findfontop {
- { /Font findresource } stopped {
- pop /findfont $error /errorname get signalerror
- } if
-} bind odef
-/findfont {
- .findfontop
-} bind def % Must be a procedure, not an operator
-
-% Remove initialization utilities.
-currentdict /.definecategory .undef
-currentdict /.emptydict .undef
-
-end % level2dict
-
-% Convert deferred resources after we finally switch to Level 2.
-
-/.fixresources {
- % Encoding resources
- EncodingDirectory
- { dup length 256 eq
- { /Encoding defineresource pop }
- { pop pop }
- ifelse
- } forall
- /.findencoding {
- { /Encoding findresource } stopped {
- pop /findencoding $error /errorname get signalerror
- } if
- } bind def
- /findencoding /.findencoding load def % must be a procedure
- /.defineencoding { /Encoding defineresource pop } bind def
- % ColorRendering resources and ProcSet
- systemdict /ColorRendering .knownget {
- /ColorRendering exch /ProcSet defineresource pop
- systemdict /ColorRendering undef
- /DefaultColorRendering currentcolorrendering /ColorRendering defineresource pop
- } if
- % ColorSpace resources
- systemdict /CIEsRGB .knownget {
- /sRGB exch /ColorSpace defineresource pop
- systemdict /CIEsRGB undef
- } if
- % ColorSpaceFamily resources
- colorspacedict { pop dup /ColorSpaceFamily defineresource pop } forall
- % Filter resources
- filterdict { pop dup /Filter defineresource pop } forall
- % FontType and FMapType resources
- buildfontdict { pop dup /FontType defineresource pop } forall
- mark
- buildfontdict 0 known { 2 3 4 5 6 7 8 } if
- buildfontdict 9 known { 9 } if
- counttomark { dup /FMapType defineresource pop } repeat pop
- % FormType resources
- .formtypes { pop dup /FormType defineresource pop } forall
- % HalftoneType resources
- .halftonetypes { pop dup /HalftoneType defineresource pop } forall
- % ColorRenderingType resources
- .colorrenderingtypes {pop dup /ColorRenderingType defineresource pop} forall
- % ImageType resources
- .imagetypes { pop dup /ImageType defineresource pop } forall
- % PatternType resources
- .patterntypes { pop dup /PatternType defineresource pop } forall
- % Make the fixed resource categories immutable.
- /.shadingtypes where {
- pop .shadingtypes { pop dup /ShadingType defineresource pop } forall
- } if
- [ /ColorSpaceFamily /Emulator /Filter /IODevice /ColorRenderingType
- /FMapType /FontType /FormType /HalftoneType /ImageType /PatternType
- /.shadingtypes where { pop /ShadingType } if
- ] {
- /Category findresource
- dup /.Instances get readonly pop
- .LocalInstances readonly pop
- readonly pop
- } forall
- % clean up
- systemdict /.fixresources undef
-} bind def
-
-%% Replace 1 (gs_resmp.ps)
-(gs_resmp.ps) dup runlibfile VMDEBUG
diff --git a/Master/tlpkg/tlgs/lib/gs_resmp.ps b/Master/tlpkg/tlgs/lib/gs_resmp.ps deleted file mode 100644 index 64bda1a4b81..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_resmp.ps +++ /dev/null @@ -1,531 +0,0 @@ -% Copyright (C) 2000 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_resmp.ps 8046 2007-06-12 20:55:18Z alexcher $
-% A procset to redefine a resource category with a resource map.
-
-% Public entries :
-
-% Redefine - a procedure for redefining a resource category with a map.
-% Methods for interpreting the resource map to be provided by client
-% in the argument dictionary.
-%
-% Note that the procedure Redefine is idempotential :
-% consequtive calls to it will not replace the category methods,
-% but will merge resource maps. If an interleaving redefinition
-% needs to cancel the idempotentity, it must remove the entry
-% /.IsRedefinedWithMap from the category dictionary.
-
-% MakeResourceEnumerator - this procedure is useful for
-% redefining any category. It provides a proper order of instances
-% and proper stacks during resourceforall.
-
-% BindWithCurrentdict - a procedure for generating temporary procedures
-% from templates, binding them with a local dictionary.
-
-% execstack_lookup - a procedure for communicating through the execution stack.
-% It allows for a callee to get an information from an indirect caller.
-
-% The procedures are designed for exeution witout putting
-% the procset instance onto the dictionary stack.
-
-languagelevel 2 .setlanguagelevel
-currentglobal true setglobal
-
-/MappedCategoryRedefiner 10 dict begin % The procset.
-
-currentpacking false setpacking
-
-/InstanceEnumeratorPattern % - InstanceEnumeratorPattern ...
-{
- % This is a pattern for enumeration procedure to be built dynamically,
- % applying BindWithCurrentdict with a temporary dictionary.
- % The following names will be replaced with specific objects
- % during BindWithCurrentdict :
- % en_local_dict - a dictionary for storing the local integer variable 'status'.
- % scr - the scratch string argument of resourceforall;
- % proc - the procedure argument of resourceforall;
- % InstancesStatus - a dictionary that maps resource instance names to their status value;
- % Category - the category to be enumerated.
-
- % When this procedure is called from ResourceForAll, the category is the current dictionary.
- % We remove it from the dictionary stack before performing the enumeration
- % to provide the <proc> to write to the underlying dictionary,
- % and put it back after the enumeration is completed.
- end
- {
- 0 1 2 {
- en_local_dict exch /status exch put
- InstancesStatus {
- en_local_dict /status get eq {
- scr cvs % ... (Font)
- proc exec %
- } {
- pop
- } ifelse % ...
- } forall
- } for % ...
- } stopped
- Category begin
- { stop } if
-} bind def
-
-% An auxiliary proc for BindWithCurrentdict :
-/.BindAux % <proc> BindAux <proc>
-{ 0 exec
-} bind def
-
-setpacking
-
-/BindWithCurrentdict % <proc> BindWithCurrentdict <proc>
-{
- % Make a copy of the given procedure, binding in the values of all names
- % defined in currentdict.
- % Caution1 : this code cannot handle procedures that were already
- % bound recursively.
- % Caution2 : this code don't bind packedarrays. This was done
- % intentionally for a termination of the procedure tree.
-
- dup length array copy
- dup length 1 sub -1 0 {
- 2 copy get % {precopy} i {elem}
- dup dup type /arraytype eq exch xcheck and {
- % {precopy} i {elem}
- //.BindAux exec % {precopy} i {elem_copy}
- 2 index 3 1 roll put % {precopy}
- } {
- dup dup type /nametype eq exch xcheck and {
- % {precopy} i {elem}
- currentdict exch .knownget {
- 2 index 3 1 roll put % {precopy}
- } {
- pop
- } ifelse
- } {
- pop pop
- } ifelse
- } ifelse % {precopy}
- } for % {copy}
- cvx
-} bind def
-
-//.BindAux 0 //BindWithCurrentdict put % bind the recursive call in 'Bind'.
-
-/MakeResourceEnumerator % <proc> <scr> <InstancesStatus> MakeResourceEnumerator <Enumerator>
-{
- % Build the enumeration procedure :
-
- % Since the resourceforall procedure may leave values on the operand stack,
- % we cannot simply store the enumerator's local data on the stack.
- % We also cannot use a static dictionary to store local variables,
- % because of possible recursion in the resourceforall procedure.
- % To work around this, we create a copy of the enumeration procedure and
- % bind it dynamically with a temporary dictionary, which contains
- % local variables for the currently executing instance of resourceforall.
-
- % Always place the enumerator in local VM,
- % because its elements may be in local VM.
-
- currentglobal 4 1 roll
- false setglobal
- currentdict % Category
- 6 dict begin % the temporary dictionary
- /Category exch def
- /InstancesStatus exch def
- /scr exch def
- /proc exch def
- /en_local_dict currentdict def
- //InstanceEnumeratorPattern //BindWithCurrentdict exec % Enumerator
- /status 0 def % variable for the current status to enumerate - do not bind with it !
- end
- exch setglobal
-} bind def
-
-/execstack_lookup % <object> execstack_lookup <object1>
- % <object> execstack_lookup null
-{ % Checks whether execution stack contains a procedure starting with <object>,
- % and retrives the 2nd element of the procedure,
- % or null if the procedure was not found.
- %
- % Since 'execstack' actually renders subarrays of procedures,
- % the pattern for recognition must be like this :
- %
- % { <object> <object1>
- % CallSomething
- % } loop
- %
- % The solution with 'loop' depends on how GS implements cycles,
- % so it must not appear in documents, which are required to be interpreter independent.
- % Any other type of cycles are also acceptable.
- % If no repitition is really needed, just insert 'exit' into its body.
- % If <object> <object1> are not needed for the caller, insert "pop pop" after them.
- % If <object1> is really unuseful, the pattern may be simplified :
- %
- % { <object> pop
- % CallSomething
- % exit
- % } loop
- %
- % It will retrieve 'pop' or 'null'.
- %
- % Note that 2 topmost execstack elements are the execstack_lookup procedure and its caller.
- % We don't check them.
-
- currentglobal false setglobal % <object> bGlobal
- countexecstack array execstack % <object> bGlobal [execstack]
- dup null exch % <object> bGlobal [execstack] null [execstack]
- length 3 sub -1 0 { % <object> bGlobal [execstack] null i
- 2 index exch get % <object> bGlobal [execstack] null proc
- dup type dup /packedarraytype eq exch /arraytype eq or {
- dup rcheck {
- dup length 1 gt { % <object> bGlobal [execstack] null proc
- dup 0 get % <object> bGlobal [execstack] null proc elem0
- 5 index eq { % <object> bGlobal [execstack] null proc
- 1 get % <object> bGlobal [execstack] null object1
- exch pop exit % <object> bGlobal [execstack] object1
- } {
- pop
- } ifelse
- } {
- pop % <object> bGlobal [execstack] false
- } ifelse
- } {
- pop % <object> bGlobal [execstack] false
- } ifelse
- } {
- pop % <object> bGlobal [execstack] false
- } ifelse
- } for % <object> bGlobal [execstack] bResult
- exch pop exch setglobal exch pop % bResult
-} bind def
-
-currentpacking false setpacking
-/MethodsToRedefine 5 dict begin
-
- % Procedures in this dictionary really are patterns for new category methods.
- % The following names will be replaced with specific objects during BindWithCurrentdict :
- % .map - the map dictionary;
- % DefineResource, ResourceStatus, ResourceFileName, FindResource, ResourceForAll
- % - procedures from the original resource category.
-
- /FindResource % <Name> FindResource <dict>
- { RESMPDEBUG { (resmp FindResource beg ) print dup = } if
- dup ResourceStatus exec {
- pop 2 lt
- } {
- false
- } ifelse % bInVirtualMemory
- { FindResource exec
- } {
- dup dup .map exch .knownget { % /Name /Name <<record>>
- dup dup /RecordVirtualMethods get /IsActive get exec {
- 1 index .getvminstance { % /Name /Name <<record>> holder
- 1 get 1 eq
- } {
- true
- } ifelse % /Name /Name <<record>> bStatusIs1
- 4 1 roll % bStatusIs1 /Name /Name <<record>>
- dup /RecordVirtualMethods get /MakeInstance get exec
- % bStatusIs1 /Name /Name Instance size
- 5 1 roll % size bStatusIs1 /Name /Name Instance
- DefineResource exec % size bStatusIs1 /Name Instance
- % Make ResourceStatus to return correct values for this instance :
- % Hack: we replace status values in the instance holder :
- exch .getvminstance pop % size bStatusIs1 Instance holder
- dup 5 -1 roll 2 exch put % bStatusIs1 Instance holder
- 3 2 roll { % Instance holder
- 1 1 put % Instance
- } {
- pop
- } ifelse % Instance
- } { % /Name /Name <<record>>
- pop pop FindResource exec
- } ifelse
- } { % /Name /Name
- pop FindResource exec
- } ifelse
- } ifelse
- RESMPDEBUG { (resmp FindResource end) = } if
- } bind def
-
- /ResourceStatus % <Name> ResourceStatus <status> <size> true
- % <Name> ResourceStatus false
- { RESMPDEBUG { (resmp ResourceStatus beg ) print dup == } if
- dup ResourceStatus exec { % /Name status size
- 1 index 2 lt {
- % In VM - return with it.
- 3 2 roll pop true
- } {
- % Not in VM.
- exch pop exch % size /Name
- dup .map exch .knownget { % size /Name <<record>>
- dup dup /RecordVirtualMethods get /IsActive get exec {
- 3 2 roll pop % /Name <<record>>
- dup /RecordVirtualMethods get /GetSize get exec 2 exch true
- } { % size /Name <<record>>
- pop pop 2 exch true
- } ifelse
- } { % size /Name
- pop 2 exch true
- } ifelse
- } ifelse
- } { % /Name
- dup .map exch .knownget { % /Name <<record>>
- dup dup /RecordVirtualMethods get /IsActive get exec {
- dup /RecordVirtualMethods get /GetSize get exec 2 exch true
- } { % /Name <<record>>
- pop pop false
- } ifelse
- } { % /Name
- pop false
- } ifelse
- } ifelse
- RESMPDEBUG { (resmp ResourceStatus end) = } if
- } bind def
-
- /ResourceFileName % <Name> <scratch> ResourceFileName <string>
- { RESMPDEBUG { (resmp ResourceFileName beg ) print 1 index = } if
- exch % (scratch) /Name
- .map 1 index .knownget { % (scratch) /Name <<record>>
- RESMPDEBUG { (resmp ResourceFileName : have a map record.) = } if
- dup dup /RecordVirtualMethods get /IsActive get exec {
- RESMPDEBUG { (resmp ResourceFileName : record is active.) = } if
- dup /RecordVirtualMethods get /GetFilePath get exec % (string)
- RESMPDEBUG { (resmp ResourceFileName : retrieving ) print dup = } if
- } { % (scratch) /Name <<record>>
- RESMPDEBUG { (resmp ResourceFileName : record is NOT active.) = } if
- pop exch ResourceFileName exec
- RESMPDEBUG { (resmp ResourceFileName : retrieving ) print dup = } if
- } ifelse
- } {
- RESMPDEBUG { (resmp ResourceFileName : have NO map record.) = } if
- exch ResourceFileName exec
- RESMPDEBUG { (resmp ResourceFileName : retrieving ) print dup = } if
- } ifelse
- RESMPDEBUG { (resmp ResourceFileName end) = } if
- } bind def
-
- /ResourceForAll % <template> <proc> <scratch> ResourceForAll -
- { RESMPDEBUG { (resmp ResourceForAll beg ) print CategoryName =string cvs print ( ) print 2 index = } if
- % Create InstancesStatus dictionary :
- 20 dict % IS - Instances Status
- 4 1 roll % <<IS>> (templ) {proc} (sctarch)
- % Check if we are under another ResourceForAll :
- /.DisableResourceOrdering //execstack_lookup exec null eq 4 1 roll
- % <<IS>> bOrder (templ) {proc} (sctarch)
-
- % Put underlying resources to the InstancesStatus dictionary :
- currentdict % the category
- begin % ResourceForAll removes it locally.
- 2 index
- { cvn % <<IS>> bOrder (templ) {proc} (sctarch) /Name
- 4 index {
- dup ResourceStatus exec {pop 6 index 3 1 roll put} {pop} ifelse
- } {
- 5 index exch 2 put % Don't need the ordering, put '2' as a scratch.
- } ifelse
- }
- 2 index ResourceForAll exec % <<IS>> bOrder (templ) {proc} (sctarch)
- 4 3 roll pop % <<IS>> (templ) {proc} (sctarch)
- end
-
- % Put .map entries to the InstancesStatus dictionary :
- 4 -1 roll begin % (templ) {proc} (sctarch)
- .map { % (templ) {proc} (sctarch) /Name record
- dup dup /RecordVirtualMethods get /IsActive get exec {
- pop % (templ) {proc} (sctarch) /Name
- dup currentdict exch known {
- pop
- } {
- dup 2 index cvs % (templ) {proc} (sctarch) /Name (Name)
- 4 index .stringmatch { % (templ) {proc} (sctarch) /Name
- 2 def % It is not in VM.
- } {
- pop
- } ifelse
- } ifelse
- } { % (templ) {proc} (sctarch) /Name record
- pop pop
- } ifelse
- } forall % (templ) {proc} (sctarch)
-
- % prepare stacks for the enumeration :
- 3 2 roll pop % {proc} (sctarch)
- currentdict end % {proc} (scratch) <<IS>>
-
- % Make the enumerator and apply it :
- //MakeResourceEnumerator exec exec
- RESMPDEBUG { (resmp ResourceForAll end)= } if
- } bind def
-
- /GetCIDSystemInfoFromMap % <Name> GetCIDSystemInfoFromMap <Name>
- % <Name> GetCIDSystemInfoFromMap <dict>
- { RESMPDEBUG { (resmp GetCIDSystemInfoFromMap beg ) print dup = } if
- % This is a special function for communicating with GetCIDSystemInfo in gs_cidcm.ps .
- dup .map exch .knownget {
- RESMPDEBUG { (resmp GetCIDSystemInfoFromMap : have a map record.) = } if
- dup /RecordVirtualMethods get /GetCSI get exec
- dup null ne {
- RESMPDEBUG { (resmp GetCIDSystemInfoFromMap : retrieving a dict.) = } if
- exch
- } if
- pop
- } if
- RESMPDEBUG { (resmp GetCIDSystemInfoFromMap end) = } if
- } bind def
-
-currentdict end def
-setpacking
-
-/Redefine % <OptionsDict> Redefine -
-{ % Before calling this proc, the OptionsDict must specify options for
- % the catregory to be redefined :
- % CategoryName - a name of category to redefine;
- % MapFileName - a string for the resource map file name;
- % VerifyMap - a procedure :
- % <raw_map> VerifyMap -
- % - checks the map for consistency
- % PreprocessRecord - a procedure :
- % <map> <Name> <raw_record> PreprocessRecord <map> <Name> <record> true
- % <map> <Name> <raw_record> PreprocessRecord <map> <Name> <raw_record> false
- % - converts a map record into a dictionary;
- % It must add RecordVirtualMethods dictionary to the record :
- % MakeInstance - a procedure :
- % <Name> <record> MakeInstance <Name> <Instance> <size>
- % - converts the record to resource instance;
- % GetFilePath - a procedure for ResourceFileName :
- % <scratch> <Name> <record> GetFilePath <filepath>
- % GetSize - a procedure for ResourceStatus :
- % <Name> <record> GetSize <size>
- % GetCSI - a procedure for obtaining CIDSystemInfo dictionary from the record :
- % <record> GetCSI <CSI>
- % <record> GetCSI null
- % IsActive - a procedure for skipping records depending on the current device :
- % <record> IsActive <bool>
- % Also it is allowed to contain additional entries for client's needs.
- % The OptionsDict is also used for storing some local variables.
-
- % If a category is being redefined several times with this function,
- % each redefinition must either use an unique map file,
- % or the map file should be scanned by the last redefinition
- % (and must be defined in the last one with /MapFileName).
- % This happens so because we must accumulate all variants of
- % methods before scanning the map. We would like to delay
- % the scanning until all redefinitions are done, but it requires
- % to implement a queue of "refinish" methods and execute it
- % at very end of the prelude.
-
- begin % OptionsDict
- CategoryName /Category findresource /OldCategory exch def
- OldCategory /.IsRedefinedWithMap known {
- % Already redefined with map - don't redefine, but enhance the map.
- OldCategory /NewCategory exch def
- } {
- % Redefine with a new category instance.
- OldCategory dup length dict
- dup /.PreprocessRecord 4 dict put
- copy /NewCategory exch def
- } ifelse
-
- % Provide the 'or' logic for PreprocessRecord,
- % to allow different record types to be mixed in a single map file.
- % We do this with building a dictionary of PreprocessRecord procedures,
- % which come from different calls to Redefine :
- NewCategory /.PreprocessRecord get dup length % <<pr>> l
- currentdict /PreprocessRecord get .growput
-
- currentdict /MapFileName known {
- MapFileName .libfile {
- 1 dict begin
- /; {} def
- mark exch cvx exec .dicttomark % <<map>>
- end
- dup VerifyMap % <<map>>
- } {
- QUIET not {
- currentdict /IsMapFileOptional .knownget not { false } if not {
- (Warning: the map file ) print dup =string cvs print ( was not found.) =
- } if
- } if
- pop 0 dict % <<map>>
- } ifelse
- } {
- currentdict /.map .knownget not {
- 0 dict % <<map>>
- } if
- } ifelse
-
- % Preprocess entries :
- dup NewCategory /.PreprocessRecord get % <<map>> <<map>> <<pr>>
- 3 1 roll { % <<pr>> <<map>> /Name raw_record
- false 3 1 roll % <<pr>> <<map>> false /Name raw_record
- 4 index { % <<pr>> <<map>> false /Name raw_record i {pr}
- exch pop % <<pr>> <<map>> false /Name raw_record {pr}
- exec { % <<pr>> <<map>> false /Name record
- 3 -1 roll pop true 3 1 roll % <<pr>> <<map>> true /Name record
- exit
- } if % <<pr>> <<map>> false /Name raw_record
- } forall
- 3 2 roll { % <<pr>> <<map>> /Name record
- 2 index 3 1 roll put % <<pr>> <<map>>
- } {
- exch % <<pr>> <<map>> raw_record /Name
- (Incorrect record ) print =string cvs print ( of the map file ) print MapFileName =string cvs print (.) =
- end % Pops OptionsDict from dstack.
- pop pop pop %
- /Redefine cvx /undefinedresource signalerror
- } ifelse
- } forall % <<pr>> <<map>>
- exch pop % <<map>>
-
-
- % Add the map :
- OldCategory /.IsRedefinedWithMap known { % <<map>>
- % Just add to the old map :
- OldCategory /.map get copy pop %
- } { % <<map>>
- % Store the map to both the category and OptionsDict :
- dup NewCategory exch /.map exch put
- /.map exch def %
- } ifelse
- OldCategory /.IsRedefinedWithMap known not {
- % Copy old methods to OptionsDict :
- [ /DefineResource /ResourceStatus /ResourceFileName
- /FindResource /ResourceForAll
- ] {
- dup OldCategory exch get def
- } forall
-
- % Build new methods :
- //MethodsToRedefine {
- //BindWithCurrentdict exec NewCategory 3 1 roll put
- } forall
- CategoryName /CIDFont ne {
- NewCategory /GetCIDSystemInfoFromMap undef
- % This is some ugly, sorry.
- } if
- % Redefine the category :
- NewCategory /.IsRedefinedWithMap true put
- CategoryName NewCategory /Category defineresource pop
- } if
- end % OptionsDict
-} bind executeonly def
-
-currentdict /PutPreprocessRecord .undef
-
-currentdict end
-/ProcSet defineresource pop
-
-setglobal .setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_resst.ps b/Master/tlpkg/tlgs/lib/gs_resst.ps deleted file mode 100644 index 586b97a22b4..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_resst.ps +++ /dev/null @@ -1,156 +0,0 @@ -% Copyright (C) 2000 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_resst.ps 8022 2007-06-05 22:23:38Z giles $
-% Redefine generic category with static resource table.
-
-languagelevel 2 .setlanguagelevel
-
-15 dict begin % a temporary dictionary for local binding.
-
-/sep (/) def % The %static% device uses platform independent paths.
-
-/tempstring 8192 string def
-
-/IsMyRecord % <raw_record> IsMyRecord <raw_record> bool
-{ dup type /dicttype eq { dup /StaticFilePos known } { false } ifelse
-} bind def
-
-/append_string % <scratch> <index> <string> append_string <scratch> <index>
-{
- dup length 3 index 3 index 2 index getinterval % (scratch) index (string) l (scr_substr)
- 3 2 roll exch copy pop add % (scratch) index'
-} bind def
-
-/StaticResourceRecordVirtualMethods 4 dict begin
-
- /GetFilePath % <scratch> <Name> <record> GetFilePath <filepath>
- { pop exch % /Name (scratch)
- (%static%) dup length exch 2 index copy pop % /Name (scratch) l
- //sep //append_string exec % /Name (scratch) l
- Category //tempstring cvs //append_string exec % /Name (scratch) l
- //sep //append_string exec % /Name (scratch) l
- 3 2 roll //tempstring cvs % (scratch) l (Name)
- //append_string exec % (scratch) l
- 0 exch getinterval % (path)
- } bind def
-
- /MakeInstance % <Name> <record> MakeInstance <Name> <Instance> <size>
- {
- begin
- STRESDEBUG { (Loading a static resource ) print dup = } if
- 8192 string 2 index 2 index //GetFilePath exec
- (r) file run
- STRESDEBUG { (Completed loading the static resource ) print dup = } if
- StaticFileEnd StaticFilePos sub
- end
- 1 index Category findresource
- exch
- } bind def
-
- /GetSize % <Name> <record> GetSize <size>
- {
- % WARNING : this retrives file sise rather than VM size
- begin
- pop
- StaticFileEnd StaticFilePos sub
- end
- } bind def
-
- /IsActive % <record> IsActive <bool>
- { pop true
- } bind def
-
-currentdict end def
-
-mark
-/MappedCategoryRedefiner /ProcSet findresource begin
-
-/.StaticResourcesBeg % <end_string> <no_of_resources> <category_name> .StaticResourcesBeg <category_name>
-% Puts .map dictionary to dstack.
-{
- STRESDEBUG { (Starting static resources for category ) print dup = } if
- dup /Category resourcestatus {
- pop pop exch dict begin exch pop
- } {
- STRESDEBUG { (Skipping the resources because the category isn't defined.) = } if
- pop pop .skipeof
- } ifelse
-} bind
-
-/.StaticResourcesEnd % <category_name> .StaticResourcesEnd -
-% Removes .map dictionary from dstack.
-{
- STRESDEBUG { (Completting static resources for category ) print dup = } if
- currentdict end dup % /CatName <map> <map>
- systemdict /.io_static_root .knownget not {
- 10 dict % /CatName <map> <map> <dir>
- % Save it for garbager and for debug purpose :
- dup systemdict exch /.io_static_root exch put % /CatName <map> <map> <dir>
- dup .setup_io_static % /CatName <map> <map> <dir>
- } if % /CatName <map> <map> <dir>
- exch 3 index exch put % /CatName <map>
- 14 dict begin
- /.map exch def % /CatName
- /CategoryName exch def %
- /IsMapFileOptional true def
- /VerifyMap { pop } bind def
- /PreprocessRecord % <map> <Name> <raw_record> PreprocessRecord <map> <Name> <record> <bool>
- { //IsMyRecord exec dup {
- pop dup /RecordVirtualMethods //StaticResourceRecordVirtualMethods put
- true
- } if
- } bind def
- currentdict end
- //Redefine exec
-} bind
-
-end % MappedCategoryRedefiner
-end % the temporary dictionary for local binding.
-
-/.BeginResource % <instance_name> BeginResource <instance_name>
-% Puts a record dictionary to dstack.
-{
- STRESDEBUG { (Static resource ) print dup =string cvs print } if
- currentfile fileposition
- currentfile =string readline pop dup length 0 exch 10 .min getinterval (%% Replace) ne {
- % We are in COMPILE_INITS=1 .
- 4 dict begin
- /StaticFilePos exch def
- } {
- % We are in COMPILE_INITS=0 .
- pop
- } ifelse
- (%END_RESOURCE) .skipeof
-} bind
-
-/.EndResource % <instance_name> EndResource -
-% Removes a record dictionary from dstack.
-{
- currentdict /StaticFilePos known {
- /StaticFileEnd currentfile fileposition
- (.EndResource) length sub
- def
- STRESDEBUG { ( from position ) print StaticFilePos =string cvs print ( to position ) print StaticFileEnd = } if
- currentdict end def
- } {
- pop
- STRESDEBUG { ( ignored with COMPILE_INITS=0. ) = } if
- } ifelse
-} bind
-
-.dicttomark /StaticCategoryRedefiner exch /ProcSet defineresource pop
-
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_s.xbm b/Master/tlpkg/tlgs/lib/gs_s.xbm deleted file mode 100644 index 4d5234f63e1..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_s.xbm +++ /dev/null @@ -1,11 +0,0 @@ -#define gs_s.xbm_width 24
-#define gs_s.xbm_height 24
-#define gs_s.xbm_x_hot 0
-#define gs_s.xbm_y_hot 0
-static unsigned char gs.s.bm_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x08, 0x00, 0x00, 0x13,
- 0x00, 0x00, 0x33, 0x00, 0xfe, 0x31, 0xe0, 0xff, 0x38, 0xf0, 0x3f, 0x38,
- 0xf8, 0x07, 0x7e, 0xfc, 0x01, 0x7f, 0xfe, 0x90, 0x7f, 0x7e, 0x94, 0x7f,
- 0x7e, 0x84, 0x7f, 0x7e, 0x00, 0x7f, 0x7e, 0x00, 0x7e, 0xfc, 0x60, 0x7c,
- 0xfc, 0x61, 0x38, 0xf8, 0x03, 0x38, 0xf8, 0x03, 0x18, 0xf0, 0x07, 0x0c,
- 0xc0, 0x0f, 0x06, 0xc0, 0x07, 0x03, 0xf0, 0x01, 0x00, 0x00, 0x00, 0x00};
diff --git a/Master/tlpkg/tlgs/lib/gs_s.xpm b/Master/tlpkg/tlgs/lib/gs_s.xpm deleted file mode 100644 index 765d9d79dd5..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_s.xpm +++ /dev/null @@ -1,36 +0,0 @@ -/* XPM */
-static char * gs_s_xpm[] = {
-/* width height ncolors cpp [x_hot y_hot] */
-"24 24 6 1 0 0",
-/* colors */
-" s none m none c none",
-". c #808080808080",
-"X s iconColor1 m black c black",
-"o c #C0C0C0C0C0C0",
-"O s iconColor2 m white c white",
-"+ c #00000000FFFF",
-/* pixels */
-" ",
-" .. ",
-" XoOo. ",
-" X.OoX ",
-" X.OoX. ",
-" .XXXXXX.oOoXX ",
-" ..XXXXXXXX.oOO.XX ",
-" XXXXXXXX..oOOOo.XX ",
-" XXXXXXX.OOOOOo.XXXX. ",
-" XXXXXX.OOOOOOOXXXXXXX ",
-" .XXXXX.OOOO+OOXXXXXXXX ",
-" XXXXXXOOO+O+OOXXXXXXXX ",
-" XXXXXXOOO+OOOOXXXXXXXX ",
-" XXXXXXOOOOOOOOOXXXXXXX ",
-" .XXXXXOOOOOOOOOO.XXXXX ",
-" XXXXXXOOOOO++OOO.XXXX ",
-" .XXXXX.OOOO++OOOoXXX ",
-" XXXXXX.OOOOOOOOOXXX ",
-" .XXXXXXoOOOOOOOoXX ",
-" .XXXXXXoOOOOOo.X ",
-" .XXXXXOOOOO.X ",
-" .XXXXOOOOO.. ",
-" XXXXXOOOOOOOO ",
-" "};
diff --git a/Master/tlpkg/tlgs/lib/gs_s_m.xbm b/Master/tlpkg/tlgs/lib/gs_s_m.xbm deleted file mode 100644 index 941e9c48475..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_s_m.xbm +++ /dev/null @@ -1,11 +0,0 @@ -#define gs_s_m.xbm_width 24
-#define gs_s_m.xbm_height 24
-#define gs_s_m.xbm_x_hot 0
-#define gs_s_m.xbm_y_hot 0
-static unsigned char gs.s_m.bm_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x0f, 0x00, 0x00, 0x1f,
- 0x00, 0x00, 0x3f, 0x00, 0xfe, 0x3f, 0xe0, 0xff, 0x3f, 0xf0, 0xff, 0x3f,
- 0xf8, 0xff, 0x7f, 0xfc, 0xff, 0x7f, 0xfe, 0xff, 0x7f, 0xfe, 0xff, 0x7f,
- 0xfe, 0xff, 0x7f, 0xfe, 0xff, 0x7f, 0xfe, 0xff, 0x7f, 0xfc, 0xff, 0x7f,
- 0xfc, 0xff, 0x3f, 0xf8, 0xff, 0x3f, 0xf8, 0xff, 0x1f, 0xf0, 0xff, 0x0f,
- 0xc0, 0xff, 0x07, 0xc0, 0xff, 0x03, 0xf0, 0xff, 0x01, 0x00, 0x00, 0x00};
diff --git a/Master/tlpkg/tlgs/lib/gs_sepr.ps b/Master/tlpkg/tlgs/lib/gs_sepr.ps deleted file mode 100644 index 07b070b9675..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_sepr.ps +++ /dev/null @@ -1,268 +0,0 @@ -% Copyright (C) 2001, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_sepr.ps 7201 2006-11-15 16:12:42Z ray $
-% Separation color space method dictionary
-
-
-% verify that Separation color spaces are supported
-/.setseparationspace where
- { pop }
- { currentfile closefile }
-ifelse
-
-.currentglobal true .setglobal
-.cspace_util begin
-
-
-%
-% <c1> <array> apply_sepr_tint_xform <c1>' ... <cn>' <array>
-%
-% Apply the tint transform for a Separation color space color intensity
-% value.
-%
-/apply_sepr_tint_xform
- {
- exch //bound_0_1 exec
- mark exch 2 index 3 get exec
- counttomark { cvr counttomark -1 roll } repeat % for CET, make all tints real.
- counttomark 2 add -2 roll pop
- }
-bind def
-
-
-%
-% <cspace_array> build_tintxform_function <cspace_array> <proc>
-%
-% Convert a tint transformation into a function, if possible. If this is
-% successful, <proc> will be a function procedure (a two-element,
-% execute-only, executable array whose first element is the function
-% data structure and whose second element is the operator %execfunction.
-% If it is not successful, <proc> will be the same as the tint transform
-% in <cspace_array>.
-%
-% Note that, for PDF files, the tint transform will likely already be a
-% function-array. In this case, <proc> will be this array, and thus will
-% also be identical to the original tint transform.
-%
-% This procedure is used for both Separation and DeviceN color spaces.
-%
-/build_tintxform_function
- {
- dup 3 get dup .isencapfunction not
- {
- % Try a FunctionType 4 function first; build the function dictionary
- % in local VM.
- .currentglobal exch //false .setglobal
- % Make the dictionary a couple of elements large in case this fails
- % and we need the dictionary to build a sampled function.
- 6 dict begin
- /FunctionType 4 def
- /Function exch def
- /Domain 2 index //.cs_get_range exec def
- /Range 2 index 2 get //.cs_get_range exec def
- currentdict end
- { .buildfunction }
- .internalstopped % If .buildfunction fails then not type 4 func.
- { % If not then try building a sampled (type 0) func.
- % We are using the dictionary which was created before .buildfunction
- dup /Order 3 put
- dup /BitsPerSample 16 put
- { .buildsampledfunction }
- .internalstopped % If .buildsamplefunction fails then invalid func.
- { % Failed - Create a dummy tint transform function
- % We are using the dictionary which was created before .buildfunction
- dup /Function {} put % Replace invalid tint transform with dummy
- .buildfunction
- }
- if % Check status from .buildsamplefunction/.internalstopped
- }
- if % check status from .buildfunction/.intermalstopped
- % restore the VM mode
- exch .setglobal
- }
- if
- }
-bind def
-
-%
-% <array1> <array2> converttinttransform <array1> <array2'>
-%
-% Convert a Separation/DeviceN color space to use a function as a tint
-% transformation, if this is possible. Possible outcomes are:
-%
-% 1. The tint transform already is a function, or is a procedure that
-% cannot be converted to a function. In either case, <array2> is
-% left unchanged (<array2> == <array2'>).
-%
-% 2. The tint transform is not already a function but can be converted
-% to a function, and <array1> != <array2>. In this case, <array2>
-% is modified directly.
-%
-% 3. The tint transform is not already a function but can be converted
-% to a function, and <array1> == <array2>. In this case, <array2>
-% is copied, and the copy is modified (i.e., after the operation
-% <array1> != <array2>
-%
-% This slightly complex approach avoids creating an extra color space
-% array unnecessarily.
-%
-/converttinttransform
- {
- % convert the tint transform to a fucntion
- //build_tintxform_function exec
-
- % see if anything needs to be modified
- 1 index 3 get 2 copy eq
- { pop pop }
- {
- pop
-
- % see if the color space must be copied
- 3 copy pop eq
- {
- % copy the array into local VM
- .currentglobal //false .setglobal
- 3 -1 roll dup length array copy 3 1 roll
- .setglobal
- }
- if
- 1 index exch 3 exch put
- }
- ifelse
- }
-bind def
-
-
-colorspacedict
-/Separation
- mark
- /cs_potential_indexed_base true
- /cs_potential_pattern_base true
- /cs_potential_alternate false
- /cs_potential_icc_alternate false
- /cs_get_ncomps //ncomps_1
- /cs_get_range //get_range_1
- /cs_get_default_color { pop 1 } bind
-
- /cs_get_currentgray
- { //apply_sepr_tint_xform exec 2 get //.cs_get_currentgray exec }
- bind
- /cs_get_currentrgb
- { //apply_sepr_tint_xform exec 2 get //.cs_get_currentrgb exec }
- bind
- /cs_get_currentcmyk
- { //apply_sepr_tint_xform exec 2 get //.cs_get_currentcmyk exec }
- bind
-
- % a lot of validation is done by the cs_validate method
- /cs_validate
- {
- //check_array exec
- dup 1 get type dup /nametype ne exch /stringtype ne and
- //setcspace_typecheck
- if
- dup 2 get //.cs_validate exec //.cs_potential_alternate exec not
- //setcspace_rangecheck
- if
- dup 3 get //check_array exec xcheck not
- //setcspace_typecheck
- if
- }
- bind
-
- % substitute the base space if appropriate
- /cs_substitute
- {
- dup 2 get //.cs_substitute exec 2 copy eq
- { pop pop dup }
- {
- % retain only the new alternate space
- exch pop
-
- % build all new structures in local VM
- .currentglobal 3 1 roll //false .setglobal
-
- % construct a new array and insert the new base color space
- 1 index dup length array copy dup 2 4 -1 roll put
-
- % restore VM mode
- 3 -1 roll .setglobal
- }
- ifelse
- }
- bind
-
- %
- % The Ghostscript interpreter works better when tinttransform procedures
- % are translated into functions. Attempt to do that here.
- %
- /cs_prepare //converttinttransform
-
- %
- % Install the current color space.
- %
- % The current Ghostscript color space implementation requires that
- % color spaces that provide a base or alternative color space set
- % that base/alternative color space to be the current color space
- % before attempting to set the original color space.
- %
- /cs_install
- {
- % save the current color space
- currentcolorspace
-
- % set the base color space as the current color space
- 1 index 2 get //forcesetcolorspace
-
- % set the indexed color space; restore the earlier space on error
- mark 2 index
- { .setseparationspace }
- stopped
- { cleartomark setcolorspace stop }
- { pop pop pop }
- ifelse
- }
- bind
-
- /cs_prepare_color //validate_1
-
- %
- % If a Separation color space is not supported in native mode by
- % the current process color model, Adobe implementations will always
- % execute the tint transform procedure when setcolor is invoked.
- % Ghostscript may have turned this transform into a sampled function,
- % and even if this is not the case, will have sampled the transform
- % when the color space is first set. Some applications may depend
- % on the Adobe behavior, so we implement it via the
- % cs_complete_setcolor method.
- %
- /cs_complete_setcolor
- {
- .usealternate
- {
- currentcolor exch 3 get exec
- currentcolorspace 2 get //clear_setcolor_operands exec
- }
- { pop }
- ifelse
- }
- bind
-
- .dicttomark
-put
-
-end % .cspace_util
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/gs_setpd.ps b/Master/tlpkg/tlgs/lib/gs_setpd.ps deleted file mode 100644 index 489275d852e..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_setpd.ps +++ /dev/null @@ -1,924 +0,0 @@ -% Copyright (C) 1994, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_setpd.ps 8026 2007-06-06 22:03:27Z till $
-% The current implementation of setpagedevice has the following limitations:
-% - It doesn't attempt to "interact with the user" for Policy = 2.
-
-languagelevel 1 .setlanguagelevel
-level2dict begin
-
-% ---------------- Redefinitions ---------------- %
-
-% Redefine .beginpage and .endpage so that they call BeginPage and
-% EndPage respectively if appropriate.
-
-% We have to guard against the BeginPage procedure not popping its operand.
-% This is really stupid, but the Genoa CET does it.
-/.beginpage { % - .beginpage -
- .currentshowpagecount {
- .currentpagedevice pop
- dup //null ne { /BeginPage .knownget } { pop //false } ifelse {
- % Stack: ... pagecount proc
- count 2 .execn
- % Stack: ... ..???.. oldcount
- count 1 add exch sub { pop } repeat
- } {
- pop
- } ifelse
- } if
-} bind odef
-
-% Guard similarly against EndPage not popping its operand.
-/.endpage { % <reason> .endpage <print_bool>
- .currentshowpagecount {
- 1 index .currentpagedevice pop
- dup //null ne { /EndPage .knownget } { pop //false } ifelse {
- % Stack: ... reason pagecount reason proc
- count 2 .execn
- % Stack: ... ..???.. print oldcount
- count 2 add exch sub { exch pop } repeat
- } {
- pop pop 2 ne
- } ifelse
- } {
- 2 ne
- } ifelse
-} bind odef
-
-% Define interpreter callouts for handling gstate-saving operators,
-% to make sure that they create a page device dictionary for use by
-% the corresponding gstate-restoring operator.
-% We'd really like to avoid the cost of doing this, but we don't see how.
-% The names %gsavepagedevice, %savepagedevice, %gstatepagedevice,
-% %copygstatepagedevice, and %currentgstatepagedevice are known to the
-% interpreter.
-
-(%gsavepagedevice) cvn
- { currentpagedevice pop gsave
- } bind def
-
-(%savepagedevice) cvn
- { currentpagedevice pop save
- } bind def
-
-(%gstatepagedevice) cvn
- { currentpagedevice pop gstate
- } bind def
-
-(%copygstatepagedevice) cvn
- { currentpagedevice pop copy
- } bind def
-
-(%currentgstatepagedevice) cvn
- { currentpagedevice pop currentgstate
- } bind def
-
-% Define interpreter callouts for handling gstate-restoring operators
-% when the current page device needs to be changed.
-% The names %grestorepagedevice, %grestoreallpagedevice,
-% %restorepagedevice, %restore1pagedevice, and %setgstatepagedevice
-% are known to the interpreter.
-
-/.installpagedevice
- { % Since setpagedevice doesn't create new device objects,
- % we must (carefully) reinstall the old parameters in
- % the same device.
- .currentpagedevice pop //null currentdevice //null .trysetparams
- dup type /booleantype eq
- { pop pop }
- { % This should never happen!
- SETPDDEBUG { (Error in .trysetparams!) = pstack flush } if
- cleartomark pop pop pop
- /.installpagedevice cvx /rangecheck signalerror
- }
- ifelse pop pop
- % A careful reading of the Red Book reveals that an erasepage
- % should occur, but *not* an initgraphics.
- erasepage .beginpage
- } bind def
-
-/.uninstallpagedevice
- { 2 .endpage { .currentnumcopies //false .outputpage } if
- nulldevice
- } bind def
-
-(%grestorepagedevice) cvn
- { .uninstallpagedevice grestore .installpagedevice
- } bind def
-
-(%grestoreallpagedevice) cvn
- { .uninstallpagedevice grestore .installpagedevice grestoreall
- } bind def
-
-(%restore1pagedevice) cvn
- { .uninstallpagedevice grestore .installpagedevice restore
- } bind def
-
-(%restorepagedevice) cvn
- { .uninstallpagedevice restore .installpagedevice
- } bind def
-
-(%setgstatepagedevice) cvn
- { .uninstallpagedevice setgstate .installpagedevice
- } bind def
-
-% Redefine .currentnumcopies so it consults the NumCopies device parameter.
-/.numcopiesdict mark
- /NumCopies dup
-.dicttomark readonly def
-
-/.currentnumcopies
- { currentdevice //.numcopiesdict .getdeviceparams
- dup type /integertype eq
- { exch pop exch pop }
- { cleartomark #copies }
- ifelse
- } bind odef
-
-% Redefine .currentpagedevice and .setpagedevice so they convert between
-% null and a fixed empty directionary.
-/.nullpagedevice 0 dict readonly def
-/.currentpagedevice {
- //.currentpagedevice exch dup //null eq { pop //.nullpagedevice } if exch
-} bind odef
-/.setpagedevice {
- dup //.nullpagedevice eq { pop //null } if //.setpagedevice
-} bind odef
-
-% ---------------- Auxiliary definitions ---------------- %
-
-% Define the required attributes of all page devices, and their default values.
-% We don't include attributes such as .MediaSize, which all devices
-% are guaranteed to supply on their own.
-/.defaultpolicies mark
- % M. Sweet, Easy Software Products
- %
- % Due to the fact that it is not possible to properly implement
- % the selection policies from a Ghostscript driver, we have changed
- % the default policy to "7" (impose) to avoid numerous problems with
- % printing within CUPS...
- %
- NOMEDIAATTRS {
- /PolicyNotFound 7
- /PageSize 7
- } {
- /PolicyNotFound 1
- /PageSize 0
- } ifelse
- /PolicyReport {
- dup /.LockSafetyParams known {
- % Only possible error is invalidaccess
- /setpagedevice .systemvar /invalidaccess signalerror
- }
- if
- pop
- } bind
-.dicttomark readonly def
-% Note that the values of .requiredattrs are executed, not just fetched.
-/.requiredattrs mark
- /PageDeviceName //null
- /PageOffset [0 0] readonly
-% We populate InputAttributes with all of the known page sizes
-% followed by a dummy media type that handles pages of any size.
-% This will create some duplicates, but that only slightly slows
-% down the media selection (loop is in zmedia2.c).
-%
-% Some PostScript creators assume that slot 0 is the default media
-% size and some can't handle a non-standard 4-element array which
-% is a 'range' type page size (always put last).
-%
-% Real Devices that can only handle specific page sizes will override this.
- /InputAttributes {
- mark
- % First put the device's default page size in slot 0
- % This satifies those that have devices built with a4 as the default
- 0 mark /PageSize currentdevice /PageSize gsgetdeviceprop .dicttomark
- statusdict /.pagetypenames get {
- counttomark 1 sub 2 idiv exch mark exch /PageSize exch
- % stack: mark --dict-- --dict-- ... key mark /PageSize pagetypename
- % see note above about pagetype executable array contents.
- load dup 0 get exch 1 get 2 array astore .dicttomark
- } forall
- % If NORANGEPAGESIZE is defined, (-dNORANGEPAGESIZE), then don't add
- % the 'match any' PageSize entry
- systemdict /NORANGEPAGESIZE known not {
- % Add one last entry which is the 4 element range array (non-standard)
- counttomark 2 idiv
- % PageSize with either dimension 0 will be detected in
- % match_page_size, so we can allow it here
- mark /PageSize [0 dup 16#7ffff dup] .dicttomark
- } if
- .dicttomark
- }
- (%MediaSource) 0
- /OutputAttributes {
- mark 0 mark .dicttomark readonly .dicttomark
- }
- (%MediaDestination) 0
- /Install {{.callinstall}} bind
- /BeginPage {{.callbeginpage}} bind
- /EndPage {{.callendpage}} bind
- /Policies .defaultpolicies
- /ImagingBBox //null % default value
- /UseCIEColor /.getuseciecolor load
-.dicttomark readonly def
-
-% Define currentpagedevice so it creates the dictionary on demand if needed,
-% adding all the required entries defined just above.
-% We have to deal specially with entries that the driver may change
-% on its own.
-/.dynamicppkeys mark
- /.MediaSize dup % because it changes when PageSize is set
-% /LeadingEdge dup
- /PageCount dup
- /Colors dup
- /BitsPerPixel dup
- /ColorValues dup
-.dicttomark readonly def
-/.makecurrentpagedevice { % - .makecurrentpagedevice <dict>
- currentdevice //null .getdeviceparams
- % Make the dictionary large enough to add defaulted entries.
- counttomark 2 idiv .requiredattrs length add dict
- counttomark 2 idiv { dup 4 2 roll put } repeat exch pop
- % Add any missing required attributes.
- % Make a writable and (if possible) local copy of any default
- % dictionaries, to work around a bug in the output of WordPerfect,
- % which assumes that these dictionaries are writable and local.
- .currentglobal exch dup gcheck .setglobal
- .requiredattrs {
- 2 index 2 index known {
- 1 index /Policies eq {
- % Merge policies from the device driver with defaults
- 2 index % <<>> /key value <<>>
- 3 2 roll get % <<>> value <<policies>>
- exch {
- 2 index 2 index known {
- pop pop
- } {
- 2 index 3 1 roll put
- } ifelse
- } forall
- pop
- } {
- pop pop
- } ifelse
- } {
- exec 2 index 3 1 roll put
- } ifelse
- } forall exch .setglobal
- dup .setpagedevice
-} bind def
-/currentpagedevice {
- .currentpagedevice {
- dup length 0 eq {
- pop .makecurrentpagedevice
- } {
- % If any of the dynamic keys have changed,
- % we must update the page device dictionary.
- currentdevice //.dynamicppkeys .getdeviceparams .dicttomark {
- % Stack: current key value
- 2 index 2 index .knownget { 1 index ne } { //true } ifelse
- { 2 index wcheck not
- { % This is the first entry being updated.
- % Copy the dictionary to make it writable.
- 3 -1 roll
- currentglobal 1 index dup gcheck currentglobal and setglobal
- length dict
- exch setglobal
- .copydict
- 3 1 roll
- }
- if
- 2 index 3 1 roll put
- }
- { pop pop
- }
- ifelse
- } forall
- % If the device is the distiller device, update distillerparams that
- % may have been changed by setdistillerparams
- currentdevice .devicename /pdfwrite eq {
- currentdistillerparams {
- % Stack: current key value
- 2 index 2 index .knownget { 1 index ne } { //true } ifelse
- { 2 index 3 1 roll put } { pop pop } ifelse
- } forall
- } if
- % If the dictionary was global and is now local, copy
- % any global subsidiary dictionaries to local VM. This
- % too is to work around the Word Perfect bug (see above).
- dup gcheck not {
- dup {
- dup type /dicttype eq { dup gcheck } { //false } ifelse {
- % Copy-on-write, see above.
- 2 index wcheck not {
- 3 -1 roll dup length dict .copydict
- 3 1 roll
- } if
- .copytree 2 index 3 1 roll put
- } {
- pop pop
- } ifelse
- } forall
- } if
- % We would like to do a .setpagedevice so we don't keep
- % re-creating the dictionary. Unfortunately, the effect
- % of this is that if any dynamic key changes (PageCount
- % in particular), we will do the equivalent of a
- % setpagedevice at the next restore or grestore.
- % Therefore, we make the dictionary read-only, but
- % we don't store it away. I.e., NOT:
- % dup wcheck { .setpagedevice .currentpagedevice pop } if
- readonly
- } ifelse
- } if
-} bind odef
-
-% Copy a dictionary recursively.
-/.copytree { % <dict> .copytree <dict'>
- dup length dict exch {
- dup type /dicttype eq { .copytree } if 2 index 3 1 roll put
- } forall
-} bind def
-
-% The implementation of setpagedevice is quite complex. Currently,
-% everything but the media matching algorithm is implemented here.
-
-% By default, we only present the requested changes to the device,
-% but there are some parameters that require special merging action.
-% Define those parameters here, with the procedures that do the merging.
-% The procedures are called as follows:
-% <merged> <key> <new_value> -proc- <merged> <key> <new_value'>
-/.mergespecial mark
- /InputAttributes
- { dup //null eq
- { pop //null
- }
- { 3 copy pop .knownget
- { dup //null eq
- { pop dup length dict }
- { dup length 2 index length add dict .copydict }
- ifelse
- }
- { dup length dict
- }
- ifelse .copydict readonly
- }
- ifelse
- } bind
- /OutputAttributes 1 index
- /Policies
- { 3 copy pop .knownget
- { dup length 2 index length add dict .copydict }
- { dup length dict }
- ifelse copy readonly
- } bind
-.dicttomark readonly def
-
-% M. Sweet, Easy Software Products:
-%
-% Define NOMEDIAATTRS to turn off the default (but unimplementable) media
-% selection policies for setpagedevice. This is used by CUPS to support
-% the standard Adobe media attributes.
-NOMEDIAATTRS {
- % Define only PageSize for input attribute matching.
- /.inputattrkeys [
- /PageSize
- ] readonly def
- % Define no other keys used in media selection.
- /.inputselectionkeys [
- /noInputSelectionsKeys
- ] readonly def
-
- % Define no keys used in output attribute matching.
- /.outputattrkeys [
- /noOutputAttrKeys
- ] readonly def
-} {
- % Define the keys used in input attribute matching.
- /.inputattrkeys [
- /PageSize /MediaColor /MediaWeight /MediaType /InsertSheet /ManualFeed
- % The following are documented in Adobe's supplement for v2017.
- /LeadingEdge /MediaClass
- ] readonly def
- % Define other keys used in media selection.
- /.inputselectionkeys [
- /MediaPosition /Orientation
- ] readonly def
-
- % Define the keys used in output attribute matching.
- /.outputattrkeys [
- /OutputType /Duplex /Tumble /ManualFeed
- ] readonly def
-} ifelse
-
-% Define all the parameters that should always be copied to the merged
-% dictionary.
-/.copiedkeys [
- /OutputDevice
- .mergespecial { pop } forall
- .inputattrkeys aload pop
- .inputselectionkeys aload pop
- .outputattrkeys aload pop
-] readonly def
-
-% Define the parameters that should not be presented to the device.
-% The procedures are called as follows:
-% <merged> <key> <value> -proc-
-% The procedure leaves all its operands on the stack and returns
-% true iff the key/value pair should be presented to .putdeviceparams.
-/.presentspecial mark
- .dynamicppkeys
- { pop dup /LeadingEdge ne { //false } { pop } ifelse }
- forall
- % We must ignore an explicit request for .MediaSize,
- % because media matching always handles this.
- /.MediaSize //false
- /Name //false
- /OutputDevice //false
- /PageDeviceName //false
- /PageOffset //false
- /PageSize //false % obsolete alias for .MediaSize
- /InputAttributes //false
- .inputattrkeys
- { dup dup /PageSize eq exch /LeadingEdge eq or
- { pop }
- { { 2 index /InputAttributes .knownget { //null eq } { //true } ifelse } }
- ifelse
- }
- forall
- .inputselectionkeys { //false } forall
- /OutputAttributes //false
- .outputattrkeys
- { { 2 index /OutputAttributes .knownget { //null eq } { //true } ifelse } }
- forall
- /Install //false
- /BeginPage //false
- /EndPage //false
- /Policies //false
- % Our extensions:
- /HWColorMap
- { % HACK: don't transmit the color map, because
- % window systems can change the color map on their own
- % incrementally. Someday we'll have a better
- % solution for this....
- //false
- }
- /ViewerPreProcess //false
- /ImagingBBox //false % This prevents the ImagingBBox value in the setpagedevice
- % from affecting the device's ImagingBBox parameter, but
- % does retain a 'shadow' copy at the PostScript level.
- % This is done for Adobe compatibility since Adobe does
- % render marks outside the ImagingBBox (and QuarkXpress
- % relies on it).
-.dicttomark readonly def
-
-% Define access to device defaults.
-/.defaultdeviceparams
- { finddevice //null .getdeviceparams
- } bind def
-
-% Select media (input or output). The hard work is done in an operator:
-% <pagedict> <attrdict> <policydict> <keys> .matchmedia <key> true
-% <pagedict> <attrdict> <policydict> <keys> .matchmedia false
-% <pagedict> null <policydict> <keys> .matchmedia null true
-/.selectmedia % <orig> <request> <merged> <failed> <-- retained
- % <attrdict> <policydict> <attrkeys> <mediakey>
- % .selectmedia
- { 5 index 5 -2 roll 4 index .matchmedia
- % Stack: orig request merged failed attrkeys mediakey
- % (key true | false)
- { 4 index 3 1 roll put pop
- }
- { % Adobe's implementations have a "big hairy heuristic"
- % to choose the set of keys to report as having failed the match.
- % For the moment, we report any keys that are in the request
- % and don't have the same value as in the original dictionary.
- 5 index 1 index .knownget
- { 4 index 3 1 roll put }
- { 3 index exch .undef }
- ifelse
- { % Stack: <orig> <request> <merged> <failed> <attrkey>
- 3 index 1 index .knownget
- { 5 index 2 index .knownget { ne } { pop //true } ifelse }
- { //true }
- ifelse % Stack: ... <failed> <attrkey> <report>
- { 2 copy /rangecheck put }
- if pop
- }
- forall
- }
- ifelse
- } bind def
-
-% Apply Policies to any unprocessed failed requests.
-% As we process each request entry, we replace the error name
-% in the <failed> dictionary with the policy value,
-% and we replace the key in the <merged> dictionary with its prior value
-% (or remove it if it had no prior value).
-/.policyprocs mark
-% These procedures are called with the following on the stack:
-% <orig> <merged> <failed> <Policies> <key> <policy>
-% They are expected to consume the top 2 operands.
-% NOTE: we currently treat all values other than 0, 1, or 7 (for PageSize)
-% the same as 0, i.e., we signal an error.
-%
-% M. Sweet, Easy Software Products:
-%
-% Define NOMEDIAATTRS to turn off the default (but unimplementable) media
-% selection policies for setpagedevice. This is used by CUPS to support
-% the standard Adobe media attributes.
- 0 { % Set errorinfo and signal a configurationerror.
- NOMEDIAATTRS {
- % NOMEDIAATTRS means that the default policy is 7...
- pop 2 index exch 7 put
- } {
- pop dup 4 index exch get 2 array astore
- $error /errorinfo 3 -1 roll put
- cleartomark
- /setpagedevice .systemvar /configurationerror signalerror
- } ifelse
- } bind
- 1 { % Roll back the failed request to its previous status.
-SETPDDEBUG { (Rolling back.) = pstack flush } if
- 3 index 2 index 3 -1 roll .forceput
- 4 index 1 index .knownget
- { 4 index 3 1 roll .forceput }
- { 3 index exch .undef }
- ifelse
- } .bind
- 7 { % For PageSize only, just impose the request.
- 1 index /PageSize eq
- { pop pop 1 index /PageSize 7 put }
- { .policyprocs 0 get exec }
- ifelse
- } bind
-.dicttomark readonly def
-/.applypolicies % <orig> <merged> <failed> .applypolicies
- % <orig> <merged'> <failed'>
- { 1 index /Policies get 1 index
- { type /integertype eq
- { pop % already processed
- }
- { 2 copy .knownget not { 1 index /PolicyNotFound get } if
- % Stack: <orig> <merged> <failed> <Policies> <key>
- % <policy>
- .policyprocs 1 index .knownget not { .policyprocs 0 get } if exec
- }
- ifelse
- }
- forall pop
- } bind def
-
-% Prepare to present parameters to the device, by spreading them onto the
-% operand stack and removing any that shouldn't be presented.
-/.prepareparams % <params> .prepareparams -mark- <key1> <value1> ...
- { mark exch dup
- { % Stack: -mark- key1 value1 ... merged key value
- .presentspecial 2 index .knownget
- { exec { 3 -1 roll } { pop pop } ifelse }
- { 3 -1 roll }
- ifelse
- }
- forall pop
- } bind def
-
-% Put device parameters without resetting currentpagedevice.
-% (.putdeviceparams clears the current page device.)
-/.putdeviceparamsonly % <device> <Policies|null> <require_all> -mark-
- % <key1> <value1> ... .putdeviceparamsonly
- % On success: <device> <eraseflag>
- % On failure: <device> <Policies|null> <req_all> -mark-
- % <key1> <error1> ...
- { .currentpagedevice
- { counttomark 4 add 1 roll .putdeviceparams
- dup type /booleantype eq { 3 } { counttomark 5 add } ifelse -1 roll
- .setpagedevice
- }
- { pop .putdeviceparams
- }
- ifelse
- } bind def
-
-% Try setting the device parameters from the merged request.
-/.trysetparams % <merged> <(ignored)> <device> <Policies>
- % .trysetparams
- { //true 4 index .prepareparams
- % Add the computed .MediaSize.
- % Stack: merged (ignored) device Policies -true-
- % -mark- key1 value1 ...
- counttomark 5 add index .computemediasize
- exch pop exch pop /.MediaSize exch
-SETPDDEBUG { (Putting.) = pstack flush } if
- .putdeviceparamsonly
-SETPDDEBUG { (Result of putting.) = pstack flush } if
- } bind def
-
-% Compute the media size and initial matrix from a merged request (after
-% media selection).
-/.computemediasize % <request> .computemediasize
- % <request> <matrix> <[width height]>
- { dup /PageSize get % requested page size
- 1 index /InputAttributes get
- 2 index (%MediaSource) get get /PageSize get % media size
- % (may be a range)
- 2 index /Policies get
- dup /PageSize .knownget
- { exch pop } { /PolicyNotFound get } ifelse % PageSize policy,
- % affects scaling
- 3 index /Orientation .knownget not { //null } if
- 4 index /RollFedMedia .knownget not { //false } if
- matrix .matchpagesize not {
- % This is a "can't happen" condition!
- /setpagedevice .systemvar /rangecheck signalerror
- } if
- 2 array astore
- } bind def
-
-% ---------------- setpagedevice itself ---------------- %
-
-/setpagedevice
- { % We mustn't pop the argument until the very end,
- % so that the pseudo-operator machinery can restore the stack
- % if an error occurs.
- mark 1 index currentpagedevice
-
- % Check whether we are changing OutputDevice;
- % also handle the case where the current device
- % is not a page device.
- % Stack: mark <request> <current>
-SETPDDEBUG { (Checking.) = pstack flush } if
-
- dup /OutputDevice .knownget
- { % Current device is a page device.
- 2 index /OutputDevice .knownget
- { % A specific OutputDevice was requested.
- 2 copy eq
- { pop pop //null }
- { exch pop }
- ifelse
- }
- { pop //null
- }
- ifelse
- }
- { % Current device is not a page device.
- % Use the default device.
- 1 index /OutputDevice .knownget not { .defaultdevicename } if
- }
- ifelse
- dup //null eq
- { pop
- }
- { exch pop .defaultdeviceparams
- % In case of duplicate keys, .dicttomark takes the entry
- % lower on the stack, so we can just append the defaults here.
- .requiredattrs { exec } forall .dicttomark
- }
- ifelse
-
- % Check whether a viewer wants to intervene.
- % We must check both the request (which takes precedence)
- % and the current dictionary.
- % Stack: mark <request> <orig>
- exch dup /ViewerPreProcess .knownget
- { exec }
- { 1 index /ViewerPreProcess .knownget { exec } if }
- ifelse exch
-
- % Construct a merged request from the actual request plus
- % any keys that should always be propagated.
- % Stack: mark <request> <orig>
-SETPDDEBUG { (Merging.) = pstack flush } if
-
- exch 1 index length 1 index length add dict
- .copiedkeys
- { % Stack: <orig> <request> <merged> <key>
- 3 index 1 index .knownget { 3 copy put pop } if pop
- }
- forall
- % Stack: <orig> <request> <merged>
- dup 2 index
- { % stack: <orig> <request> <merged> <merged> <rkey> <rvalue>
- .mergespecial 2 index .knownget { exec } if
- put dup
- }
- forall pop
- % Hack: if FIXEDRESOLUTION is true, discard any attempt to
- % change HWResolution.
- FIXEDRESOLUTION { dup /HWResolution .undef } if
- % Hack: if FIXEDMEDIA is true, discard any attempt to change
- % PageSize or HWSize.
- FIXEDMEDIA
- { dup /PageSize 4 index /PageSize get put
- dup /HWSize 4 index /HWSize get put
- } if
- % Hack: to work around some files that take a PageSize
- % from InputAttributes and impose it, discard any attempt
- % to set PageSize to a 4-element value.
- % Stack: mark <orig> <request> <merged>
- dup /PageSize .knownget {
- length 2 ne {
- dup /PageSize 4 index /PageSize get put
- } if
- } if
-
- % Select input and output media.
- % Stack: mark <orig> <request> <merged>
-SETPDDEBUG { (Selecting.) = pstack flush } if
-
- 0 dict % <failed>
- 1 index /InputAttributes .knownget
- { 2 index /Policies get
- .inputattrkeys (%MediaSource) cvn .selectmedia
- } if
- 1 index /OutputAttributes .knownget
- { 2 index /Policies get
- .outputattrkeys (%MediaDestination) cvn .selectmedia
- } if
- 3 -1 roll 4 1 roll % temporarily swap orig & request
- .applypolicies
- 3 -1 roll 4 1 roll % swap back
-
- % Construct the new device, and attempt to set its attributes.
- % Stack: mark <orig> <request> <merged> <failed>
-SETPDDEBUG { (Constructing.) = pstack flush } if
-
- currentdevice .devicename 2 index /OutputDevice get eq
- { currentdevice }
- { 1 index /OutputDevice get finddevice }
- ifelse
- %**************** We should copy the device here,
- %**************** but since we can't close the old device,
- %**************** we don't. This is WRONG.
- %****************copydevice
- 2 index /Policies get
- .trysetparams
- dup type /booleantype ne
- { % The request failed.
- % Stack: ... <orig> <request> <merged> <failed> <device>
- % <Policies> true mark <name> <errorname> ...
-SETPDDEBUG { (Recovering.) = pstack flush } if
- counttomark 4 add index
- counttomark 2 idiv { dup 4 -2 roll put } repeat
- pop pop pop
- % Stack: mark ... <orig> <request> <merged> <failed> <device>
- % <Policies>
- 6 2 roll 3 -1 roll 4 1 roll
- .applypolicies
- 3 -1 roll 4 1 roll 6 -2 roll
- .trysetparams % shouldn't fail!
- dup type /booleantype ne
- { 2 { counttomark 1 add 1 roll cleartomark } repeat
- /setpagedevice .systemvar exch signalerror
- }
- if
- }
- if
-
- % The attempt succeeded. Install the new device.
- % Stack: mark ... <merged> <failed> <device> <eraseflag>
-SETPDDEBUG { (Installing.) = pstack flush } if
-
- pop 2 .endpage
- { 1 //true .outputpage
- (>>setpagedevice, press <return> to continue<<\n) .confirm
- }
- if
- % .setdevice clears the current page device!
- .currentpagedevice pop exch
- .setdevice pop
- .setpagedevice
-
- % Implement UseCIEColor directly if this is a LL3 system.
- % The color substitution feature is now implemented in
- % the interpreter, and this is used as an optimization.
- %
- % NB: This shoud be the only use of the .setuseciecolor
- % operator anywhere.
- %
- % If UseCIEColor is transitioned to false, set some
- % color space other than /DeviceGray, to insure that
- % initgraphics will actually perform a setcolorspace
- % operation (there is an optimization in setcolorspace
- % that does nothing if the operand and current color
- % spaces are the same, and UseCIEColor is false).
-
- /.setuseciecolor where
- {
- pop 1 index /UseCIEColor .knownget
- {
- dup .setuseciecolor not
- { /DeviceRGB setcolorspace }
- if
- }
- if
- }
- if
-
- % Merge the request into the current page device,
- % unless we're changing the OutputDevice.
- % Stack: mark ... <merged> <failed>
- exch currentpagedevice dup length 2 index length add dict
- % Stack: mark ... <failed> <merged> <current> <newdict>
- 2 index /OutputDevice .knownget {
- 2 index /OutputDevice .knownget not { //null } if eq
- } {
- //true
- } ifelse {
- % Same OutputDevice, merge the dictionaries.
- .copydict
- } {
- % Different OutputDevice, discard the old dictionary.
- exch pop
- } ifelse .copydict
- % Initialize the default matrix, taking media matching
- % into account.
- .computemediasize pop initmatrix concat
- dup /PageOffset .knownget
- { % Translate by the given number of 1/72" units in device X/Y.
- dup 0 get exch 1 get
- 2 index /HWResolution get dup 1 get exch 0 get
- 4 -1 roll mul 72 div 3 1 roll mul 72 div
- idtransform translate
- }
- if
- % We must install the new page device dictionary
- % before calling the Install procedure.
- dup .setpagedevice
- .setdefaulthalftone % Set the default screen before calling Install.
- dup /Install .knownget {
- { .execinstall } stopped {
- pop % Install procedure failed. One element will have been left on the stack.
- % stack: mark <orig> <request> <failed> <merged>
- 1 index /Install $error /errorname get put % Put it in the "failed" dict
- % .applypolicies needs stack: <orig> <merged> <failed>
- exch 4 2 roll exch 4 2 roll .applypolicies exch 4 2 roll exch 4 2 roll
- % Now execute the old Install -- failures after this are not handled
- dup /Install .knownget { { .execinstall } stopped { pop } if } if
- .postinstall stop
- } {
- .postinstall
- } ifelse
- } {
- .postinstall
- } ifelse
-} odef
-
-% We break out the code after calling the Install procedure into a
-% separate procedure, since it is executed even if Install causes an error.
-% By making .execinstall a separate operator procedure, we get the stacks
-% mostly restored if it fails, except for one element (the operand).
-% Thus if it fails, there will be one element left on the op stack.
-
-/.execinstall { % <proc> .execinstall -
- dup % element left on the stack if the exec fails.
-
- % Because the interpreter optimizes tail calls, we can't just let
- % the body of this procedure be 'exec', because that would lose
- % the stack protection that is the whole reason for having the
- % procedure in the first place. The 'pop' for the dummy element
- % on the op stack suffices.
- exec
- pop % See above.
-} odef
-
-/.postinstall { % mark ... <failed> <merged> .postinstall -
- matrix currentmatrix .setdefaultmatrix
- % Erase and initialize the page.
- initgraphics
- currentoverprint //false setoverprint 1 setcolor
- .fillpage
- 0 setcolor setoverprint
- .beginpage
-
- % Clean up, calling PolicyReport if needed.
- % Stack: mark ... <failed> <merged>
-SETPDDEBUG { (Finishing.) = pstack flush } if
-
- exch dup length 0 ne
- { 1 index /Policies get /PolicyReport get
- counttomark 1 add 2 roll cleartomark
- exec
- }
- { cleartomark
- }
- ifelse pop
-
-} odef
-
-end % level2dict
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_statd.ps b/Master/tlpkg/tlgs/lib/gs_statd.ps deleted file mode 100644 index 4ad40b50667..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_statd.ps +++ /dev/null @@ -1,374 +0,0 @@ -% Copyright (C) 1989, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_statd.ps 6300 2005-12-28 19:56:24Z giles $
-% This file provides statusdict, serverdict, and assorted LaserWriter
-% operators, mostly for the benefit of poorly designed PostScript programs
-% that 'know' they are running on a LaserWriter.
-
-systemdict begin
- % We make statusdict a little larger for Level 2 stuff.
- % Note that it must be allocated in local VM.
- .currentglobal false .setglobal
- /statusdict 89 dict .forcedef % statusdict is local, sys'dict global
- % To support the Level 2 job control features,
- % serverdict must also be in local VM.
- /serverdict 10 dict .forcedef % serverdict is local, sys'dict global
- .setglobal
-end
-
-% Define various paper formats. The Adobe documentation defines only these:
-% 11x17, a3, a4, a4small, b5, ledger, legal, letter, lettersmall, note.
-% These procedures are also accessed as data structures during initialization,
-% so the page dimensions must be the first two elements of the procedure.
-
-/.setpagesize { /statusdict .systemvar begin .setpagesize end } bind def
-userdict begin
- % Page sizes defined by Adobe documentation
- % Note: these executable arrays should all begin with two
- % integers which are the width and height (see gs_setpd.ps).
- /11x17 {792 1224 //.setpagesize exec} bind def % 11x17 portrait
- /a3 {842 1191 //.setpagesize exec} bind def
- /a4 {595 842 //.setpagesize exec} bind def
-% a4small should be a4 with an ImagingBBox of [25 25 570 817].
- /a4small /a4 load def
-% b5 see below.
- /ledger {1224 792 //.setpagesize exec} bind def % 11x17 landscape
- /legal {612 1008 //.setpagesize exec} bind def
- /letter {612 792 //.setpagesize exec} bind def
-% lettersmall should be letter with an ImagingBBox of [25 25 587 767].
- /lettersmall /letter load def
-% note should be letter (or some other size) with the ImagingBBox
-% shrunk by 25 units on all 4 sides.
- /note /letter load def
- % End of Adobe-defined page sizes
-STRICT { (%END SIZES) .skipeof } if
- % Other page sizes
- % ISO standard paper sizes
- /a0 {2384 3370 //.setpagesize exec} bind def
- /a1 {1684 2384 //.setpagesize exec} bind def
- /a2 {1191 1684 //.setpagesize exec} bind def
-% /a3 {842 1191 //.setpagesize exec} bind def % defined by Adobe
-% /a4 {595 842 //.setpagesize exec} bind def % defined by Adobe
- /a5 {420 595 //.setpagesize exec} bind def
- /a6 {297 420 //.setpagesize exec} bind def
- /a7 {210 297 //.setpagesize exec} bind def
- /a8 {148 210 //.setpagesize exec} bind def
- /a9 {105 148 //.setpagesize exec} bind def
- /a10 {73 105 //.setpagesize exec} bind def
-% ISO and JIS B sizes are different....
- /isob0 {2835 4008 //.setpagesize exec} bind def
- /b0 /isob0 load def
- /isob1 {2004 2835 //.setpagesize exec} bind def
- /b1 /isob1 load def
- /isob2 {1417 2004 //.setpagesize exec} bind def
- /b2 /isob2 load def
- /isob3 {1001 1417 //.setpagesize exec} bind def
- /b3 /isob3 load def
- /isob4 {709 1001 //.setpagesize exec} bind def
- /b4 /isob4 load def
- /isob5 {499 709 //.setpagesize exec} bind def
- /b5 /isob5 load def
- /isob6 {354 499 //.setpagesize exec} bind def
- /b6 /isob6 load def
- /jisb0 {2920 4127 //.setpagesize exec} bind def
- /jisb1 {2064 2920 //.setpagesize exec} bind def
- /jisb2 {1460 2064 //.setpagesize exec} bind def
- /jisb3 {1032 1460 //.setpagesize exec} bind def
- /jisb4 {729 1032 //.setpagesize exec} bind def
- /jisb5 {516 729 //.setpagesize exec} bind def
- /jisb6 {363 516 //.setpagesize exec} bind def
- /c0 {2599 3677 //.setpagesize exec} bind def
- /c1 {1837 2599 //.setpagesize exec} bind def
- /c2 {1298 1837 //.setpagesize exec} bind def
- /c3 {918 1298 //.setpagesize exec} bind def
- /c4 {649 918 //.setpagesize exec} bind def
- /c5 {459 649 //.setpagesize exec} bind def
- /c6 {323 459 //.setpagesize exec} bind def
- % U.S. CAD standard paper sizes
- /archE {2592 3456 //.setpagesize exec} bind def
- /archD {1728 2592 //.setpagesize exec} bind def
- /archC {1296 1728 //.setpagesize exec} bind def
- /archB {864 1296 //.setpagesize exec} bind def
- /archA {648 864 //.setpagesize exec} bind def
- % Other paper sizes
- /flsa {612 936 //.setpagesize exec} bind def % U.S. foolscap
- /flse {612 936 //.setpagesize exec} bind def % European foolscap
- /halfletter {396 612 //.setpagesize exec} bind def
- % minimum of a4 and letter (a4 width, letter length)
- /pa4 {595 792 //.setpagesize exec} bind def
-% /tabloid {792 1224 //.setpagesize exec} bind def % 11x17 portrait
-% /csheet {1224 1584 //.setpagesize exec} bind def % ANSI C 17x22
-% /dsheet {1584 2448 //.setpagesize exec} bind def % ANSI D 22x34
-% /esheet {2448 3168 //.setpagesize exec} bind def % ANSI E 34x44
-%END SIZES
-end
-currentdict /.setpagesize .undef
-
-statusdict begin
-
-% Define the pagetype values for the known page formats.
-% The values for all but letter and note are arbitrary.
-/.pagetypenames
- [ /letter /note %do not change this line, needed by 'setpagetype'
- /legal /lettersmall
- /11x17 /ledger
- /a4small /a3 /a4
-STRICT { (%END SIZES) .skipeof } if
- /a0 /a1 /a2 /a5 /a6 /a7 /a8 /a9 /a10
- /archA /archB /archC /archD /archE
- /b0 /b1 /b2 /b3 /b4 /b5 /b6
- /c0 /c1 /c2 /c3 /c4 /c5 /c6
- /flsa /flse /halfletter
- /isob0 /isob1 /isob2 /isob3 /isob4 /isob5 /isob6
- /jisb0 /jisb1 /jisb2 /jisb3 /jisb4 /jisb5 /jisb6
- /pa4
-%END SIZES
- ] cvlit readonly def
-
-%%%%%% The following items were suggested by a user as useful.
-
-% Permanent definitions
-
-/ramsize 4194304 def
-/hardwareiomode 0 def
- /sethardwareiomode {pop} bind def
-/softwareiomode 0 def
- /setsoftwareiomode {pop} bind def
-/dosysstart false def
- /setdosysstart {pop} bind def
-/allowjobreset true def
- /setallowjobreset {pop} bind def
-/defaultpaperfamily 0 def
- /setdefaultpaperfamily {pop} bind def
-/defaultpapertray 0 def
- /setdefaultpapertray {pop} bind def
-/defaulttrayswitch false def
- /setdefaulttrayswitch {pop} bind def
-
-% Tray and format selection
-
- /11x17tray {/11x17 .uservar exec} bind def
- /a3tray {/a3 .uservar exec} bind def
- /a4tray {/a4 .uservar exec} bind def
- /a5tray {/a5 .uservar exec} bind def
- /a6tray {/a6 .uservar exec} bind def
- /b4tray {/b4 .uservar exec} bind def
- /b5tray {/b5 .uservar exec} bind def
- /flsatray {/flsa .uservar exec} bind def
- /flsetray {/flse .uservar exec} bind def
- /halflettertray {/halfletter .uservar exec} bind def
- /ledgertray {/ledger .uservar exec} bind def
- /legaltray {/legal .uservar exec} bind def
- /lettertray {/letter .uservar exec} bind def
-
-% Per-job parameters
-
-/paperfamily 0 def % 0 is US, 1 is European
-/papertray 1 def
- /setpapertray {statusdict exch /papertray exch put} bind def
-/trayswitch false def % paperout feeds from another tray
-% We don't implement the (undocumented by Adobe) papersize 'operator',
-% because it's very awkward to make it interact properly with all the
-% different ways of setting the paper size.
-%/papersize {/letter true} bind def % <name of paper size>, <short-edge-first-p>
-/appletalktype (LaserWriter) def
-
-%%%%%% The following items are defined in the PostScript Language
-%%%%%% Reference Manual, First Edition, and subsequent 'compatibility'
-%%%%%% documentation from Adobe.
-
- /checkpassword {statusdict begin .password eq end} bind def
- /defaulttimeouts {statusdict begin .timeouts aload pop end} bind def
- /diskonline {
- false (%disk*%) { pop not exit } 8192 string /IODevice resourceforall
- } bind def
- /diskstatus {10240 2097152 } bind odef % - diskstatus <free> <total> (in 1024 byte pages)
-
-%/dostartpage
- /eescratch {pop 0} bind def
- /idlefonts {statusdict begin mark .idlefonts aload pop end} bind def
- /jobname () def
-%/jobtimeout
- /manualfeed false def
- /manualfeedtimeout 60 def
- /margins {statusdict begin .topmargin .leftmargin end} bind def
- /pagecount {4711} bind def
- /pagestackorder {false} bind def
- /pagetype 0 def
- /prefeed false def
- /printererror {pop pop} bind def
- /printername {statusdict /.printername get exch copy} bind def
- /processcolors /processcolors load def % defined in systemdict
- /product product def % product is defined in systemdict
- /revision revision def % revision is defined in systemdict
- /sccbatch {pop 9600 0} bind def
- /sccinteractive {pop 9600 0} bind def
- /setdefaulttimeouts {statusdict begin .timeouts astore pop end} bind def
- /setdostartpage {statusdict exch /dostartpage exch put} bind def
- /setduplexmode {mark /Duplex 3 -1 roll currentdevice putdeviceprops} bind def
- /seteescratch {pop pop} bind def
- /setidlefonts {] statusdict exch /.idlefonts exch put} bind def
- /setjobtimeout {statusdict exch /jobtimeout exch put} bind def
- /setmargins
- { statusdict begin
- /.leftmargin exch def /.topmargin exch def
- end
- } bind def
-
-% The following compatibility operators are only documented by Adobe in a
-% supplement to the Red Book.
-%
-% - pagemargin <offset>
-% - pageparams <width> <height> <offset> <orientation>
-% <width> <height> <orientation> setpage -
-% <offset> setpagemargin -
-% <width> <height> <offset> <orientation> setpageparams -
-%
-% width and height are in default units (and if orientation is odd, are
-% exchanged!). offset is the x margin, also in default units.
-% Unfortunately, because orientation is relative to the device paper feed,
-% it does not have a consistent meaning in terms of image orientation.
-% We follow the convention that ORIENT1 determines the orientation value
-% that means portait: false means 0, true means 1.
-
- /pagemargin { 0 } bind def
- /pageparams
- { currentdevice 1 dict dup /.MediaSize dup put .getdeviceparams
- exch pop exch pop aload pop 0 ORIENT1 { 1 } { 0 } ifelse
- } bind def
- /setpage
- { ORIENT1 { 1 } { 0 } ifelse ne {exch} if
- statusdict /.setpagesize get exec
- } bind def
- /setpagemargin {pop} bind def % can't do better without setpagedevice
- /setpageparams
- { exch pop ORIENT1 { 1 } { 0 } ifelse ne {exch} if
- statusdict /.setpagesize get exec
- } bind def
- /setpagetype
- { statusdict begin
- % The Adobe documentation only defines setpagetype
- % (a Level 1 operator) as accepting the values 0 and 1,
- % so we do too.
- dup .pagetypenames 0 2 getinterval exch get
- //systemdict /userdict get exch get cvx exec
- /pagetype exch def
- end
- } bind def
- /setpassword
- {exch checkpassword
- {statusdict exch /.password exch put true}
- {pop false}
- ifelse} bind def
- /setprintername
- {dup length string copy statusdict exch /.printername exch put} bind def
-
-% setresolution is not documented by Adobe, but some applications
-% use it anyway, without testing whether or not it is present.
-%
-% <pixels_per_inch> setresolution -
-%
-% sets the resolution of the device.
-
- /setresolution
- { mark /HWResolution [ 4 -1 roll dup ] currentdevice putdeviceprops pop
- initmatrix erasepage
- } bind def
- /setsccbatch {pop pop pop} bind def
- /setsccinteractive {pop pop pop} bind def
- /settumble {pop} bind def
- /waittimeout 300 def
-
-%%%%%% End of documented items.
-
-/.setpagesize
- { mark /HWSize [
- 4 index 4 index matrix defaultmatrix dtransform
- abs ceiling cvi exch abs ceiling cvi exch
- ] currentdevice putdeviceprops pop pop pop
- initmatrix initclip erasepage
- } bind def
-/.password 0 def
-/.timeouts [0 60 30] def
-true setdostartpage
-mark setidlefonts
-0 setjobtimeout
-0 0 setmargins
-product setprintername
-
-end % statusdict
-
-%%%%%% The following documented compatibility "operators" are in systemdict,
-%%%%%% not in statusdict.
-
-systemdict begin
-.currentglobal true .setglobal
-
-/devformat true def
-/devforall { % <pattern> <proc> <scratch> devforall -
- exch {
- 1 index currentdevparams
- /Type .knownget { /FileSystem eq } { false } ifelse
- { exec } { pop pop } ifelse
- } /exec load 3 packedarray cvx exch
- (*) 3 1 roll /IODevice resourceforall
-} odef
-
-/devstatus { % <(%disk*%)> devstatus <searchable> <writable>
- % <hasNames> <mounted> <removable> <searchOrder>
- % <freePages> <size> true
- % <string> devstatus false
- dup length 5 ge {
- dup 0 5 getinterval (%disk) eq {
- dup /IODevice resourcestatus {
- pop pop dup currentdevparams
- dup /Searchable get
- exch dup /Writeable get
- exch dup /HasNames get
- exch dup /Mounted get
- exch dup /Removable get
- exch dup /SearchOrder get
- exch dup /Free get
- exch /LogicalSize get
- 9 -1 roll pop true
- } {
- pop false
- } ifelse
- } {
- pop false
- } ifelse
- } {
- pop false
- } ifelse
-} odef
-
-.setglobal end % systemdict
-
-% The following contents of serverdict are a complete guess,
-% based on some observed LaserWriter boilerplate.
-
-serverdict begin
-
- /execjob { } bind def
-% The Red Book implies that something like the following is
-% an appropriate definition of exitserver.
- /exitserver { clear stop } bind def
-% However, this interacts badly with our standard error handler,
-% so we override it with the following less appropriate definition.
- /exitserver { 0 ne { clear cleardictstack } if } bind def
- /setrealdevice { } bind def
-
-end % serverdict
diff --git a/Master/tlpkg/tlgs/lib/gs_std_e.ps b/Master/tlpkg/tlgs/lib/gs_std_e.ps deleted file mode 100644 index e07c90c996d..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_std_e.ps +++ /dev/null @@ -1,73 +0,0 @@ -% Copyright (C) 1993, 1994 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_std_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the standard encoding vector.
-/StandardEncoding
-% \00x
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-% \04x
- /space /exclam /quotedbl /numbersign
- /dollar /percent /ampersand /quoteright
- /parenleft /parenright /asterisk /plus
- /comma /hyphen /period /slash
- /zero /one /two /three
- /four /five /six /seven
- /eight /nine /colon /semicolon
- /less /equal /greater /question
-% \10x
- /at /A /B /C /D /E /F /G
- /H /I /J /K /L /M /N /O
- /P /Q /R /S /T /U /V /W
- /X /Y /Z /bracketleft /backslash /bracketright /asciicircum /underscore
-% \14x
- /quoteleft /a /b /c /d /e /f /g
- /h /i /j /k /l /m /n /o
- /p /q /r /s /t /u /v /w
- /x /y /z /braceleft /bar /braceright /asciitilde /.notdef
-% \20x
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-% \24x
- /.notdef /exclamdown /cent /sterling
- /fraction /yen /florin /section
- /currency /quotesingle /quotedblleft /guillemotleft
- /guilsinglleft /guilsinglright /fi /fl
- /.notdef /endash /dagger /daggerdbl
- /periodcentered /.notdef /paragraph /bullet
- /quotesinglbase /quotedblbase /quotedblright /guillemotright
- /ellipsis /perthousand /.notdef /questiondown
-% \30x
- /.notdef /grave /acute /circumflex /tilde /macron /breve /dotaccent
- /dieresis /.notdef /ring /cedilla /.notdef /hungarumlaut /ogonek /caron
- /emdash /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
- /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-% \34x
- /.notdef /AE /.notdef /ordfeminine /.notdef /.notdef /.notdef /.notdef
- /Lslash /Oslash /OE /ordmasculine /.notdef /.notdef /.notdef /.notdef
- /.notdef /ae /.notdef /.notdef /.notdef /dotlessi /.notdef /.notdef
- /lslash /oslash /oe /germandbls /.notdef /.notdef /.notdef /.notdef
-% Make an array on large systems, a packed array on small ones.
-256
-vmstatus exch pop exch pop
-100000 ge { array astore readonly } { packedarray } ifelse
-def
-0 StandardEncoding .registerencoding
-/StandardEncoding StandardEncoding .defineencoding
diff --git a/Master/tlpkg/tlgs/lib/gs_sym_e.ps b/Master/tlpkg/tlgs/lib/gs_sym_e.ps deleted file mode 100644 index d4ab056cff5..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_sym_e.ps +++ /dev/null @@ -1,83 +0,0 @@ -% Copyright (C) 1991, 1994, 1998, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_sym_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Symbol encoding vector.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/SymbolEncoding
-% \000
- StandardEncoding 0 32 getinterval aload pop % /.notdef
-% \040
- /space /exclam /universal /numbersign
- /existential /percent /ampersand /suchthat
- /parenleft /parenright /asteriskmath /plus
- /comma /minus /period /slash
- /zero /one /two /three
- /four /five /six /seven
- /eight /nine /colon /semicolon
- /less /equal /greater /question
-% \100
- /congruent /Alpha /Beta /Chi
- /Delta /Epsilon /Phi /Gamma
- /Eta /Iota /theta1 /Kappa
- /Lambda /Mu /Nu /Omicron
- /Pi /Theta /Rho /Sigma
- /Tau /Upsilon /sigma1 /Omega
- /Xi /Psi /Zeta /bracketleft
- /therefore /bracketright /perpendicular /underscore
-% \140
- /radicalex /alpha /beta /chi
- /delta /epsilon /phi /gamma
- /eta /iota /phi1 /kappa
- /lambda /mu /nu /omicron
- /pi /theta /rho /sigma
- /tau /upsilon /omega1 /omega
- /xi /psi /zeta /braceleft
- /bar /braceright /similar /.notdef
-% \200
- StandardEncoding 0 32 getinterval aload pop % /.notdef
-% \240
- /Euro /Upsilon1 /minute /lessequal
- /fraction /infinity /florin /club
- /diamond /heart /spade /arrowboth
- /arrowleft /arrowup /arrowright /arrowdown
- /degree /plusminus /second /greaterequal
- /multiply /proportional /partialdiff /bullet
- /divide /notequal /equivalence /approxequal
- /ellipsis /arrowvertex /arrowhorizex /carriagereturn
-% \300
- /aleph /Ifraktur /Rfraktur /weierstrass
- /circlemultiply /circleplus /emptyset /intersection
- /union /propersuperset /reflexsuperset /notsubset
- /propersubset /reflexsubset /element /notelement
- /angle /gradient /registerserif /copyrightserif
- /trademarkserif /product /radical /dotmath
- /logicalnot /logicaland /logicalor /arrowdblboth
- /arrowdblleft /arrowdblup /arrowdblright /arrowdbldown
-% \340
- /lozenge /angleleft /registersans /copyrightsans
- /trademarksans /summation /parenlefttp /parenleftex
- /parenleftbt /bracketlefttp /bracketleftex /bracketleftbt
- /bracelefttp /braceleftmid /braceleftbt /braceex
- /.notdef /angleright /integral /integraltp
- /integralex /integralbt /parenrighttp /parenrightex
- /parenrightbt /bracketrighttp /bracketrightex /bracketrightbt
- /bracerighttp /bracerightmid /bracerightbt /.notdef
-256 packedarray .defineencoding
-2 SymbolEncoding .registerencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_t.xbm b/Master/tlpkg/tlgs/lib/gs_t.xbm deleted file mode 100644 index e35c2b7acb8..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_t.xbm +++ /dev/null @@ -1,8 +0,0 @@ -#define gs_t.xbm_width 16
-#define gs_t.xbm_height 16
-#define gs_t.xbm_x_hot 0
-#define gs_t.xbm_y_hot 0
-static unsigned char gs.t.bm_bits[] = {
- 0x00, 0x10, 0x00, 0x20, 0x00, 0x68, 0xf0, 0x67, 0xfc, 0x61, 0x7e, 0x70,
- 0x1f, 0xf9, 0x4f, 0xfd, 0x4f, 0xfc, 0x0f, 0xf8, 0x1f, 0xf3, 0x1e, 0xe3,
- 0x3e, 0x60, 0x7c, 0x30, 0x70, 0x0c, 0x1e, 0x00};
diff --git a/Master/tlpkg/tlgs/lib/gs_t.xpm b/Master/tlpkg/tlgs/lib/gs_t.xpm deleted file mode 100644 index 8b587ecd69d..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_t.xpm +++ /dev/null @@ -1,28 +0,0 @@ -/* XPM */
-static char * gs_t_xpm[] = {
-/* width height ncolors cpp [x_hot y_hot] */
-"16 16 6 1 0 0",
-/* colors */
-" s none m none c none",
-". s iconColor1 m black c black",
-"X s iconColor2 m white c white",
-"o c #808080808080",
-"O c #C0C0C0C0C0C0",
-"+ c #00000000FFFF",
-/* pixels */
-" . ",
-" X. ",
-" .X.o ",
-" o......XX.. ",
-" .......OXXX.. ",
-" ......XXXXXo.. ",
-"o....XXX+XX.....",
-"....XX+X+Xo.....",
-"....XX+XXXo.....",
-"....XXXXXXX.....",
-"o...oXXX++XX....",
-" ....XXX++XXX..o",
-" ....oXXXXXXX.. ",
-" .....XXXXX.. ",
-" ...XXXoo ",
-" o...XXXXXXX "};
diff --git a/Master/tlpkg/tlgs/lib/gs_t_m.xbm b/Master/tlpkg/tlgs/lib/gs_t_m.xbm deleted file mode 100644 index 3cfe6237bc5..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_t_m.xbm +++ /dev/null @@ -1,8 +0,0 @@ -#define gs_t_m.xbm_width 16
-#define gs_t_m.xbm_height 16
-#define gs_t_m.xbm_x_hot 0
-#define gs_t_m.xbm_y_hot 0
-static unsigned char gs.t_m.bm_bits[] = {
- 0x00, 0x10, 0x00, 0x30, 0x00, 0x78, 0xf0, 0x7f, 0xfc, 0x7f, 0xfe, 0x7f,
- 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xfe, 0xff,
- 0xfe, 0x7f, 0xfc, 0x3f, 0xf0, 0x0f, 0xfe, 0x0f};
diff --git a/Master/tlpkg/tlgs/lib/gs_trap.ps b/Master/tlpkg/tlgs/lib/gs_trap.ps deleted file mode 100644 index 21e12b388ef..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_trap.ps +++ /dev/null @@ -1,103 +0,0 @@ -% Copyright (C) 1999, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_trap.ps 6300 2005-12-28 19:56:24Z giles $
-% PostScript LanguageLevel 3 in-RIP trapping support.
-
-ll3dict begin
-
-% We need LanguageLevel 2 or higher in order to have setuserparams and
-% defineresource.
-languagelevel dup 2 .max .setlanguagelevel
-
-% ------ Trapping ------ %
-
-% The PostScript-level trapping parameters are maintained in userdict,
-% and explicitly reinstalled upon restore.
-
-/Trapping mark
-
-/settrapparams dup { % <paramdict> settrapparams -
- /.trapparams .uservar dup length dict .copydict
- dup 2 index {
- % Stack: paramdict olddict olddict key value
- 2 index 2 index known { put dup } { pop pop } ifelse
- } forall pop
- dup .settrapparams % Let the operator check parameter validity.
- .userdict /.trapparams 3 -1 roll put pop
-} bind .makeoperator
-
-/.copyparams { % <obj> .copyparams <obj'>
- dup type /dicttype eq {
- dup length dict .copydict
- dup {
- .copyparams 3 copy put pop pop
- } forall
- } {
- dup type /arraytype eq {
- [ exch { .copyparams } forall ]
- } if
- } ifelse
-} odef
-
-/currenttrapparams dup { % - currenttrapparams <paramdict>
- /.trapparams .uservar .copyparams
-} bind .makeoperator
-
-/settrapzone dup { % - settrapzone -
- % ****** DUMMY ******
- newpath
-} bind .makeoperator
-
-% Define initial (dummy) trapping parameters.
-% These values are mostly complete guesses.
-userdict /.trapparams mark
- /BlackColorLimit 1.0
- /BlackDensityLimit 1.0
- /BlackWidth 1.0
- /ColorantZoneDetails 0 dict
- /Enabled true
- /HalftoneName null
- /ImageInternalTrapping false
- /ImagemaskTrapping true
- /ImageResolution 1
- /ImageToObjectTrapping true
- /ImageTrapPlacement /Center
- /SlidingTrapLimit 1.0
- /StepLimit 1.0
- /TrapColorScaling 0.0
- /TrapSetName null
- /TrapWidth 1.0
-.dicttomark readonly put
-
-.dicttomark /ProcSet defineresource pop
-
-% Define the InkParams and TrapParams resource categories.
-{ /InkParams /TrapParams } {
- /Generic /Category findresource dup maxlength 3 add dict .copydict begin
- /InstanceType /dicttype def
- currentdict end /Category defineresource pop
-} forall
-
-% Define the TrappingType resource category.
-/Generic /Category findresource dup maxlength 3 add dict .copydict begin
- /InstanceType /integertype def
-/TrappingType currentdict end /Category defineresource pop
-
-{1001} { dup /TrappingType defineresource pop } forall
-
-.setlanguagelevel
-
-end % ll3dict
diff --git a/Master/tlpkg/tlgs/lib/gs_ttf.ps b/Master/tlpkg/tlgs/lib/gs_ttf.ps deleted file mode 100644 index e6295825fbb..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_ttf.ps +++ /dev/null @@ -1,1947 +0,0 @@ -% Copyright (C) 1996-2003 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_ttf.ps 8556 2008-02-28 14:56:32Z alexcher $
-% Support code for direct use of TrueType fonts.
-% (Not needed for Type 42 fonts.)
-
-% Note that if you want to use this file without including the ttfont.dev
-% option when you built Ghostscript, you will need to load the following
-% files before this one:
-% lib/gs_mgl_e.ps
-% lib/gs_mro_e.ps
-% lib/gs_wan_e.ps
-
-% Thanks to B. Jackowski and GUST (the Polish TeX Users' Group) for
-% the glyf-splitting code.
-
-% ---------------- Font loading machinery ---------------- %
-
-% Augment the FONTPATH machinery so it recognizes TrueType fonts.
-
-/.scanfontheaders where {
- pop /.scanfontheaders [
- .scanfontheaders aload pop (\000\001\000\000*) (true*)
- ] def
-} if
-
-% <file> <key> .findfontvalue <value> true
-% <file> <key> .findfontvalue false
-% Closes the file in either case.
-/.findnonttfontvalue /.findfontvalue load def
-/.findfontvalue {
- 1 index read {
- 2 index 1 index unread
- % beginning with binary 0 or 't' (TrueType), or 'O' (OpenType)
- dup 0 eq 1 index (O) 0 get eq or exch (t) 0 get eq or {
- % If this is a font at all, it's a TrueType font.
- dup /FontType eq {
- pop closefile 42 true
- } {
- dup /FontName eq { pop .findttfontname } { pop closefile false } ifelse
- } ifelse
- } {
- % Not a TrueType font.
- .findnonttfontvalue
- } ifelse
- } { pop closefile false } ifelse
-} bind def
-
-% <file> .findttfontname <fname> true
-% <file> .findttfontname false
-% Closes the file in either case.
-/.findttfontname {
- //true 0 .loadttfonttables
- tabdict /name .knownget {
- dup 8 getu32 f exch setfileposition
- 12 getu32 string f exch readstring pop
- dup
- 6 findname not {
- 4 findname % Try FullName
- } {
- exch pop true
- }
- ifelse
- } {
- false
- } ifelse
- f closefile end end
-} bind def
-
-% Load a font file that might be a TrueType font.
-
-/tt_tag_dict << <00010000> 0 (true) 0 (typ1) 0 (ttcf) 0 >> readonly def
-
-% <file> .loadfontfile -
-/.loadnonttfontfile /.loadfontfile load def
-/.loadfontfile {
- dup (1234) .peekstring { //tt_tag_dict exch known } { //false } ifelse {
- % If this is a font at all, it's a TrueType font.
- .loadttfont pop
- } {
- % Not a TrueType font.
- .loadnonttfontfile
- } ifelse
-} bind def
-
-currentdict /tt_tag_dict .undef
-
-% ---------------- Automatic Type 42 generation ---------------- %
-
-% Load a TrueType font from a file as a Type 42 PostScript font.
-% The thing that makes this really messy is the handling of encodings.
-% There are 2 interacting tables that affect the encoding:
-% 'cmap' provides multiple maps from character codes to glyph indices
-% 'post' maps glyph indices to glyph names (if present)
-% What we need to get out of this is:
-% Encoding mapping character codes to glyph names
-% (the composition of cmap and post)
-% CharStrings mapping glyph names to glyph indices
-% (the inverse of post)
-% If the post table is missing, we have to take a guess based on the cmap
-% table.
-
-/.loadttfontdict 50 dict dup begin
-
-/orgXUID AladdinEnterprisesXUID def
-/maxstring 32764 def % half the maximum length of a PostScript string,
- % must be a multiple of 4 (for hmtx / loca / vmtx)
-
-/.invert_encoding % <array> invert_encoding <dict>
-{ dup 256 dict exch
- 0 exch 1 exch length 1 sub { % [] <> i
- dup 3 index exch get % [] <> i v
- dup /.notdef ne {
- exch 2 index 2 index .knownget {
- dup type /arraytype eq {
- [ exch aload pop counttomark 2 add -1 roll ]
- } {
- exch 2 array astore
- } ifelse
- } if 2 index 3 1 roll put
- } {
- pop pop
- } ifelse
- } for
- exch pop
-} bind def
-
-% Make /MacRomanEncodingForTrueType including additional
-% characters in Mac OS Roman encoding, which is missing
-% in /MacRomanEncoding. See PDF spec 1.7, p. 431 or
-% "Inside Macintosh: Text" 1-55, Figure 1-36.
-% This is useful to exploit the glyphs via Apple Roman
-% TrueType cmap subtable, but not appropriate for information
-% interchange.
-
-/MacRomanEncodingForTrueType
- /MacRomanEncoding .findencoding
- dup length array copy
- <<
- /notequal 173
- /infinity 176
- /lessequal 178
- /greaterequal 179
- /partialdiff 182
- /summation 183
- /product 184
- /pi 185
- /integral 186
- /Omega 189
- /radical 195
- /approxequal 197
- /Delta 198
- /lozenge 215
- /Euro 219
- /apple 240
- >> {
- TTFDEBUG { (Extend MacRomanEncodingForTrueType for TrueType: ) =only } if
-
- % check /.notdef to avoid overwriting
- 2 index 1 index get dup /.notdef eq {
- TTFDEBUG { (insert /) =only 2 index =only ( @ ) =only 1 index == } if
- pop
- exch 2 index 3 1 roll put
- } {
- TTFDEBUG { (cannot insert /) =only 2 index =only ( @ ) =only 1 index =only ( used for ) =only dup == } if
- pop
- pop pop
- } ifelse
- } forall
- aload pop
- 256 packedarray
- 5 1 index .registerencoding
-.defineencoding
-
-% Define the Macintosh standard mapping from characters to glyph indices.
-/MacRomanEncoding dup .findencoding def
-/MacGlyphEncoding dup .findencoding def
-/MacRomanEncodingForTrueType dup .findencoding def
-
-% Invert the MacRomanEncoding.
-/.romanmacdict MacRomanEncodingForTrueType .invert_encoding def
-/.latin1isodict ISOLatin1Encoding .invert_encoding def
-
-% Define remapping for misnamed glyphs in TrueType 'post' tables.
-% There are probably a lot more than this!
-% Also see /postalias table below.
-/postremap mark
- /Eoverdot /Edotaccent
- /eoverdot /edotaccent
-.dicttomark readonly def
-
-% Array used for fast pre-filling of cmap array
-/.array1024z [ 1024 { 0 } repeat ] def
-
-% ---- Utilities ---- %
-
-% Define a serial number for creating unique XUIDs for TrueType fonts.
-% We used to use the checkSumAdjustment value from the font, but this is
-% not reliable, since some fonts don't set it correctly.
-% Note that we must do this in a string to make it immune to save/restore.
-/xuidstring <80000000> def
-/curxuid { % - curxuid <int>
- 0 xuidstring { exch 8 bitshift exch add } forall
-} bind def
-/nextxuid { % - nextxuid -
- 3 -1 0 {
- xuidstring 1 index 2 copy get dup 255 ne {
- 1 add put pop exit
- } if pop 0 put pop
- } for
-} bind def
-
-% <string> <index> getu16 <integer>
-/getu16 {
- 2 copy get 8 bitshift 3 1 roll 1 add get add
-} bind def
-
-% <string> <index> gets16 <integer>
-/gets16 {
- getu16 16#8000 xor 16#8000 sub
-} bind def
-
-% <string> <index> getu32 <integer>
-/getu32 {
- 2 copy getu16 16 bitshift 3 1 roll 2 add getu16 add
-} bind def
-
-% <string> <index> gets32 <integer>
-/gets32 {
- 2 copy gets16 16 bitshift 3 1 roll 2 add getu16 add
-} bind def
-
-% <string|array> <index> getu16 <integer>
-/getu16a {
- 2 getinterval_from_stringarray 0 getu16
-} bind def
-
-% <string|array> <index> gets16 <integer>
-/gets16a {
- 2 getinterval_from_stringarray 0 gets16
-} bind def
-
-% <string|array> <index> getu32a <integer>
-/getu32a {
- 4 getinterval_from_stringarray 0 getu32
-} bind def
-
-% <string|array> <index> gets32a <integer>
-/gets32a {
- 4 getinterval_from_stringarray 0 gets32
-} bind def
-
-16#ffffffff 0 gt { % 64-bit sign extension
- { /curxuid /gets32 /gets32a} {
- mark 1 index load aload pop { 16#80000000 xor 16#80000000 sub } aload pop
- .packtomark cvx def
- } bind forall
-} if
-
-% <string> <index> <integer> putu16 -
-/putu16 {
- 3 copy -8 bitshift put
- exch 1 add exch 16#ff and put
-} bind def
-
-% <string> <index> <integer> putu32 -
-/putu32 {
- 3 copy -16 bitshift putu16
- exch 2 add exch 16#ffff and putu16
-} bind def
-
-% <nametable> <nameid> findname <string> true
-% <nametable> <nameid> findname false
-/findname {
- TTFDEBUG { (findname: ) print dup =only } if
- false 3 1 roll
- 1 index length 0 gt { % check for zero length name table
- 0 1 3 index 2 getu16 1 sub {
- % Stack: false table id index
- 12 mul 6 add 2 index exch 12 getinterval
- dup 6 getu16 2 index eq {
- % We found the name we want.
- exch pop
- % Stack: false table record
- dup 10 getu16 2 index 4 getu16 add
- 1 index 8 getu16 4 -1 roll 3 1 roll
- 3 copy add 1 index length
- le {
- pop
- getinterval exch
- % Stack: false string record
- % Check for 8- vs. 16-bit characters.
- is2byte { true } { dup is2byte2 } ifelse { string2to1 } if true null 4 -1 roll exit
- } {
- pop pop pop pop
- false
- exit
- } ifelse
- } if pop
- } for
- } if
- pop pop
- TTFDEBUG {
- dup { ( = ) print 1 index == } { ( not found) = } ifelse
- } if
-} bind def
-
-% <namerecord> is2byte <bool>
-/is2byte {
- dup 0 getu16 {
- { pop true } % Apple Unicode
- { pop false } % Macintosh Script manager
- { 1 getu16 1 eq } % ISO
- { 1 getu16 1 eq } % Microsoft
- } exch get exec
-} bind def
-
-% <string> is2byte2 <bool>
-/is2byte2 {
- dup length
- dup 2 mod 0 ne {
- pop pop false
- } { % s l
- true exch % s b l
- 1 sub 0 exch 2 exch {
- 2 index exch get 0 ne {
- pop false exit
- } if
- } for
- exch pop
- } ifelse
-} bind def
-
-% <string2> string2to1 <string>
-/string2to1 {
- dup length 2 idiv string dup
- 0 1 3 index length 1 sub {
- 3 index 1 index 2 mul 1 add get put dup
- } for pop exch pop
-} bind def
-
-% Each procedure in this dictionary is called as follows:
-% <encodingtable> proc <glypharray>
-/cmapformats mark
- 0 { % Apple standard 1-to-1 mapping.
- 6 256 getinterval_from_stringarray { } forall 256 packedarray
- } bind
- 2 { % Apple 16bit CJK (ShiftJIS etc)
-
- % /sHK_sz subHeaderKey_size % 1 * uint16
- % /sH_sz subHeader_size % 4 * uint16
- % /sH_len subHeader_length
- % /cmapf2_tblen total table length
- % /cmapf2_lang language code (not used)
- % /sHKs subHeaderKeys
-
- /sHK_sz 2 def
- /sH_sz 8 def
- dup 2 getu16a /cmapf2_tblen exch def
-
- dup 4 getu16a /cmapf2_lang exch def
-
- dup 6 256 sHK_sz mul getinterval_from_stringarray /sHKs exch def
-
- 0 % initialization value for /sH_len
- 0 1 255 {
- sHKs exch
- 2 mul getu16
- 1 index % get current max
- 1 index % get current subHeaderKey
- lt {exch} if pop
- } for
- /sH_len exch def
-
- dup 6 256 sHK_sz mul add
- cmapf2_tblen 1 index sub getinterval_from_stringarray
- /sH_gIA exch def
-
- /cmapf2_glyph_array 65535 array def
-
- /.cmapf2_putGID {
- /cmapf2_ch cmapf2_ch_hi 8 bitshift cmapf2_ch_lo add def
- firstCode cmapf2_ch_lo le
- cmapf2_ch_lo firstCode entryCount add lt
- and { % true: j is inside
- sH_offset idRangeOffset add % offset to gI
- cmapf2_ch_lo firstCode sub 2 mul % rel. pos. in range
- add 6 add % offset in sH_gIA
- sH_gIA exch getu16
- dup 0 gt { %
- idDelta add
- cmapf2_glyph_array exch cmapf2_ch exch put
- } {
- pop
- % cmapf2_glyph_array cmapf2_ch 0 put
- } ifelse
- } { % false: j is outside
- % cmapf2_glyph_array cmapf2_ch 0 put
- } ifelse
- } def
-
- 16#00 1 16#ff { % hi_byte scan
- /cmapf2_ch_hi exch def
- sHKs cmapf2_ch_hi sHK_sz mul getu16
- /sH_offset exch def
- sH_gIA sH_offset sH_sz getinterval
- dup 0 getu16 /firstCode exch def
- dup 2 getu16 /entryCount exch def
- dup 4 gets16 /idDelta exch def
- dup 6 getu16 /idRangeOffset exch def
- pop
- sH_offset 0 eq {
- /cmapf2_ch_lo cmapf2_ch_hi def
- /cmapf2_ch_hi 0 def
- .cmapf2_putGID
- } {
- 16#00 1 16#ff { % lo_byte scan
- /cmapf2_ch_lo exch def
- .cmapf2_putGID
- } for
- } ifelse
- } for
- pop
- 0 1 cmapf2_glyph_array length 1 sub { % rewrite null -> 0.
- dup cmapf2_glyph_array exch get
- null eq { cmapf2_glyph_array exch 0 put } {pop} ifelse
- } for
- cmapf2_glyph_array
- } bind
- 4 { % Microsoft/Adobe segmented mapping.
- /etab exch def
- /nseg2 etab 6 getu16 def
- 14 /endc etab 2 index nseg2 getinterval_from_stringarray 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_from_stringarray def
- nseg2 add /iddelta etab 2 index nseg2 getinterval_from_stringarray def
- nseg2 add /idroff etab 2 index nseg2 getinterval_from_stringarray def
- % The following hack allows us to properly handle
- % idiosyncratic fonts that start at 0xf000:
- pop
- /firstcode startc 0 getu16 16#ff00 and dup 16#f000 ne { pop 0 } if def
- /putglyph {
- glyphs code 3 -1 roll put /code code 1 add def
- } bind def
- % Do a first pass to compute the size of the glyphs array.
- /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
- numcodes scode firstcode sub
- % Hack for fonts that have only 0x0000 and 0xf000 ranges
- %dup 16#e000 ge { 255 and } if
- % the previous line is obstructive to CJK fonts, so it was removed
- exch sub 0 .max ecode scode sub 1 add add
- exch 1 index add exch
- numcodes add /numcodes exch def
- } for array def
- % prefill the array with 0's faster than a { 0 putglyph } repeat
- glyphs length 1024 ge {
- .array1024z 0 1024 glyphs length 1023 sub { glyphs exch 2 index putinterval } for
- glyphs dup length 1024 sub 3 -1 roll
- putinterval
- } {
- 0 1 glyphs length 1 sub { glyphs exch 0 put } for
- } ifelse
- % Now fill in the array.
- /numcodes 0 def /code 0 def
- 0 2 nseg2 3 sub {
- /i2 exch def
- /scode startc i2 getu16 def
- /ecode endc i2 getu16 def
- numcodes scode firstcode sub
- % Hack for fonts that have only 0x0000 and 0xf000 ranges
- %dup 16#e000 ge { 255 and } if
- % the previous line is obstructive to CJK fonts, so it was removed
- exch sub 0 .max dup /code exch code exch add def
- ecode scode sub 1 add add numcodes add /numcodes exch def
- /delta iddelta i2 gets16 def
- TTFDEBUG {
- (scode=) print scode =only
- ( ecode=) print ecode =only
- ( delta=) print delta =only
- ( droff=) print idroff i2 getu16 =
- } if
- idroff i2 getu16 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 getu16a
- dup 0 ne { delta add 65535 and } if putglyph
- } for
- } ifelse
- } for glyphs /glyphs null def % for GC
- } bind
- 6 { % Single interval lookup.
- dup 6 getu16a /firstcode exch def
- dup 8 getu16a /ng exch def
- firstcode ng add array
- % Stack: tab array
- % Fill elements 0 .. firstcode-1 with 0
- 0 1 firstcode 1 sub { 2 copy 0 put pop } for
- dup firstcode ng getinterval
- % Stack: tab array subarray
- % Fill elements firstcode .. firstcode+nvalue-1 with glyph values
- 0 1 ng 1 sub {
- dup 2 mul 10 add 4 index exch getu16a 3 copy put pop pop
- } for pop exch pop
- } bind
-.dicttomark readonly def % cmapformats
-
-% <cmaptab> cmaparray <glypharray>
-/cmaparray {
- dup 0 getu16a cmapformats exch .knownget {
- TTFDEBUG {
- (cmap: format ) print 1 index 0 getu16a = flush
- } if exec
- } {
- (Can't handle format ) print 0 getu16a = flush
- 0 1 255 { } for 256 packedarray
- } ifelse
- TTFDEBUG {
- (cmap: length=) print dup length = dup ==
- } if
-} bind def
-
-/get_from_stringarray % <array|string> <offset> get_from_stringarray <int>
-{ 1 index type /stringtype eq {
- get
- } {
- exch { % o ()
- 2 copy length ge {
- length sub
- } {
- exch get exit
- } ifelse
- } forall
- } ifelse
-} bind def
-
-/getinterval_from_stringarray % <array|string> <offset> <length> getinterval_from_stringarray <string>
-{ % May allocate a string in VM.
- 2 index type /stringtype eq {
- getinterval
- } {
- string exch 0 % [] s o p
- 4 3 roll { % s o p Si
- dup length % s o p Si lSi
- dup 4 index lt {
- 3 index exch sub % s o p Si o'
- exch pop 3 1 roll exch pop % s o' p
- } { % s o p Si lSi
- dup 3 1 roll % s o p lSi Si lSi
- 4 index sub % s o p lSi Si lSi-o
- 5 index length 4 index sub % s o p lSi Si lSi-o ls-p
- 2 copy gt { exch } if pop % s o p lSi Si minl
- dup 3 1 roll % s o p lSi minl Si minl
- 5 index exch getinterval % s o p lSi minl from
- 5 index 4 index 3 index % s o p lSi minl from s p minl
- getinterval % s o p lSi minl from to
- copy pop % s o p lSi minl
- exch pop add exch pop 0 exch % s 0 p'
- dup 3 index length ge { exit } if
- } ifelse
- } forall
- pop pop % s
- } ifelse
-} bind def
-
-/string_array_size % <array|string> string_array_size <int>
-{ dup type /stringtype eq {
- length
- } {
- 0 exch { length add } forall
- } ifelse
-} bind def
-
-% Each procedure in this dictionary is called as follows:
-% posttable <<proc>> glyphencoding
-/postformats mark
- 16#00010000 { % 258 standard Macintosh glyphs.
- pop MacGlyphEncoding
- }
- 16#00020000 { % Detailed map, required by Microsoft fonts.
- dup dup type /arraytype eq { 0 get } if length 36 lt {
- TTFDEBUG { (post format 2.0 invalid.) = flush } if
- pop [ ]
- } {
- /postglyphs exch def
- /post_first postglyphs dup type /arraytype eq { 0 get } if def
- post_first 32 getu16 /numglyphs exch def
- /glyphnames numglyphs 2 mul 34 add def
- % Build names array in the order they occur in the 'post' table
- /postpos glyphnames def
- /total_length postglyphs //string_array_size exec def
- numglyphs array 0 1 numglyphs 1 sub {
- postpos total_length ge { pop exit } if
- % No name available, /postnames will be defined as an empty
- % array and the glyph won't get a name attached.
- postglyphs postpos //get_from_stringarray exec
- postglyphs postpos 1 add 2 index //getinterval_from_stringarray exec cvn
- exch postpos add 1 add /postpos exch def
- 2 index 3 1 roll
- put
- } for
- /postnames exch def
-
- % Some TrueType fonts converted by "Windows Type 1 Installer" have
- % problematic post table including MacGlyphEncoding entries which
- % should be omitted. Such extra entries in the beginning of glyphName
- % array make /Encoding broken. If we find populary predefined
- % ISOLatin1Encoding glyph name in the post table, empty encoding is
- % returned. Some TrueType fonts for Microsoft Windows redefines
- % MacGlyphEncoding glyph name out of predefined range). To permit
- % such fonts, ISOLatin1Encoding is used to find broken post. Bug 689495.
- /.broken_post //false def
- tabdict /name .knownget {
- (Windows Type 1 Installer V1.0) search {
- pop pop pop
- .latin1isodict postnames {
- dup //null ne
- % dup /.notdef ne and
- {
- 2 copy known {
- TTFDEBUG { (ignore post table that redefines ISOLatin1Encoding glyph name ) print dup == flush } if
- /.broken_post //true def
- pop exit
- } if
- } if
- pop
- } forall
- pop
- } {
- pop
- } ifelse
- } if
-
- numglyphs array 0 1 numglyphs 1 sub {
- dup 2 mul 34 add postglyphs exch 2 //getinterval_from_stringarray exec
- dup 0 get 8 bitshift exch 1 get add dup 258 lt {
- MacGlyphEncoding exch get
- } {
- dup 32768 ge {
- % According to the published TrueType spec, such values are
- % "reserved for future use", but at least some PDF files
- % produced by the Adobe PDF library contain entries with a
- % value of 16#ffff.
- pop /.notdef
- } {
- % Get the name for this glyph
- 258 sub dup postnames length ge {
- TTFDEBUG { ( *** warning: glyph index past end of 'post' table) = flush } if
- pop
- exit
- } if
- postnames exch get
- % At least some of Microsoft's TrueType fonts use incorrect
- % (Adobe-incompatible) names for some glyphs.
- % Correct for this here.
- postremap 1 index .knownget { exch pop } if
- } ifelse
- } ifelse
- 2 index 3 1 roll put
- } for
-
- .broken_post {
- pop
- 0 1 postnames length 1 sub {
- postnames 1 index get null eq {
- postnames 1 index /.notdef put
- } if
- pop
- } for
-
- [ postnames aload length 1 roll ]
- } if
- }
- ifelse
- } bind
- 16#00030000 { % No map.
- pop [ ]
- } bind
-.dicttomark readonly def % postformats
-
-/call.readtable
-{ .readtable
-} bind def
-/call.readbigtable
-{ .readbigtable
-} bind def
-
-% Each procedure in this dictionary is called as follows:
-% <file> <length> -proc- <string|array_of_strings>
-% Note that each table must have an even length, because of a strange
-% Adobe requirement that each sfnts entry have even length.
-/readtables mark
- % Ordinary tables
- (head) //call.readtable
- (hhea) 1 index
- (maxp) 1 index
- (name) 1 index
- (OS/2) 1 index
- (post) //call.readbigtable
- (vhea) //call.readtable
- % Big tables
- (cmap) //call.readbigtable
- (glyf) 1 index
- (loca) 1 index
- (hmtx) 1 index
- (vmtx) 1 index
- % Tables only needed for embedding in PDF files
- (cvt ) //call.readtable
- (fpgm) 1 index
- (prep) 1 index
-.dicttomark
-% Normally there would be a 'readonly' here, but the ttf2pf utility wants
-% to include the 'kern' table as well, so we leave the readtables dictionary
-% writable.
-def % readtables
-
-/readtables_stripped readtables dup length dict copy
-dup (loca) { .skiptable } put
-dup (glyf) { .skiptable } put
-def
-
-% Read a table as a single string.
-% <file> <length> .skiptable <string>
-/.skiptable {
- pop pop ()
-} bind def
-
-% Read a table as a single string.
-% <file> <length> .readtable <string>
-/.readtable {
- dup dup 1 and add string
- % Stack: f len str
- dup 0 4 -1 roll getinterval
- % Stack: f str str1
- % Because of the absurd PostScript specification that gives an
- % error for reading into an empty string, we have to check for
- % this explicitly here.
- 3 -1 roll exch
- dup () ne { readstring } if pop pop
-} bind def
-
-% Read a big table (one that may exceed 64K).
-% <file> <length> .readbigtable <string[s]>
-/.readbigtable {
- dup 65400 lt {
- .readtable
- } {
- currentuserparams /VMReclaim get -2 vmreclaim
- [ 4 2 roll {
- % Stack: mark ... f left
- dup maxstring le { exit } if
- 1 index maxstring string readstring pop 3 1 roll maxstring sub
- } loop .readtable ]
- exch vmreclaim
- } ifelse
-} bind def
-
-end readonly def % .loadttfontdict
-
-% <tab> .printtab -
-/.printtab {
- dup 0 4 getinterval print ( ) print
- dup 8 getu32 =only ( ) print
- 12 getu32 =
-} bind def
-
-% <file> <bool> <SubfontID> .loadttfonttables -
-% Pushes .loadttfontdict & scratch dict on d-stack.
-% Defines f, offsets, tables, tabdict, tabs.
-% Skips loca and glyf if <bool> is true.
-/.loadttfonttables {
- .loadttfontdict begin
- 40 dict begin
- /SubfontID exch def
- /load_stripped exch def
- /f exch def
- /offsets f 12 string readstring pop def
- load_stripped { readtables_stripped } { readtables } ifelse /readtables_ exch def
- offsets 0 4 getinterval (ttcf) eq {
- % We need to handle TT collections with disk fonts only.
- % Therefore the file is a disk file and it can be positioned.
- offsets 8 getu32 /num_fonts exch def
- SubfontID num_fonts ge {
- QUIET not { (True Type collection contains insufficient fonts.) = } if
- /.loadttfonttables cvx /invalidfont signalerror
- } if
- SubfontID 4 mul 12 add f exch setfileposition
- f 4 string readstring pop 0
- getu32 /ttc_offset exch def
- f ttc_offset setfileposition
- /offsets f 12 string readstring pop def
- } {
- SubfontID 0 gt {
- QUIET not { (SubfontID > 0 with a True Type file which is not a collection.) = } if
- /.loadttfonttables cvx /invalidfont signalerror
- } if
- /ttc_offset 0 def
- } ifelse
- /tables f offsets 4 getu16 16 mul string readstring pop def
- /tabdict tables length 16 idiv dict def
- % tabs = tables we want to keep, sorted by file position.
- /tabs [ 0 16 tables length 1 sub {
- tables exch 16 getinterval
- TTFDEBUG { dup .printtab } if
- dup 0 4 getinterval readtables_ 1 index known {
- % put all 0 length tables at 0 to avoid overlap
- 1 index 12 getu32 0 eq { 1 index 8 0 putu32 } if
- tabdict exch 2 index put
- } {
- pop pop
- } ifelse
- } for ] {
- exch 8 getu32 exch 8 getu32 lt
- } .sort def
- % In certain malformed TrueType fonts, tables overlap.
- % Truncate tables if necessary.
- 0 1 tabs length 2 sub {
- dup tabs exch get exch 1 add tabs exch get
- 1 index 8 getu32 2 index 12 getu32 add
- 1 index 8 getu32 gt {
- (**** Warning: ) print 1 index 0 4 getinterval print
- ( overlaps ) print dup 0 4 getinterval print
- (, truncating.) = flush
- dup 8 getu32 2 index 8 getu32 sub
- 2 index 12 3 -1 roll putu32
- } if pop pop
- } for
-} bind def
-
-/.file_table_pos_names
-mark
-/glyf 0
-/loca 0
-.dicttomark readonly def
-
-% - .readttdata -
-% Read data. Updates offsets, tabs; stores data in tabdict.
-/.readttdata {
- /file_table_pos 10 dict def
- /fpos offsets length tables length add ttc_offset add def
- /sfpos offsets length tabs length 16 mul add def
- offsets 4 tabs length putu16
- tabs {
- dup 0 4 getinterval /tname exch def
- dup 8 getu32 /tpos exch def
- dup 12 getu32 /tlen exch def
- load_stripped //.file_table_pos_names tname known and {
- pop
- file_table_pos tname [tpos tlen] put
- tabdict tname () put
- } {
- 8 sfpos putu32
- % Skip data between the end of the previous table and
- % the beginning of this one, if any.
- tpos fpos gt {
- load_stripped {
- % 'setfileposition' is faster for skipping a big data.
- f tpos setfileposition
- } {
- f tpos fpos sub () /SubFileDecode filter dup flushfile closefile
- /fpos tpos def
- } ifelse
- } if
- f tlen readtables_ tname get exec
- tabdict tname 3 -1 roll put
- % Round up the table length to an even value.
- /sfpos sfpos tlen dup 1 and add add def
- } ifelse
- /fpos fpos tlen add def
- } forall
-} bind def
-
-% Find the string in a list of strings that includes a given index.
-% <strings> <index> .findseg <string> <index'>
-/.findseg {
- exch {
- dup length 2 index gt { exch exit } if
- length sub
- } forall
-} bind def
-
-% - .makesfnts -
-% Defines checksum, getloca, head, locatable, numloca, post, sfnts, upem
-% Note that the 'loca' table may be out of order. This is handled when
-% needed in .dividesfnts
-/.makesfnts {
- .readttdata
- /head tabdict /head get def
- /post tabdict /post .knownget {
- dup 0 get /post_first_part exch def
- } {
- null
- } ifelse def
- load_stripped not {
- /locatable tabdict /loca get def
- /numloca
- locatable dup type /stringtype eq
- { length }
- { 0 exch { length add } forall }
- ifelse % no def yet
- locatable type /stringtype eq {
- /.indexloca {} def
- } {
- /.indexloca /.findseg load def
- } ifelse
- head 50 getu16 0 ne {
- /getloca {
- 2 bitshift locatable exch .indexloca getu32
- } def
- 4 idiv 1 sub
- } {
- /getloca {
- dup add locatable exch .indexloca getu16 dup add
- } def
- 2 idiv 1 sub
- } ifelse def % numloca
- % If necessary, re-partition the glyfs.
- tabdict /glyf get dup type /stringtype ne {
- .dividesfnts tabdict /glyf 3 -1 roll put
- } {
- pop
- } ifelse
- } {
- % We did not load loca, take the number of glyphs from maxp.
- /numloca tabdict /maxp get 4 getu16 def
- } ifelse
- /sfnts [
- offsets tabs { concatstrings } forall
- tabs {
- 0 4 getinterval tabdict exch get
- dup type /stringtype ne { aload pop } if
- } forall
- ] def
-} bind def
-
-% <glyfs> .dividesfnts <glyfs'>
-/.dividesfnts {
- /glyfs exch def
- /len1 0 glyfs { length add } forall def
- % Determine where to split the glyfs by scanning the sorted locatable
- % The very last entry in loca may be bogus.
- % Note that some loca entries may be odd, but we can only
- % split at even positions.
- %
- % Construct splitarray, the array of final lengths of
- % the sfnts entries covering the glyfs (i.e., all but
- % the first and last sfnts entries).
- /prevsplit 0 def
- /prevboundary 0 def
- % sort the locatable in case it is out of order
- % Note the 'loca' table remains unchanged
- /needsort false def
- numloca array % the array of 'loca' entries (may be out of order)
- -1 % initial values for in order check
- 0 1 numloca 1 sub {
- dup getloca dup
- 4 -1 roll lt { /needsort true def } if
- 3 copy put exch pop
- } for pop % discard inorder check value
- needsort {
- { lt } bind .sort % stack: locatable_array
- } if
- /splitarray [
- 3 -1 roll 0 1 numloca 1 sub {
- % stack: /splitarray -mark- { splitlen splitlen ... } locatable_array index
- 1 index exch get dup prevsplit maxstring add gt {
- prevboundary prevsplit sub exch
- /prevsplit prevboundary def
- } if
- dup 1 and 0 eq { /prevboundary exch def } { pop } ifelse
- dup type /arraytype ne { exch } if % keep locatable_array on top
- } for
- len1 prevsplit sub
- exch pop % discard locatable_array
- ] def
- currentuserparams /VMReclaim get -2 vmreclaim
- [
- % Re-split the sfnts glyfs strings according to splitarray.
- % We do this by iterating over the final segments defined
- % by splitarray, and constructing them from pieces of the
- % current glyfs strings. We recycle the current strings
- % when possible, to avoid stressing the allocator.
- /sfnt_idx 0 def
- /strpos 0 def
- /avail () def
- splitarray {
- /seglen exch def
- /segpos 0 def
- avail length seglen ge
- { avail 0 seglen getinterval /avail () def } { seglen string }
- ifelse
- {
- /str glyfs sfnt_idx get def
- /strlen str length def
- /strleft strlen strpos sub def
- seglen segpos sub strleft lt { exit } if
- % Copy the (rest of the) string into the new segment.
- % We know strleft <= segleft.
- dup segpos str strpos strleft getinterval putinterval
- /segpos segpos strleft add def
- /avail str def
- /sfnt_idx sfnt_idx 1 add def
- /strpos 0 def
- segpos seglen eq { exit } if
- } loop
- % Fill up the segment with an initial piece of the next
- % existing glyfs string. We know strleft > segleft.
- /segleft seglen segpos sub def
- dup segpos str strpos segleft getinterval putinterval
- /strpos strpos segleft add def
- } forall
- ]
- exch vmreclaim
-} bind def
-
-/first_post_string % - first_post_string <string>
-{
- post dup type /arraytype eq { 0 get } if
-} bind def
-
-% - .getpost -
-% Uses post, defines glyphencoding
-/.getpost {
- /glyphencoding post null eq {
- TTFDEBUG { (post missing) = flush } if [ ]
- } {
- postformats first_post_string 0 getu32 .knownget {
- TTFDEBUG {
- (post: format ) print
- first_post_string
- dup 0 getu16 =only (,) print 2 getu16 = flush
- } if
- post exch exec
- } {
- TTFDEBUG { (post: unknown format ) print post 0 getu32 = flush } if [ ]
- } ifelse
- } ifelse
- TTFDEBUG { (post=) print dup == } if
- def
-} bind def
-
-% - .ttkeys <key> <value> ...
-/.ttkeys {
- count /ttkeycount exch def
- /upem head 18 getu16 def
- /FontMatrix matrix
- /FontBBox [ 36 2 42 { head exch gets16 upem div } for ]
- nextxuid
- tabdict /name .knownget {
- % Find the names from the 'name' table.
- /names exch def
- /FontName names 6 findname not { names 4 findname not { curxuid 16#ffffffff and 16 32 string cvrs } if } if
- /fontname 1 index def
- /FontInfo mark
- names 0 findname { /Notice exch } if
- names 1 findname { /FamilyName exch } if
- names 4 findname { /FullName exch } if
- names 5 findname { /Version exch } if
- } {
- % No name table, fabricate a FontName.
- /FontName curxuid 16#ffffffff and 16 32 string cvrs
- /fontname 1 index def
- /FontInfo mark
- } ifelse
- % Stack: ... /FontInfo mark key1 value1 ...
- post null ne {
- /ItalicAngle first_post_string 4 gets32 65536.0 div
- /isFixedPitch first_post_string 12 getu32 0 ne
- /UnderlinePosition first_post_string 8 gets16 upem div
- /UnderlineThickness first_post_string 10 gets16 upem div
- } if
- counttomark 0 ne { .dicttomark } { pop pop } ifelse
- /XUID [orgXUID 42 curxuid]
- TTFDEBUG {
- tabs { .printtab } forall
- [ sfnts { length } forall ] ==
- count ttkeycount sub array astore dup { == } forall aload pop
- } if
- /sfnts sfnts
-} bind def
-
-% ---------------- Standard TrueType font loading ---------------- %
-
-% - .pickcmap_with_no_xlatmap -
-% Defines cmapsub, cmaptab
-/.pickcmap_with_no_xlatmap {
- tabdict /cmap get
- % The Apple cmap format is no help in determining the encoding.
- % Look for a Microsoft table. If we can't find one,
- % just use the first table, whatever it is.
- dup 4 8 getinterval_from_stringarray exch % () [] % the default
- 0 1 2 index 2 getu16a 1 sub { % () [] i
- 8 mul 4 add 1 index exch 8 getinterval_from_stringarray % () [] ()
- TTFDEBUG {
- (cmap: platform ) print dup 0 getu16 =only
- ( encoding ) print dup 2 getu16 = flush
- } if
- dup 0 getu16 3 eq { exch 3 -1 roll pop exit } if pop
- } for
- % Stack: subentry table
- /cmapsub 2 index def % () []
- exch 4 getu32 1 index string_array_size 1 index sub getinterval_from_stringarray
- /cmaptab exch def
-} bind def
-
-% - .pickcmap_with_xlatmap -
-% Defines cmapsub, cmaptab
-/.pickcmap_with_xlatmap {
- .xlatmap_dict /TrueType known not {
- (Emulating a CID font with a True Type file, ) print
- (the file gs/lib/xlatmap must contain /TrueType key.) =
- /.pickcmap_with_xlatmap cvx /configurationerror signalerror
- } if
- false
- .xlatmap_dict /TrueType get
- dup length 2 sub 0 exch 2 exch { % bool [] i
- 2 copy get % bool [] i ()
- (.) search { % bool [] i post match pre
- cvi exch pop exch cvi % bool [] i PlatID SpecID
- } {
- (gs/lib/xlatmap containg a record with an invalid (PlatformID.SpecificID)) =
- /.pickcmap_with_xlatmap cvx /configurationerror signalerror
- } ifelse
- TTFDEBUG {
- (Seeking a cmap for platform=) print 1 index =only ( encoding=) print dup =
- } if
- tabdict /cmap get % bool [] i PlatID SpecID (cmap)
- dup /cmaptab exch def % temporary
- 0 1 2 index 2 getu16a 1 sub { % bool [] i PlatID SpecID (cmap) j
- 8 mul 4 add 1 index exch 8
- getinterval_from_stringarray % bool [] i PlatID SpecID (cmap) (cmapsub)
- TTFDEBUG {
- (cmap: platform ) print dup 0 getu16 =only
- ( encoding ) print dup 2 getu16 = flush
- } if
- dup 0 getu16 4 index eq {
- dup 2 getu16 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 1 index getu16a % get cmap format
- 8 lt { % length for traditional 16bit format 0, 2, 4, 6
- cmaptab 1 index 2 add getu16a
- } { % length for advanced 32bit format 8, 10, 12
- cmaptab 1 index 4 add getu32a
- } ifelse % bool [] i PlatID SpecID (cmap) (cmapsub) p l
- cmaptab 3 1 roll getinterval_from_stringarray
- /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)
- 7 -1 roll pop true 7 1 roll % true [] i PlatID SpecID (cmap) (cmapsub)
- } if
- } if
- pop % true [] i PlatID SpecID (cmap)
- 5 index { exit } if
- } for % bool [] i PlatID SpecID (cmap)
- pop pop pop pop % bool []
- 1 index { exit } if
- } for % bool []
- pop % bool
- not {
- QUIET not { (True Type font doesn't contain a charset listed in gs/lib/xlatmap.) = } if
- /.pickcmap_with_xlatmap cvx /invalidfont signalerror
- } if %
-} bind def
-
-% - .pickcmap -
-% Defines cmapsub, cmaptab
-/.pickcmap {
- % Currently we use xlatmap only for emulation CIDFontType 2 with
- % a disk True Type font files, and use load_stripped
- % to check this regime. We would like to do so
- % while emulating a Type 42, but first the old code
- % about handling them to be changed
- % with adding a handling of a Decoding.
- % fixme : A correct way to fix this is to implenent
- % the Type 42 emulation with gs_fntem.ps .
- % Also note that PDF embedded fonts probably don't need a xlatmap -
- % see PDF spec, "Encodings for True Type fonts".
- load_stripped {
- //.pickcmap_with_xlatmap exec
- } {
- //.pickcmap_with_no_xlatmap exec
- } ifelse
-} bind def
-
-% <glyph> .nname <_name>
-/.nname {
- =string cvs (_) exch concatstrings cvn
-} bind def
-
-% Provide alternative backward-compatible names for new TTF glyphs.
-% This list was extracted from Adobe's Glyph List 2.0 and consists of
-% glyph names that map to the same Unicode value.
-% See: http://partners.adobe.com/asn/developer/typeforum/unicodegn.html
-/postalias mark
- /pi1 /pi /plusinus /plusminus
- /Acyrillic /afii10017 /Becyrillic /afii10018
- /Cdot /Cdotaccent /Checyrillic /afii10041
- /Dcroat /Dslash /Decyrillic /afii10021
- /Delta /increment /Djecyrillic /afii10051
- /Dzecyrillic /afii10054 /Dzhecyrillic /afii10145
- /Ecyrillic /afii10053 /Edot /Edotaccent
- /Efcyrillic /afii10038 /Elcyrillic /afii10029
- /Emcyrillic /afii10030 /Encyrillic /afii10031
- /Ercyrillic /afii10034 /Ereversedcyrillic /afii10047
- /Escyrillic /afii10035 /Euro /euro
- /Fitacyrillic /afii10147 /Gcedilla /Gcommaaccent
- /Gdot /Gdotaccent /Gecyrillic /afii10020
- /Gheupturncyrillic /afii10050 /Gjecyrillic /afii10052
- /H18533 /blackcircle /H18543 /blacksmallsquare
- /H18551 /whitesmallsquare /H22073 /whitesquare
- /Hardsigncyrillic /afii10044 /IAcyrillic /afii10049
- /IUcyrillic /afii10048 /Icyrillic /afii10055
- /Idot /Idotaccent /Iecyrillic /afii10022
- /Iicyrillic /afii10026 /Iishortcyrillic /afii10027
- /Iocyrillic /afii10023 /Izhitsacyrillic /afii10148
- /Jecyrillic /afii10057 /Kacyrillic /afii10028
- /Kcedilla /Kcommaaccent /Khacyrillic /afii10039
- /Kjecyrillic /afii10061 /Lcedilla /Lcommaaccent
- /Ldot /Ldotaccent /Ljecyrillic /afii10058
- /Ncedilla /Ncommaaccent /Njecyrillic /afii10059
- /Ocyrillic /afii10032 /Odblacute /Ohungarumlaut
- /Ohm /Omega /Oslashacute /Ostrokeacute
- /Pecyrillic /afii10033 /Rcedilla /Rcommaaccent
- /Shacyrillic /afii10042 /Shchacyrillic /afii10043
- /Softsigncyrillic /afii10046 /Tcedilla /Tcommaaccent
- /Tecyrillic /afii10036 /Tsecyrillic /afii10040
- /Tshecyrillic /afii10060 /Ucyrillic /afii10037
- /Udblacute /Uhungarumlaut /Upsilon1 /Upsilonhooksymbol
- /Ushortcyrillic /afii10062 /Vecyrillic /afii10019
- /Yatcyrillic /afii10146 /Yericyrillic /afii10045
- /Yicyrillic /afii10056 /Zdot /Zdotaccent
- /Zecyrillic /afii10025 /Zhecyrillic /afii10024
- /acutecmb /acutecomb /acyrillic /afii10065
- /afii00208 /horizontalbar /afii08941 /lira
- /afii10066 /becyrillic /afii10067 /vecyrillic
- /afii10068 /gecyrillic /afii10069 /decyrillic
- /afii10070 /iecyrillic /afii10071 /iocyrillic
- /afii10072 /zhecyrillic /afii10073 /zecyrillic
- /afii10074 /iicyrillic /afii10075 /iishortcyrillic
- /afii10076 /kacyrillic /afii10077 /elcyrillic
- /afii10078 /emcyrillic /afii10079 /encyrillic
- /afii10080 /ocyrillic /afii10081 /pecyrillic
- /afii10082 /ercyrillic /afii10083 /escyrillic
- /afii10084 /tecyrillic /afii10085 /ucyrillic
- /afii10086 /efcyrillic /afii10087 /khacyrillic
- /afii10088 /tsecyrillic /afii10089 /checyrillic
- /afii10090 /shacyrillic /afii10091 /shchacyrillic
- /afii10092 /hardsigncyrillic /afii10093 /yericyrillic
- /afii10094 /softsigncyrillic /afii10095 /ereversedcyrillic
- /afii10096 /iucyrillic /afii10097 /iacyrillic
- /afii10098 /gheupturncyrillic /afii10099 /djecyrillic
- /afii10100 /gjecyrillic /afii10101 /ecyrillic
- /afii10102 /dzecyrillic /afii10103 /icyrillic
- /afii10104 /yicyrillic /afii10105 /jecyrillic
- /afii10106 /ljecyrillic /afii10107 /njecyrillic
- /afii10108 /tshecyrillic /afii10109 /kjecyrillic
- /afii10110 /ushortcyrillic /afii10193 /dzhecyrillic
- /afii10194 /yatcyrillic /afii10195 /fitacyrillic
- /afii10196 /izhitsacyrillic /afii10846 /schwacyrillic
- /afii57381 /percentarabic /afii57388 /commaarabic
- /afii57392 /zeroarabic /afii57393 /onearabic
- /afii57394 /twoarabic /afii57395 /threearabic
- /afii57396 /fourarabic /afii57397 /fivearabic
- /afii57398 /sixarabic /afii57399 /sevenarabic
- /afii57400 /eightarabic /afii57401 /ninearabic
- /afii57403 /semicolonarabic /afii57407 /questionarabic
- /afii57409 /hamzaarabic /afii57410 /alefmaddaabovearabic
- /afii57411 /alefhamzaabovearabic /afii57412 /wawhamzaabovearabic
- /afii57413 /alefhamzabelowarabic /afii57414 /yehhamzaabovearabic
- /afii57415 /alefarabic /afii57416 /beharabic
- /afii57417 /tehmarbutaarabic /afii57418 /teharabic
- /afii57419 /theharabic /afii57420 /jeemarabic
- /afii57421 /haharabic /afii57422 /khaharabic
- /afii57423 /dalarabic /afii57424 /thalarabic
- /afii57425 /reharabic /afii57426 /zainarabic
- /afii57427 /seenarabic /afii57428 /sheenarabic
- /afii57429 /sadarabic /afii57430 /dadarabic
- /afii57431 /taharabic /afii57432 /zaharabic
- /afii57433 /ainarabic /afii57434 /ghainarabic
- /afii57440 /tatweelarabic /afii57441 /feharabic
- /afii57442 /qafarabic /afii57443 /kafarabic
- /afii57444 /lamarabic /afii57445 /meemarabic
- /afii57446 /noonarabic /afii57448 /wawarabic
- /afii57449 /alefmaksuraarabic /afii57450 /yeharabic
- /afii57451 /fathatanarabic /afii57452 /dammatanarabic
- /afii57453 /kasratanarabic /afii57454 /fathaarabic
- /afii57455 /dammaarabic /afii57456 /kasraarabic
- /afii57457 /shaddaarabic /afii57458 /sukunarabic
- /afii57470 /heharabic /afii57505 /veharabic
- /afii57506 /peharabic /afii57507 /tcheharabic
- /afii57508 /jeharabic /afii57509 /gafarabic
- /afii57511 /tteharabic /afii57512 /ddalarabic
- /afii57513 /rreharabic /afii57514 /noonghunnaarabic
- /afii57519 /yehbarreearabic /afii57636 /newsheqelsign
- /afii57645 /maqafhebrew /afii57658 /sofpasuqhebrew
- /afii57664 /alef /afii57665 /bet
- /afii57666 /gimel /afii57667 /dalet
- /afii57668 /he /afii57669 /vav
- /afii57670 /zayin /afii57671 /het
- /afii57672 /tet /afii57673 /yod
- /afii57674 /finalkaf /afii57675 /kaf
- /afii57676 /lamed /afii57677 /finalmem
- /afii57678 /mem /afii57679 /finalnun
- /afii57680 /nun /afii57681 /samekh
- /afii57682 /ayin /afii57683 /finalpe
- /afii57684 /pe /afii57685 /finaltsadi
- /afii57686 /tsadi /afii57687 /qof
- /afii57688 /resh /afii57689 /shin
- /afii57690 /tav /afii57694 /shinshindot
- /afii57695 /shinsindot /afii57700 /vavholam
- /afii57705 /doubleyodpatah /afii57716 /vavvavhebrew
- /afii57717 /vavyodhebrew /afii57718 /yodyodhebrew
- /afii57723 /vavdagesh /afii57793 /hiriq
- /afii57794 /tsere /afii57795 /segol
- /afii57796 /qubuts /afii57797 /qamats
- /afii57798 /patah /afii57799 /sheva
- /afii57800 /hatafpatah /afii57801 /hatafsegol
- /afii57802 /hatafqamats /afii57803 /sindothebrew
- /afii57804 /shindothebrew /afii57806 /holam
- /afii57807 /dagesh /afii57839 /siluqhebrew
- /afii57841 /rafe /afii57842 /paseqhebrew
- /afii57929 /apostrophemod /afii61248 /careof
- /afii61289 /lsquare /afii61352 /numero
- /afii61664 /zerowidthnonjoiner /afii63167 /asteriskarabic
- /afii64937 /commareversedmod /alefmaksurainitialarabic /yehinitialarabic
- /alefmaksuramedialarabic /yehmedialarabic /approximatelyequal /congruent
- /arrowdblboth /dblarrowleft /arrowdblleft /arrowleftdbl
- /arrowdblright /dblarrowright /arrowupdnbse /arrowupdownbase
- /bar /verticalbar /betdagesh /betdageshhebrew
- /blackdownpointingtriangle /triagdn /blackleftpointingpointer /triaglf
- /blackrectangle /filledrect /blackrightpointingpointer /triagrt
- /blacksmilingface /invsmileface /blacksquare /filledbox
- /blackuppointingtriangle /triagup /bulletinverse /invbullet
- /cdot /cdotaccent /circle /whitecircle
- /circlemultiply /timescircle /circleplus /pluscircle
- /club /clubsuitblack /colonmonetary /colonsign
- /compass /sun /daletdagesh /daletdageshhebrew
- /dargahebrew /dargalefthebrew /dbllowline /underscoredbl
- /dcroat /dmacron /decimalseparatorarabic /decimalseparatorpersian
- /dialytikatonos /dieresistonos /dkshade /shadedark
- /dotbelowcmb /dotbelowcomb /edot /edotaccent
- /eighthnotebeamed /musicalnotedbl /etnahtafoukhhebrew /etnahtahebrew
- /existential /thereexists /female /venus
- /finalkafdagesh /finalkafdageshhebrew /forall /universal
- /gcedilla /gcommaaccent /gdot /gdotaccent
- /gimeldagesh /gimeldageshhebrew /gradient /nabla
- /gravecmb /gravecomb /haaltonearabic /hehaltonearabic
- /heart /heartsuitblack /hedagesh /hedageshhebrew
- /hehfinalalttwoarabic /hehfinalarabic /hookabovecomb /hookcmb
- /ilde /tilde /integralbottom /integralbt
- /integraltop /integraltp /invcircle /whitecircleinverse
- /kafdagesh /kafdageshhebrew /kcedilla /kcommaaccent
- /lameddagesh /lameddageshhebrew /lcedilla /lcommaaccent
- /ldot /ldotaccent /logicalnotreversed /revlogicalnot
- /longs /slong /ltshade /shadelight
- /macron /overscore /mahapakhhebrew /mahapakhlefthebrew
- /male /mars /memdagesh /memdageshhebrew
- /merkhahebrew /merkhalefthebrew /merkhakefulahebrew /merkhakefulalefthebrew
- /middot /periodcentered /mu /mu1
- /munahhebrew /munahlefthebrew /napostrophe /quoterightn
- /nbspace /nonbreakingspace /ncedilla /ncommaaccent
- /notelement /notelementof /nundagesh /nundageshhebrew
- /odblacute /ohungarumlaut /omega1 /pisymbolgreek
- /openbullet /whitebullet /orthogonal /rightangle
- /oslashacute /ostrokeacute /pedagesh /pedageshhebrew
- /phi1 /phisymbolgreek /propersubset /subset
- /propersuperset /superset /qofdagesh /qofdageshhebrew
- /quoteleftreversed /quotereversed /rcedilla /rcommaaccent
- /reflexsubset /subsetorequal /reflexsuperset /supersetorequal
- /reviahebrew /reviamugrashhebrew /samekhdagesh /samekhdageshhebrew
- /sfthyphen /softhyphen /shade /shademedium
- /sheqel /sheqelhebrew /shindagesh /shindageshhebrew
- /shindageshshindot /shindageshshindothebrew /shindageshsindot /shindageshsindothebrew
- /sigma1 /sigmafinal /similar /tildeoperator
- /smileface /whitesmilingface /space /spacehackarabic
- /spade /spadesuitblack /tavdages /tavdagesh
- /tcedilla /tcommaaccent /tetdagesh /tetdageshhebrew
- /tevirhebrew /tevirlefthebrew /theta1 /thetasymbolgreek
- /thousandsseparatorarabic /thousandsseparatorpersian /tildecmb /tildecomb
- /tipehahebrew /tipehalefthebrew /tsadidagesh /tsadidageshhebrew
- /twodotenleader /twodotleader /udblacute /uhungarumlaut
- /yerahbenyomohebrew /yerahbenyomolefthebrew /yoddagesh /yoddageshhebrew
- /zayindagesh /zayindageshhebrew /zdot /zdotaccent
-.dicttomark readonly def
-
-% - .charkeys /CharStrings <charstrings> /Encoding <encoding>
-% Resets glyphencoding
-/.charkeys {
- TTFDEBUG {
- (glyphencoding: length=) print glyphencoding dup length = === flush
- } if
- % Hack: if there is no usable post table but the cmap uses
- % the Microsoft Unicode encoding, use ISOLatin1Encoding.
- % if 'post' presents, .charkeys computes (with dropping minor details) :
- % CharStrings = glyphencoding^-1
- % Encoding = cmap*glyphencoding
- % because 'post' maps glyph indices to glyph names.
- % Otherwise .charkeys must compute (with dropping same details) :
- % CharStrings = glyphencoding^-1 * cmap
- % Encoding = glyphencoding
- % because glyphencoding is stubbed with an encoding,
- % which maps char codes to glyph names.
- glyphencoding length 0 eq {
- /have_post false def
- cmapsub 0 4 getinterval <00030001> eq {
- PDFDEBUG { (No post but have cmap 3.1, so use ISOLatin1Encoding) = } if
- /glyphencoding ISOLatin1Encoding dup length array copy def
- } {
- PDFDEBUG { (No encoding info, use .GS_extended_SymbolEncoding) = } if
- /glyphencoding /.GS_extended_SymbolEncoding findencoding dup length array copy def
- } ifelse
- } {
- /have_post true def
- } ifelse
- % If necessary, fabricate additional glyphencoding entries
- % to cover all of loca
- glyphencoding length numloca lt {
- /glyphencoding numloca array
- glyphencoding length dup 1 sub 0 1 3 2 roll {
- dup glyphencoding exch get
- 3 index 3 1 roll put
- } for
- % /glyphencoding <newarray> <glyphencoding length>
- 1 numloca 1 sub {
- 1 index exch dup .nname put
- } for
- def
- } if
- /cmapa cmaptab cmaparray def
- % Some badly designed Chinese fonts have a post table
- % in which all glyphs other than 0 are named .null.
- % Use CharStrings to keep track of the reverse map from
- % names to glyphs, and don't let any name be used for
- % more than one glyph.
- /CharStrings glyphencoding dup length 1 add dict % +1 for .notdef
- 0 1 3 index length 1 sub {
- % Stack: glyphencoding dict index
- 2 index 1 index get
- have_post not {
- exch dup cmapa length lt {
- cmapa exch get
- } {
- pop 0 % a stub for a while. Must skip the entry.
- } ifelse
- exch
- } if
- 2 index 1 index known
- { % The same name maps to more than one glyph. Change the name.
- % No special treatment for /.notdef glyph. Bug 689408.
- pop dup .nname 3 index 2 index 2 index put
- 2 index exch 3 -1 roll put
- } {
- 2 index exch 3 -1 roll put % unique name
- } ifelse
- } for exch pop
- % If there is no .notdef entry, map it to glyph 0.
- dup /.notdef known not { dup /.notdef 0 put } if
- TTFDEBUG {
- (CharStrings:)= dup { exch =string cvs print ( ) print == } forall
- } if
- //postalias {
- % process pairs of names. If both names are known, do nothing. Otherwise
- % make the name that is not defined an alias for the one that does exist.
- % Stack: CharStrings(dict) /name1 /name2
- 2 index 2 index known 3 index 2 index known 1 index xor not {
- pop pop pop % both names known or neither known
- } {
- % Stack: CharStrings(dict) /name1 /name2 name1_known(bool)
- { exch } if % /name1 known -- we need it on top
- % Stack: CharStrings(dict) /alias_name /known_name
- TTFDEBUG { (setting alias: ) print 1 index ==only ( to be the same as glyph: ) print dup == } if
- 2 index exch get 2 index 3 1 roll put
- } ifelse
- } forall
- readonly
- /Encoding [
- have_post {
- cmapa dup length 256 gt { 0 256 getinterval } if
- { glyphencoding exch get } forall
- } {
- glyphencoding dup length 256 gt { 0 256 getinterval } if
- aload pop
- } ifelse
- counttomark 256 exch sub { /.notdef } repeat
- ]
- TTFDEBUG { (Encoding: ) print dup === flush } if
-} bind def
-
-currentdict /postalias undef
-
-% -mark- <key> <value> ... .definettfont <font>
-/.definettfont {
- /FontType 42
- /PaintType 0
- TTFDEBUG {
- (numloca=) print numloca =
- } if
- .dicttomark
- end end dup /FontName get exch definefont
-} bind def
-
-% <file> .loadttfont <type42font>
-/.loadttfont {
- TTFDEBUG { (.loadttfont) = } if
- //false 0 .loadttfonttables
- .makesfnts
- .getpost
- .pickcmap
- mark
- .charkeys
- .ttkeys
- .definettfont
-} bind def
-
-% ---------------- CIDFontType 2 font loading ---------------- %
-
-% Fill a string with sequential CIDs starting from the initial value.
-% <string> <value> .fill_identity_cmap <string>
-/.fill_identity_cmap { % () v
- 1 index length 2 sub % () v n-2
- 0 2 3 2 roll { % () v 0 2 n-1
- 3 copy exch % () v i () i v
- -8 bitshift % () v i () i v>>8
- put % () v i
- 3 copy 1 add % () v i () v i+1
- exch 255 and % () v i () i+1 v&255
- put % () v i
- pop 1 add % () v+1
- } for
- pop
-} bind def
-
-% -mark- <key> <value> ... .definettcidfont <font>
-/.definettcidfont {
- /CIDFontName fontname
- /CIDFontType 2
- /CIDSystemInfo mark
- /Registry (Adobe)
- /Ordering (Japan1) % adhoc
- /Supplement 0
- .dicttomark
- /CharStrings mark /.notdef 0 .dicttomark
- % The cmap isn't of any use even if it is present.
- % Just construct an identity CIDMap covering all the glyphs.
-
- /CIDCount numloca % Wrong if a CIDFontType2 embedded into PDF with a non-Identity CIDToGIDMap.
- % processCIDToGIDMap may replace.
- /CIDMap numloca maxstring le {
- % Use a single string.
- numloca 2 mul string 0 .fill_identity_cmap
- } {
- % We must use 2 strings.
- maxstring 2 mul string 0 .fill_identity_cmap
- numloca maxstring sub 2 mul string maxstring .fill_identity_cmap
- 2 array astore
- } ifelse
-
- /GDBytes 2
- .dicttomark
- end end dup /CIDFontName get exch /CIDFont defineresource
-} bind def
-
-% <file> .loadttcidfont <cidtype2font>
-/.loadttcidfont {
- //false 0 .loadttfonttables
- .makesfnts
- % CIDFontType2 fonts don't have a cmap: they are indexed by CID.
- mark
- .ttkeys
- .definettcidfont
-} bind def
-
-% <file> <SubfontID> .load_tt_font_stripped <font_data>
-% The font_data includes sfnts, NumGlyphs, TT_cmap, file_table_pos, Decoding.
-% CIDMap to be created later from TT_cmap.
-/.load_tt_font_stripped {
- //true exch .loadttfonttables
- .makesfnts
- .pickcmap
- mark
- .ttkeys
- /NumGlyphs numloca
- /TT_cmap cmaptab cmaparray
- /file_table_pos file_table_pos
- /Decoding Decoding
- .dicttomark
- end end
-} bind def
-
-% ---------------- PDF TrueType font loading ---------------- %
-
-% Strictly speaking, this code should be loaded only if we have a PDF
-% interpreter, but it's so closely tied to the rest of the code in this
-% file that we always include it.
-
-% <plat+enc> .findcmap <subtable> true
-% <plat+enc> .findcmap false
-/.findcmap {
- false exch tabdict /cmap get
- % Some fonts have multiple cmaps with the same platform and
- % encoding. Use the first one we find.
- 0 1 2 index 2 getu16a 1 sub {
- % Stack: false plat+enc cmap index
- 8 mul 4 add 1 index exch 8 getinterval_from_stringarray
- dup 0 4 getinterval 3 index eq {
- 4 getu32 1 index exch 1 index string_array_size 1 index sub getinterval_from_stringarray
- 4 -1 roll not 4 2 roll exit
- } if pop
- } for
- % Stack: false plat+enc cmap || subtable true plat+enc cmap
- pop pop
-} bind def
-
-% Build .symbol_list for .pdfcharkeys .
-% It is a dictionary containing all SymbolEncoding glyph names
-% and random names for filling gaps in the character code range.
-/.symbol_list 256 dict def
-{
- =string 0 (x) 0 get put
- /SymbolEncoding .findencoding
- 0 1 255 {
- dup 2 index exch get
- dup /.notdef eq {
- pop dup
- =string 1 3 getinterval cvs length 1 add
- =string exch 0 exch getinterval cvn
- } if
- exch //.symbol_list 3 1 roll put
- } for
- pop
-} bind exec
-
-% Create .GS_extended_SymbolEncoding as inverse of .symbol_list .
-{
- /.GS_extended_SymbolEncoding 256 array
- //.symbol_list {
- exch 2 index 3 1 roll put
- } forall
- .defineencoding
-} bind exec
-
-/.hexdigits (0123456789ABCDEF) def
-
-/.is_hex_digit { % <int> .is_hex_digit <bool>
- dup 48 ge exch
- dup 57 le exch
- dup 65 ge exch
- 70 le and
- 3 1 roll
- and or
-} bind def
-
-/.popfex { pop //false exit } bind def
-/.pop3ex { pop pop pop exit } bind def
-
-/.addglyph { % <dict> <name> <glyph#> .addglyph -
- 1 index .namestring % d n g s
- dup length 7 eq {
- % Bug688467.ps doesn't work if the uniXXXX mapping is allowed with any cmap.
- % Allow it with cmap 3.1 only.
- currentdict /.allow_uniXXXX_glyph_names .knownget not { //false } if
- } { //false
- } ifelse % d n g s b
- {
- % An undocumented Adobe feature (not sure) :
- % if the name is uniXXXX, obtain Unicode code from it.
- % See bug 688946.
- TTFDEBUG { (Try uniXXXX:) print dup print } if
- { dup 0 get 117 ne //.popfex if % u
- dup 1 get 110 ne //.popfex if % n
- dup 2 get 105 ne //.popfex if % i
- dup 3 get //.is_hex_digit exec not //.popfex if
- dup 4 get //.is_hex_digit exec not //.popfex if
- dup 5 get //.is_hex_digit exec not //.popfex if
- dup 6 get //.is_hex_digit exec not //.popfex if
- dup 3 1 getinterval .hexdigits exch search pop length exch pop exch pop 12 bitshift exch
- dup 4 1 getinterval .hexdigits exch search pop length exch pop exch pop 8 bitshift exch
- dup 5 1 getinterval .hexdigits exch search pop length exch pop exch pop 4 bitshift exch
- dup 6 1 getinterval .hexdigits exch search pop length exch pop exch pop exch pop
- add add add
- dup cmapencoding length ge //.popfex if
- cmapencoding exch get
- dup 0 eq //.popfex if
- TTFDEBUG { ( index=) print dup =string cvs print } if
- exch pop
- put //true exit
- } loop
- TTFDEBUG { ()= } if
- } {
- pop //false
- } ifelse
- not { % d n g
- { dup cmapencoding length ge //.pop3ex if
- cmapencoding exch get dup 0 eq //.pop3ex if
- 3 copy pop known //.pop3ex if
- put exit
- } loop
- } if
-} bind def
-
-% <subcmap> <chartoglyphmap> .pdfmapchars /CharStrings <charstrings>
-/.pdfmapchars {
- exch cmaparray /cmapencoding exch def % c2g
- /CharStrings 0 dict % c2g /CS <<>>
-
- % Add glyphs of <chartoglyphmap>*<subcmap> :
- 3 2 roll { % /CS <<>> v
- dup type /arraytype eq { % /CS <<>> /name []
- { 3 copy //.addglyph exec
- pop
- } forall
- } {
- 3 copy //.addglyph exec pop
- } ifelse
- pop
- } forall
-
- % Add glyphs of 'post' with lower priority :
- 0 1 glyphencoding length 1 sub {
- dup glyphencoding exch get exch
- dup 0 ne {
- 3 copy pop known not {
- 3 copy put
- } if
- } if
- pop pop
- } for
-
- dup /.notdef 0 put
-
-} bind def
-
-% - .pdfcharkeys /CharStrings <charstrings> /Encoding <encoding>
-/.pdfcharkeys {
- % The following algorithms are per the PDF Reference, Second Edition
- % (PDF 1.3 reference manual).
- TTFDEBUG { (.pdfcharkeys beg) = } if
- is_symbolic {
- <00030001> .findcmap {
- %
- % Adobe PDF spec says that symbolic fonts should contain exactly one
- % cmap subtable for Platform=1, Encoding=0.
- % Perhaps "Adobe Acrobat PDFWriter 4.0 for Windows" sometimes embeds
- % fonts with both subtables 3.1 and 1.0 (see comparefiles/159.pdf,
- % the font "Arial,Bold" with the character "registered"),
- % and both Acrobat Reader 4.0 and 5.0 choose 3.1.
- % Therefore we try 3.1 first.
- %
- ( **** Warning: Embedded symbolic TT fonts should not contain a cmap for Platform=3 Encoding=1.\n)
- pdfformaterror
- prebuilt_encoding null ne {
- % Bug 689083.
- TTFDEBUG { (Using cmap 3.0 with prebuilt_encoding.) = } if
- prebuilt_encoding .invert_encoding .pdfmapchars
- /Encoding prebuilt_encoding
- } {
- TTFDEBUG { (Using cmap 3.1 with WinAnsiEncoding) = } if
- AdobeGlyphList .pdfmapchars
- /Encoding /WinAnsiEncoding .findencoding
- } ifelse
- } {
- %
- % Adobe PDF spec says that in this case PDF interpreter should
- % map character codes directly to glyphs using
- % the cmap <00010000>. But we use PS interpreter to emulate
- % a PDF interpreter. Therefore we need to construct
- % a type 42 font, which requires an Encoding and a Charstrings.
- % We construct them with symbol_list, which
- % includes all glyphs from SymbolEncoding and additional
- % random names for 1-to-1 mapping.
- %
- % A real TT font may use a different characters than
- % the Symbol charaster set. Perhaps our code
- % will give a correct printing, because glyph names are not
- % important for symbolic fonts in PDF.
- %
- <00010000> .findcmap {
- prebuilt_encoding null ne {
- TTFDEBUG { (Using cmap 1.0 with prebuilt_encoding.) = } if
- prebuilt_encoding .invert_encoding .pdfmapchars
- /Encoding prebuilt_encoding
- } {
- % This is a case, in which an obsolete software could stupidly specify Macintosh Roman
- % for a random encoding. Particulatrly GPL Ghostscript 7.06 does so.
- % Trying to recover with 'post'.
- pop % The table itself doesn't contain useful data.
- TTFDEBUG { (Using cmap 1.0 with post or .GS_extended_SymbolEncoding) = } if
- .charkeys
- } ifelse
- } {
- % This is illegal with PDF spec.
- ( **** Warning: Embedded symbolic TT fonts must contain a cmap for Platform=1 Encoding=0.\n)
- pdfformaterror
- % Apply the default algorithm. Hopely it has 'post'.
- .charkeys
- % check if the CharStrings dict contains glyphs needed by the
- % prebuilt_encoding otherwise try the 3,0 cmap.
- prebuilt_encoding null ne {
- false prebuilt_encoding { % false means no missing glyphs
- 4 index exch known not { pop true exit } if
- } forall
- {
- ( **** Warning: Encoding derived from 'post' is incomplete.\n)
- pdfformaterror
- % Try another cmap format 3,0 -- Adobe doesn't mention it, but does
- % use it apparently (empirically determined).
- <00030000> .findcmap {
- TTFDEBUG { (Adding cmap 3.0) = } if
- 5 1 roll pop pop pop pop
- prebuilt_encoding null ne {
- prebuilt_encoding .invert_encoding .pdfmapchars
- /Encoding prebuilt_encoding
- } {
- AdobeGlyphList .pdfmapchars
- /Encoding /SymbolEncoding .findencoding
- } ifelse
- } if
- } if
- } if
- } ifelse
- } ifelse
- } {
- <00030001> .findcmap {
- prebuilt_encoding null ne {
- TTFDEBUG { (Using cmap 3.1 with prebuilt_encoding for non-symbolic.) = } if
-
- % The character code in /prebuilt_encoding[] is not guaranteed to be
- % compatible with the Microsoft UCS2 TrueType cmap subtable.
- % If the glyphname is known by AdobeGlyphList, the charcode for the glyph
- % is replaced by UCS2 charcode from AdobeGlyphList. Otherwise it is left
- % as in /prebuilt_encoding[]. /.pdfmapchars should dredge them.
-
- /.allow_uniXXXX_glyph_names //true def
- AdobeGlyphList prebuilt_encoding .invert_encoding dup { % <<AGL>> <<pbe>> <glyphname> <pbecode>
- pop % <<AGL>> <<pbe>> <glyphname>
- TTFDEBUG { (check glypname /) print dup =only flush } if
- 2 index 1 index .knownget { % <<AGL>> <<pbe>> <glyphname> <AGLcode>
- 2 index 3 1 roll % <<AGL>> <<pbe>> <<pbe>> <glyphname> <AGLcode>
- TTFDEBUG { ( redefine codepoint by AdobeGlyphList, ) print dup == flush } if
- put % <<AGL>> <<pbe>>
- } { % <<AGL>> <<pbe>> <glyphname>
- TTFDEBUG { ( unknown glyphname, leave as it is ) print flush } if
- pop % <<AGL>> <<pbe>>
- } ifelse
- } forall
- exch pop % <<pbe>>
- TTFDEBUG { dup (<<\n) print { exch ( ) print =only (\t) print == } forall (>>\n) print flush } if
- .pdfmapchars
- /Encoding prebuilt_encoding
- } {
- % Likely this branch is now obsolete.
- TTFDEBUG { (Using cmap 3.1 for non-symbolic.) = } if
- AdobeGlyphList .pdfmapchars
- /Encoding /WinAnsiEncoding .findencoding
- % WinAnsiEncoding is just a stub here.
- % It will be replaced with one from font resource,
- % because PDF spec requires it.
- } ifelse
- } {
- <00010000> .findcmap {
- TTFDEBUG { (Using cmap 1.0 for non-symbolic.) = } if
- .romanmacdict .pdfmapchars
- /Encoding
- prebuilt_encoding null ne {
- prebuilt_encoding
- } {
- /MacRomanEncodingForTrueType .findencoding
- } ifelse
- } {
- % Apply the default algorithm for using the 'post'.
- .charkeys
- } ifelse
- } ifelse
- } ifelse
- TTFDEBUG { (.pdfcharkeys end) = } if
-} bind def
-
-% <file> <is_symbolic> <Encoding|null> .loadpdfttfont <type42font>
-/.loadpdfttfont {
- TTFDEBUG { (.loadpdfttfont Encoding=) print dup == } if
- /prebuilt_encoding gput % for .pdfcharkeys
- /is_symbolic gput
- //false 0 .loadttfonttables
- .makesfnts
- tabdict /cmap known not {
- ( **** Warning: Embedded TT font lacks required cmap table. Using identity cmap.\n)
- pdfformaterror
- % Unknown (i.e. not 0 ) language ID brings in post table.
- % Fields: cmap_version, number_of_subtables,
- % plarform_id, encoding_id, offset,
- % format, subtable_length, language,
- % 256 bytes of identity mapping.
- tabdict /cmap
- < 0000 0001
- 0001 D00D 0000000c
- 0000 0106 0000
- 00 01 02 03 04 05 06 07 08 09 0a 0d 0c 0d 0e 0f
- 10 11 12 13 14 15 16 17 18 19 1a 1d 1c 1d 1e 1f
- 20 21 22 23 24 25 26 27 28 29 2a 2d 2c 2d 2e 2f
- 30 31 32 33 34 35 36 37 38 39 3a 3d 3c 3d 3e 3f
- 40 41 42 43 44 45 46 47 48 49 4a 4d 4c 4d 4e 4f
- 50 51 52 53 54 55 56 57 58 59 5a 5d 5c 5d 5e 5f
- 60 61 62 63 64 65 66 67 68 69 6a 6d 6c 6d 6e 6f
- 70 71 72 73 74 75 76 77 78 79 7a 7d 7c 7d 7e 7f
- 80 81 82 83 84 85 86 87 88 89 8a 8d 8c 8d 8e 8f
- 90 91 92 93 94 95 96 97 98 99 9a 9d 9c 9d 9e 9f
- a0 a1 a2 a3 a4 a5 a6 a7 a8 a9 aa ad ac ad ae af
- b0 b1 b2 b3 b4 b5 b6 b7 b8 b9 ba bd bc bd be bf
- c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 ca cd cc cd ce cf
- d0 d1 d2 d3 d4 d5 d6 d7 d8 d9 da dd dc dd de df
- e0 e1 e2 e3 e4 e5 e6 e7 e8 e9 ea ed ec ed ee ef
- f0 f1 f2 f3 f4 f5 f6 f7 f8 f9 fa fd fc fd fe ff
- > readonly put
- } if
- .getpost
- .pickcmap
- mark
- .pdfcharkeys
- .ttkeys
- .definettfont
-} bind def
diff --git a/Master/tlpkg/tlgs/lib/gs_typ32.ps b/Master/tlpkg/tlgs/lib/gs_typ32.ps deleted file mode 100644 index a4e83be5343..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_typ32.ps +++ /dev/null @@ -1,133 +0,0 @@ -% Copyright (C) 1997 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_typ32.ps 7710 2007-02-17 14:14:09Z alexcher $
-% Initialization file for Type 32 fonts.
-
-% ------ Type 32 fonts ------ %
-
-% We need LanguageLevel 2 or higher in order to have defineresource.
-languagelevel dup 2 .max .setlanguagelevel
-
-/BitmapFontInit mark
-
-/.makeglyph32 systemdict /.makeglyph32 get
-systemdict /.makeglyph32 .undef
-
-/addglyph { % ([wx wy llx lly urx ury] |
- % [w0x w0y llx lly urx ury w1x w1y vx vy])
- % <bitmap> <cid> <type32font> addglyph -
- 1 index dup 2 index .removeglyphs
- 22 string .makeglyph32
- % Stack: metrics bitmap cid font metstr
- 3 index () ne {
- % Use G4 encoding to compress the bitmap.
- % Define a string large enough to hold the metrics,
- % an uncompressed bitmap (worst case = 5x expansion),
- % and the 2 RTC codes (3 bytes).
- dup length 4 index length 5 mul add 10 add string
- % Stack: metrics bitmap cid font metstr buffer
- dup 0 3 index putinterval
- dup 2 index length 1 index length 1 index sub getinterval
- % Stack: metrics bitmap cid font metstr buffer bitbuf
- mark /Columns 8 index dup 4 get exch 2 get sub
- /Rows 10 index dup 5 get exch 3 get sub
- /K -1 /EndOfBlock true /BlackIs1 true
- .dicttomark /CCITTFaxEncode filter
- % Stack: metrics bitmap cid font metstr buffer filter
- dup 6 index writestring closefile
- % Find the end of the data by scanning backwards for the RTC.
- % There are 2 RTCs x 12 bits = 3 bytes to remove.
- {
- dup dup length 1 sub get 0 ne { exit } if
- 0 1 index length 1 sub getinterval
- } loop
- 0 1 index length 3 sub getinterval
- exch pop % metstr
- } if
- 1 index /CharStrings get 3 index 3 -1 roll put
- pop pop pop pop
-} obind
-
-/removeall { % <type32font> removeall -
- 0 65535 2 index removeglyphs pop
-} obind
-
-/.removeglyphs systemdict /.removeglyphs get
-systemdict /.removeglyphs .undef
-
-/removeglyphs { % <cid_min> <cid_max> <type32font> .removeglyphs -
- 3 copy .removeglyphs
- dup /CharStrings get dup {
- % Stack: cidmin cidmax font CharStrings cid bitmap
- pop dup 5 index ge { dup 4 index le { 2 copy undef } if } if pop
- } forall pop pop pop pop
-} obind
-
-.dicttomark /ProcSet defineresource pop
-
-/.cidfonttypes where { pop } { /.cidfonttypes 6 dict def } ifelse
-.cidfonttypes begin
-
-4 % CIDFontType 4 = FontType 32
-{ dup /FontType 32 .forceput
- dup /CharStrings 20 dict .forceput
- 1 index exch .buildfont32 exch pop
-} bind def
-
-end % .cidfonttypes
-
-% Define the BuildGlyph procedure.
-% Since Type 32 fonts are indexed by CID, there is no BuildChar procedure.
-% The name %Type32BuildGlyph is known to the interpreter.
-(%Type32BuildGlyph) cvn { % <font> <cid> %Type32BuildGlyph -
- 1 index /CharStrings get
- % Stack: font cid CharStrings
- dup 2 index .knownget {
- exch pop
- } {
- 0 .knownget not {
- exch pop % Stack: cid
- .getshowoperator /invalidfont signalerror
- } if
- } ifelse
- % Stack: font cid cstr
- dup //.getmetrics32 % use // because of .undef below
- dup 14 gt {
- 8 index 8 index 13 3 roll setcachedevice2
- } {
- 4 index 4 index 9 3 roll setcachedevice
- } ifelse
- % Stack: font cid cstr w h nmetrics llx lly
- 6 -1 roll 4 -1 roll 1 index length 1 index sub getinterval
- % Stack: font cid w h llx lly bitstr
- dup () eq {
- pop pop pop
- } {
- mark /Columns 6 index /Rows 7 index /K -1 /EndOfBlock false /BlackIs1 true
- .dicttomark /CCITTFaxDecode filter 4 index 4 index true
- % Stack: font cid w h llx lly filter w h true
- [ 1 0 0 1 11 -2 roll exch neg exch neg ] 5 -1 roll imagemask
- } ifelse
- pop pop pop pop
-} .bind def
-
-systemdict /.getmetrics32 .undef
-
-buildfontdict 32 /.buildfont32 cvx put
-
-32 dup /FontType defineresource pop
-
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/gs_typ42.ps b/Master/tlpkg/tlgs/lib/gs_typ42.ps deleted file mode 100644 index 2ef6058954e..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_typ42.ps +++ /dev/null @@ -1,62 +0,0 @@ -% Copyright (C) 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_typ42.ps 8537 2008-02-22 10:09:30Z leonardo $
-% Type 42 font support code.
-
-% Here are the BuildChar and BuildGlyph implementation for Type 42 fonts.
-% The names %Type42BuildChar and %Type42BuildGlyph are known to the
-% interpreter. The real work is done in an operator:
-% <font> <code|name> <name> <glyphindex> .type42execchar -
-
-(%Type42BuildChar) cvn % <font> <code> %Type42BuildChar -
- { 1 index /Encoding get 1 index get .type42build
- } bind def
-(%Type42BuildGlyph) cvn % <font> <name> %Type42BuildGlyph -
- { dup .type42build
- } bind def
-/.type42build % <font> <code|name> <name> .type42build -
- { 2 index begin
- dup CharStrings exch .knownget not
- { 2 copy eq { exch pop /.notdef exch } if
- QUIET not
- { (Substituting .notdef for ) print
- =string cvs print ( in the font ) print
- 1 index /FontName get = flush
- }
- { pop }
- ifelse
- /.notdef CharStrings /.notdef get
- } if
- end .type42execchar
- } bind def
-
-% Register the font type for definefont.
-buildfontdict 42
- { % check for bogus sfnts -- this happens in Genoa FTS 421-01.ps
- dup /sfnts get 0 get length 14 lt { % smallest valid sfnts is 14 bytes
- % HACK: Add a BuildGlyph and make this a Type 3 font instead
- dup /FontType 3 put
- dup /BuildGlyph {
- 1 index /CharStrings get exch 2 copy known not { pop /.notdef } if get exec
- } bind put
- //.buildfont3 exec
- } {
- systemdict /.buildfont42 get exec
- } ifelse
- } bind
-put
-
-
diff --git a/Master/tlpkg/tlgs/lib/gs_type1.ps b/Master/tlpkg/tlgs/lib/gs_type1.ps deleted file mode 100644 index 825819ceada..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_type1.ps +++ /dev/null @@ -1,209 +0,0 @@ -% Copyright (C) 1994, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_type1.ps 8092 2007-06-30 12:25:22Z alexcher $
-% Type 1 font support code.
-
-% The standard representation for PostScript compatible fonts is described
-% in the book "Adobe Type 1 Font Format", published by Adobe Systems Inc.
-
-% Define an augmented version of .buildfont1 that inserts UnderlinePosition
-% and UnderlineThickness entries in FontInfo if they aren't there already,
-% and FontBBox isn't degenerate.
-% (This works around the incorrect assumption, made by many word processors,
-% that these entries are present in the built-in fonts.)
-/.buildfont1
- {
- .currentglobal 3 1 roll
- dup .gcheck .setglobal
- dup .fontbbox {
- pop pop pop pop
- dup /FontInfo known not
- { .growfontdict dup /FontInfo 2 dict put }
- if
- dup dup /FontInfo get dup dup
- /UnderlinePosition known exch /UnderlineThickness known and
- { pop pop % entries already present
- }
- { dup length 2 add dict .copydict
- dup /UnderlinePosition known not
- { dup /UnderlinePosition 3 index /FontBBox get
- 1 get 2 div put % 1/2 the font descent
- }
- if
- dup /UnderlineThickness known not
- { dup /UnderlineThickness 3 index /FontBBox get
- dup 3 get exch 1 get sub 20 div put % 1/20 the font height
- }
- if
- 1 index /FontInfo get wcheck not { readonly } if
- /FontInfo exch put
- }
- ifelse
- } if
- //.buildfont1
- 3 2 roll .setglobal
- } bind def
-% If the diskfont feature isn't included, define a dummy .loadfontdict.
-/.loadfontdict where
- { pop }
- { /.loadfontdict 0 dict readonly def }
-ifelse
-/.loadfontfile % <file> .loadfontfile -
- { mark exch
- DISKFONTS { .loadfontdict begin } if
- % In order to load fonts reliably, we should push systemdict
- % here. However, Ed Taft says that Adobe implementations
- % push userdict and nothing else!
- % We really would just like systemdict on the stack,
- % but fonts produced by Fontographer require a writable dictionary.
- % However, we can't use any of the other well-known dictionaries
- % (such as userdict), since the whole point of pushing systemdict
- % is to make sure that nothing important has been redefined.
- /userdict .systemvar begin
- % We can't just use `run', because we want to check for .PFB files.
- currentpacking
- { //false setpacking .loadfont1 //true setpacking }
- { .loadfont1 }
- ifelse end
- { stop } if
- DISKFONTS { end } if
- cleartomark
- } bind def
- % container for CloseSource flag (default //true to prevent buildup of file handles)
- /closesourcedict mark
- /CloseSource //true
- .dicttomark readonly def
-/.loadfont1 { % <file> .loadfont1 <errorflag>
- { % We would like to use `false /PFBDecode filter',
- % but this occasionally produces a whitespace character as
- % the first of an eexec section, so we can't do it.
- % Also, since the real input file never reaches EOF if we are using
- % a PFBDecode filter (the filter stops just after reading the last
- % character), we must explicitly close the real file in this case.
- % Since the file might leave garbage on the operand stack,
- % we have to create a procedure to close the file reliably.
- dup read not { -1 } if
- 2 copy unread 16#80 eq {
- dup //closesourcedict //true /PFBDecode filter cvx
- exch .currentresourcefile eq {
- dup /.execasresource .systemvar
- } {
- {exec}
- } ifelse
- 2 index cvlit
- /closefile .systemvar 3 .execn
- } {
- cvx exec
- } ifelse
- } stopped
-} bind def
-% undefine a dict that is only used internally, and is immediately bound
-currentdict /closesourcedict .undef
-
-% Here are the BuildChar and BuildGlyph implementation for Type 1 fonts.
-% The names %Type1BuildChar and %Type1BuildGlyph are known to the interpreter.
-% The real work is done in an operator:
-% <font> <code|name> <name> <charstring> .type1execchar -
-
-(%Type1BuildChar) cvn { % <font> <code> %Type1BuildChar -
- 1 index /Encoding get 1 index get .type1build .type1execchar
-} bind def
-(%Type1BuildGlyph) cvn { % <font> <name> %Type1BuildGlyph -
- dup .type1build .type1execchar
-} bind def
-% Note: this procedure is used for both Type 1 and Type 2 fonts.
-/.type1build { % <font> <code|name> <name> .type1build
- % <font> <code|name> <name> <charstring>
- 2 index begin
- dup CharStrings exch .knownget not {
- 2 copy eq { exch pop /.notdef exch } if
- QUIET not
- { (Substituting .notdef for ) print
- =string cvs print ( in the font ) print
- 1 index /FontName get = flush
- }
- { pop }
- ifelse
- /.notdef CharStrings /.notdef get
- } if
- end
-} bind def
-
-1183615869 internaldict begin
-% CCRun is an undocumented procedure provided for Type 4 and Type 0 fonts.
-% Apparently there are two different argument lists for CCRun.
-% Handling the one with the extra Private dictionary requires fabricating
-% a Type 1 font on the fly, since we aren't currently prepared to parse the
-% dictionary any other way.
-/CCRun { % <font> <code|name> <charstring> CCRun -
- % <font> <code|name> <charstring> <Private> CCRun -
- dup type /dicttype eq {
- dup 4 index /Private .knownget { ne } { pop //true } ifelse {
- % The Private dictionary was supplied, and is different
- % from the Private dictionary of the font. Fabricate a
- % Type 1 font with this Private dictionary. Most of the
- % font entries are arbitrary or not needed.
- .currentglobal //false .setglobal 10 dict exch .setglobal begin
- /Private exch def
- /FontType 1 def
- /FontMatrix 3 index /FontMatrix get def
- /Encoding 3 index /Encoding .knownget not { StandardEncoding } if def
- /FontBBox 3 index /FontBBox .knownget not { {0 0 0 0} } if def
- /PaintType 0 def
- /CharStrings 1 dict dup /.notdef () put def
- 3 -1 roll pop () currentdict end .buildfont1 exch pop 3 1 roll
- } {
- pop
- } ifelse
- } if
- 1 index dup type /integertype eq {
- 3 index /Encoding get exch get
- } if exch .type1execchar
-} bind def
-
-% setweightvector is an undocumented procedure that force writes
-% weight vector to the font. Do extra checks for safety.
-/setweightvector { % <font> <vector> setweightvector -
- dup type dup /arraytype ne exch /packedarraytype ne and
- 2 index type /dicttype ne or {
- /setweightvector cvx /typecheck signalerror
- } if
- 1 index /FontType known not {
- /setweightvector cvx /invalidfont signalerror
- } if
- dup gcheck 2 index gcheck not and {
- /setweightvector cvx /invalidaccess signalerror
- } if
- 2 copy /WeightVector exch .forceput
- .setweightvector
-} .bind executeonly def
-end
-
-% Register the font types for definefont.
-buildfontdict 1 /.buildfont1 cvx put
-buildfontdict 4 /.buildfont4 cvx put
-
-% Add Type 2 support if applicable.
-/.buildfont2 where not { (%END2) .skipeof } if
-pop
-(%Type2BuildChar) cvn { % <font> <code> %Type2BuildChar -
- 1 index /Encoding get 1 index get .type1build .type2execchar
-} bind def
-(%Type2BuildGlyph) cvn { % <font> <name> %Type2BuildGlyph -
- dup .type1build .type2execchar
-} bind def
-buildfontdict 2 /.buildfont2 cvx put
-%END2
diff --git a/Master/tlpkg/tlgs/lib/gs_wan_e.ps b/Master/tlpkg/tlgs/lib/gs_wan_e.ps deleted file mode 100644 index 181029c87fd..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_wan_e.ps +++ /dev/null @@ -1,46 +0,0 @@ -% Copyright (C) 1994, 1996, 1997, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_wan_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the WinAnsi encoding vector.
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/WinAnsiEncoding
-ISOLatin1Encoding 0 39 getinterval aload pop
- /quotesingle
-ISOLatin1Encoding 40 5 getinterval aload pop
- /hyphen
-ISOLatin1Encoding 46 50 getinterval aload pop
- /grave
-ISOLatin1Encoding 97 30 getinterval aload pop
- /bullet
-% \20x
- % NOTE: /Euro, /Zcaron, and /zcaron are new for PDF 1.3.
- % We may have to take them out for backward compatibility.
- /Euro /bullet /quotesinglbase /florin
- /quotedblbase /ellipsis /dagger /daggerdbl
- /circumflex /perthousand /Scaron /guilsinglleft
- /OE /bullet /Zcaron /bullet
- /bullet /quoteleft /quoteright /quotedblleft
- /quotedblright /bullet /endash /emdash
- /tilde /trademark /scaron /guilsinglright
- /oe /bullet /zcaron /Ydieresis
-ISOLatin1Encoding 160 96 getinterval aload pop
-256 packedarray
-4 1 index .registerencoding
-.defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_wl1_e.ps b/Master/tlpkg/tlgs/lib/gs_wl1_e.ps deleted file mode 100644 index 88d83604620..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_wl1_e.ps +++ /dev/null @@ -1,66 +0,0 @@ -% Copyright (C) 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_wl1_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Windows 3.1 Latin 1 encoding vector (H-P Symbol set 19U).
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/Win31Latin1Encoding
-ISOLatin1Encoding 0 39 getinterval aload pop
- /quotesingle
-ISOLatin1Encoding 40 5 getinterval aload pop
- /hyphen
-ISOLatin1Encoding 46 50 getinterval aload pop
- /grave
-ISOLatin1Encoding 97 30 getinterval aload pop
- /graybox
-% \20x
- /.notdef /.notdef /quotesinglbase /florin
- /quotedblbase /ellipsis /dagger /daggerdbl
- /circumflex /perthousand /Scaron /guilsinglleft
- /OE /.notdef /.notdef /.notdef
- /.notdef /quoteleft /quoteright /quotedblleft
- /quotedblright /bullet /endash /emdash
- /tilde /trademark /scaron /guilsinglright
- /oe /.notdef /.notdef /Ydieresis
- /.notdef /exclamdown /cent /sterling
- /currency /yen /brokenbar /section
- /dieresis /copyright /ordfeminine /guillemotleft
- /logicalnot /softhyphen /registered /overscore
- /degree /plusminus /twosuperior /threesuperior
- /acute /mu /paragraph /periodcentered
- /cedilla /onesuperior /ordmasculine /guillemotright
- /onequarter /onehalf /threequarters /questiondown
-% \30x
- /Agrave /Aacute /Acircumflex /Atilde
- /Adieresis /Aring /AE /Ccedilla
- /Egrave /Eacute /Ecircumflex /Edieresis
- /Igrave /Iacute /Icircumflex /Idieresis
- /Eth /Ntilde /Ograve /Oacute
- /Ocircumflex /Otilde /Odieresis /multiply
- /Oslash /Ugrave /Uacute /Ucircumflex
- /Udieresis /Yacute /Thorn /germandbls
- /agrave /aacute /acircumflex /atilde
- /adieresis /aring /ae /ccedilla
- /egrave /eacute /ecircumflex /edieresis
- /igrave /iacute /icircumflex /idieresis
- /eth /ntilde /ograve /oacute
- /ocircumflex /otilde /odieresis /divide
- /oslash /ugrave /uacute /ucircumflex
- /udieresis /yacute /thorn /ydieresis
-256 packedarray .defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_wl2_e.ps b/Master/tlpkg/tlgs/lib/gs_wl2_e.ps deleted file mode 100644 index a0e8477dd41..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_wl2_e.ps +++ /dev/null @@ -1,66 +0,0 @@ -% Copyright (C) 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_wl2_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Windows 3.1 Latin 2 encoding vector (H-P Symbol set 9E).
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/Win32Latin2Encoding
-ISOLatin1Encoding 0 39 getinterval aload pop
- /quotesingle
-ISOLatin1Encoding 40 5 getinterval aload pop
- /hyphen
-ISOLatin1Encoding 46 50 getinterval aload pop
- /grave
-ISOLatin1Encoding 97 30 getinterval aload pop
- /graybox
-% \20x
- /.notdef /.notdef /quotesinglbase /.notdef
- /quotedblbase /ellipsis /dagger /daggerdbl
- /.notdef /perthousand /Scaron /guilsinglleft
- /Sacute /Tcaron /Zcaron /Zacute
- /.notdef /quoteleft /quoteright /quotedblleft
- /quotedblright /bullet /endash /emdash
- /.notdef /trademark /scaron /guilsinglright
- /sacute /tcaron /zcaron /zacute
- /.notdef /caron /breve /Lslash
- /currency /Aogonek /brokenbar /section
- /dieresis /copyright /Scedilla /guillemotleft
- /logicalnot /softhyphen /registered /Zdotaccent
- /degree /plusminus /ogonek /lslash
- /acute /mu /paragraph /periodcentered
- /cedilla /aogonek /scedilla /guillemotright
- /Lcaron /hungarumlaut /lcaron /zdotaccent
-% \30x
- /Racute /Aacute /Acircumflex /Abreve
- /Adieresis /Lacute /Cacute /Ccedilla
- /Ccaron /Eacute /Eogonek /Edieresis
- /Ecaron /Iacute /Icircumflex /Dcaron
- /Dcroat /Nacute /Ncaron /Oacute
- /Ocircumflex /Ohungarumlaut /Odieresis /multiply
- /Rcaron /Uring /Uacute /Uhungarumlaut
- /Udieresis /Yacute /Tcommaaccent /germandbls
- /racute /aacute /acircumflex /abreve
- /adieresis /lacute /cacute /ccedilla
- /ccaron /eacute /eogonek /edieresis
- /ecaron /iacute /icircumflex /dcaron
- /dcroat /nacute /ncaron /oacute
- /ocircumflex /ohungarumlaut /odieresis /divide
- /rcaron /uring /uacute /uhungarumlaut
- /udieresis /yacute /tcommaaccent /dotaccent
-256 packedarray .defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gs_wl5_e.ps b/Master/tlpkg/tlgs/lib/gs_wl5_e.ps deleted file mode 100644 index 07c4249488e..00000000000 --- a/Master/tlpkg/tlgs/lib/gs_wl5_e.ps +++ /dev/null @@ -1,66 +0,0 @@ -% Copyright (C) 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gs_wl5_e.ps 6300 2005-12-28 19:56:24Z giles $
-% Define the Windows 3.1 Latin 5 encoding vector (H-P Symbol set 5T).
-/currentglobal where
- { pop currentglobal { setglobal } true setglobal }
- { { } }
-ifelse
-/Win32Latin5Encoding
-ISOLatin1Encoding 0 39 getinterval aload pop
- /quotesingle
-ISOLatin1Encoding 40 5 getinterval aload pop
- /hyphen
-ISOLatin1Encoding 46 50 getinterval aload pop
- /grave
-ISOLatin1Encoding 97 30 getinterval aload pop
- /graybox
-% \20x
- /.notdef /.notdef /quotesinglbase /florin
- /quotedblbase /ellipsis /dagger /daggerdbl
- /circumflex /perthousand /Scaron /guilsinglleft
- /OE /.notdef /.notdef /.notdef
- /.notdef /quoteleft /quoteright /quotedblleft
- /quotedblright /bullet /endash /emdash
- /tilde /trademark /scaron /guilsinglright
- /oe /.notdef /.notdef /Ydieresis
- /.notdef /exclamdown /cent /sterling
- /currency /yen /brokenbar /section
- /dieresis /copyright /ordfeminine /guillemotleft
- /logicalnot /softhyphen /registered /overscore
- /degree /plusminus /twosuperior /threesuperior
- /acute /mu /paragraph /periodcentered
- /cedilla /onesuperior /ordmasculine /guillemotright
- /onequarter /onehalf /threequarters /questiondown
-% \30x
- /Agrave /Aacute /Acircumflex /Atilde
- /Adieresis /Aring /AE /Ccedilla
- /Egrave /Eacute /Ecircumflex /Edieresis
- /Igrave /Iacute /Icircumflex /Idieresis
- /Gbreve /Ntilde /Ograve /Oacute
- /Ocircumflex /Otilde /Odieresis /multiply
- /Oslash /Ugrave /Uacute /Ucircumflex
- /Udieresis /Idotaccent /Scedilla /germandbls
- /agrave /aacute /acircumflex /atilde
- /adieresis /aring /ae /ccedilla
- /egrave /eacute /ecircumflex /edieresis
- /igrave /iacute /icircumflex /idieresis
- /gbreve /ntilde /ograve /oacute
- /ocircumflex /otilde /odieresis /divide
- /oslash /ugrave /uacute /ucircumflex
- /udieresis /dotlessi /scedilla /ydieresis
-256 packedarray .defineencoding
-exec
diff --git a/Master/tlpkg/tlgs/lib/gslp.ps b/Master/tlpkg/tlgs/lib/gslp.ps deleted file mode 100644 index c520be656d9..00000000000 --- a/Master/tlpkg/tlgs/lib/gslp.ps +++ /dev/null @@ -1,695 +0,0 @@ -% Copyright (C) 1991, 1995, 1996, 1997, 1998, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gslp.ps 6300 2005-12-28 19:56:24Z giles $
-% gslp.ps - format and print text
-
-% This utility provides functionality approximately equivalent to the Unix
-% `enscript' program. It prints plain text files using a single font.
-% It currently handles tabs and formfeeds, but not backspaces.
-% It will line-wrap when using fixed-pitch fonts.
-% It will also do kerning and width adjustment.
-% Standard switches implemented:
-% -12BclqRr -b<header> -f<font> -F<hfont> -L<lines> -p<outfile>
-% Sun switches implemented:
-% -T<n> set tab width
-% Switches ignored:
-% -GghKkmow -# -C -d -J -n -P -S -s -t -v
-% Switches added:
-% --add-to-space <units>
-% add the given number of 1/72" units to the width of each
-% space (may be negative)
-% --add-to-width <units>
-% add the given number of 1/72" units to the width of each
-% character (may be negative)
-% --columns <n>
-% print in <n> columns
-% --detect
-% treat the file as PostScript if it starts with %!
-% --first-page <n>
-% start printing at page <n>
-% --kern <file.afm>
-% kern using information from the given .AFM file
-% --last-page <n>
-% stop printing after page <n>
-% --(heading|footing)-(left|center|right) <string>
-% set the heading/footing fields; use -B first to clear
-% --margin-(top|bottom|left|right) <inches>
-% set a margin
-% --no-eject-(file|formfeed)
-% end-of-file/FF only starts a new column, not a new sheet
-% --spacing <n>
-% use double (n=2), triple (n=3), etc. spacing
-% Also, the string %# in a heading or footing is replaced with the page #.
-/PageNumberString (%#) def
-
-/lpdict 150 dict def
-lpdict begin
-
-% build iso-latin-1 version of a font
-/font-to-iso-latin-1 { % <font> font-to-iso-latin-1 <font>
- %% reencode for iso latin1; from the 2nd edition red book, sec 5.6.1
- dup length dict begin {1 index /FID ne {def} {pop pop} ifelse} forall
- /Encoding ISOLatin1Encoding def currentdict end
- dup /FontName get 80 string cvs (-ISOLatin1) concatstrings cvn
- exch definefont
-} def
-
-/find-latin-font { % <name> find-latin-font <font>
- findfont font-to-iso-latin-1
-} def
-
-% Define the initial values of the printing parameters.
-
-/AddToSpace 0 def
-/AddToWidth 0 def
-/BodyFont null def % use default
- /defaultBodyFontPortrait
- /Courier find-latin-font 10 scalefont def
- /defaultBodyFontLandscape
- /Courier find-latin-font 7 scalefont def
- /defaultBodyFont
- { Landscape { defaultBodyFontLandscape } { defaultBodyFontPortrait } ifelse } def
-/Columns 1 def
-/DetectFileType false def
-/EjectEOF true def
-/EjectFF true def
-/Footers false def
-/FootingLeft () def
-/FootingCenter () def
-/FootingRight () def
-/Headers true def
-/HeadingLeft () def
-/HeadingCenter () def
-/HeadingRight (page ) PageNumberString concatstrings def
-/HeadingFont null def % use default
- /defaultHeadingFont
- /Courier-Bold find-latin-font 10 scalefont def
-/Kern 0 dict def % no kerning
-/Landscape false def
-/MarginBottom 36 def % 1/2"
-/MarginLeft 36 def % 1/2"
-/MarginRight 36 def % 1/2"
-/MarginTop 36 def % 1/2"
-/MaxLines 9999 def % max lines per page
-/Noisy true def % i.e., not quiet
-/OutFile null def % null = write directly to device
-/PageFirst 1 def
-/PageLast 99999 def
-/Spacing 1 def
-/Tab 8 def
-/Truncate false def % wrap long lines, don't truncate
-
-% When writing to a file, we want to write out PostScript;
-% when writing to the printer, we want to execute it;
-% some commands should be executed regardless.
-% lpexec provides for all this.
-
-/lpdef { % <name> <value> lpdef -
- /def 2 true lpexec
-} def
-
-/lpexec { % <arg1> ... <argn> </op> <n> <do_always> lpexec -
- OutFile null eq {
- pop 1 add true
- } {
- /t exch def 1 add /n exch def cvx
- n -1 roll dup wo
- n 1 sub { n -1 roll dup wosp } repeat
- (\n) ws n t
- } ifelse
- { pop load exec }
- { { pop } repeat }
- ifelse
-} def
-
-/lpmoveto { % <x> <y> lpmoveto -
- % Round the coordinates for smaller output.
- 2 {
- exch 100 mul round 100 div
- dup dup cvi eq { cvi } if
- } repeat
- 1 index X eq { neg exch pop /V 1 } { neg /M 2 } ifelse true lpexec
-} def
-/lpshow { % <string> lpshow -
- dup length 0 ne {
- addspace 0 ne {
- addspace 0 32
- addwidth 0 ne {
- addwidth 0 6 -1 roll /awidthshow 6 true lpexec
- } {
- 4 -1 roll /widthshow 4 true lpexec
- } ifelse
- } {
- addwidth 0 ne {
- addwidth 0 3 -1 roll /ashow 3 true lpexec
- } {
- OutFile null ne {
- dup dup length =string length gt {
- /show 1 false lpexec
- } {
- (S ) ws ws (\n) ws
- } ifelse
- } if show
- } ifelse
- } ifelse
- } {
- pop
- } ifelse
-} def
-/lpsetmyfont {
- dup load setfont
- OutFile null ne { cvx /setfont 1 false lpexec } { pop } ifelse
-} def
-
-% Define some utility procedures.
-
-/banner % ypos left center right
- { /HFont lpsetmyfont
- /addspace 0 def /addwidth 0 def
- /pairkern 0 dict def
- 3 -1 roll bannerstring pop 0 4 index pwidth showline2 pop
- exch bannerstring pwidth exch sub 2 div 3 index pwidth showline2 pop
- bannerstring
- % Prevent the last character of the heading from grazing
- % the right margin.
- % ****** WHY DOES IT REQUIRE SO MUCH PADDING? ******
- ( ) stringwidth pop 2 mul add
- pwidth exch sub
- 3 -1 roll pwidth showline2 pop
- } def
-
-/bannerstring % string -> string width
- { PageNumberString search
- { exch pop pindex 4 string cvs concatstrings exch concatstrings
- }
- if dup stringwidth pop
- } def
-
-/beginpage
- { /lindex 0 def
- /skipping pindex PageFirst ge pindex PageLast le and not def
- pagex pagey Landscape {/BL} {/B} ifelse 2 true lpexec
- /pagesave exch def
- skipping { nulldevice /OutFile null def } if
- Headers
- { lheight hdescent add
- HeadingLeft HeadingCenter HeadingRight banner
- } if
- /BFont lpsetmyfont
- /pairkern Kern def
- /addspace AddToSpace def /addwidth AddToWidth def
- pairkern length 0 ne {
- /addspace AddToSpace lpdef /addwidth AddToWidth lpdef
- } if
- } def
-
-/endpage {
- lindex 0 ne {
- Footers {
- topskip plength sub hdescent add
- FootingLeft FootingCenter FootingRight banner
- } if
- /E
- } {
- /restore
- } ifelse
- pagesave exch 0 true lpexec
- /pindex pindex 1 add def
-} def
-
-/endcolumn
- { lindex colines 1 sub add colines idiv colines mul
- dup llength ge { pop endpage beginpage } { /lindex exch def } ifelse
- } def
-
-/fontheight % <font> fontheight <ascent> <height>
- { gsave setfont
- newpath 0 0 moveto
- (|^_j) false charpath
- pathbbox exch pop dup 2 index sub 4 -2 roll pop pop
- grestore exch 1.25 mul exch 1.25 mul
- } def
-
-/wdict {
- dup length wosp ( dict\n) ws
- { (dup) ws exch wosp wosp ( put\n) ws } forall
-} def
-/wosp { ( ) ws wo } def
-/wo {
- dup type /dicttype eq { wdict } { OutFile exch write==only } ifelse
-} def
-/ws {
- OutFile exch writestring
-} def
-
-/outfont { % <name> <font> outfont -
- OutFile null ne {
- exch wo
- dup /FontName get
- dup wosp (-ISOLatin1) ws wosp ( RE) ws
- /FontMatrix get 0 get 1000 mul round cvi wosp
- ( scalefont def\n) ws
- } {
- pop pop
- }ifelse
-} def
-
-/StringFF (\f) def
-/CharFF StringFF 0 get def
-/StringTAB (\t) def
-/CharTAB StringTAB 0 get def
-
-/showline % line -> leftover_line (handles \f)
- { { showline1 dup length 0 eq { exit } if
- dup 0 get CharFF ne { exit } if
- EjectFF { endpage beginpage } { endcolumn } ifelse
- skip1
- }
- loop
- } def
-
-/showline1 % line -> leftover_line (handles page break)
- { lindex llength eq { endpage beginpage } if
- lindex colines idiv cowidth mul % x
- lindex colines mod 1 add lheight mul neg fascent sub % y
- 1 index cowidth add
- showline2
- /lindex lindex 1 add def
- } def
-
-/setxy {
- /ty exch def /tx exch def
-} def
-
-/showline2 { % string x y xlimit -> leftover_string (handles tabs)
- 2 index exch 5 2 roll setxy {
- % Stack: xinit xlimit string
- showline3 dup length 0 eq { exit } if
- dup 0 get CharTAB ne { exit } if
- tx 3 index sub tabwx div
- 0.05 add ceiling tabwx mul 3 index add ty setxy
- skip1
- tx 2 index ge { exit } if
- } loop exch pop exch pop
-} def
-
-/showline3 { % xlimit string -> xlimit leftover_string
- % (finds line break / tab / formfeed)
- 1 index tx sub
- cwx div 0.1 add cvi 0 .max 1 index length .min
- 1 index 0 3 -1 roll getinterval
- % look for \f or \t
- StringFF search { exch pop exch pop } if
- StringTAB search { exch pop exch pop } if
- dup length 0 ne {
- tx ty lpmoveto
- dup pairkern length 0 eq {
- lpshow
- } {
- { kproc } exch /kshow 2 true lpexec
- } ifelse
- currentpoint setxy
- } if
- length dup 2 index length exch sub getinterval
-} def
-
-/kproc { % <char1> <char2> kproc -
- pairkern currentfont /Encoding get 3 index get
- 2 copy known {
- get currentfont /Encoding get 2 index get
- 2 copy known {
- get currentfont /FontMatrix get 0 get mul
- } {
- pop pop 0
- } ifelse
- } {
- pop pop 0
- } ifelse
- addwidth add 2 index 32 eq { addspace add } if
- dup 0 eq { pop } { 0 rmoveto } ifelse
- pop pop
-} def
-
-/skip1
- { dup length 1 sub 1 exch getinterval
- } def
-
-/e== { % <object> e== - -- print an object to stderr
- (%stderr) (w) file dup 3 -1 roll write==only flushfile
-} def
-
-/eprint { % <string> eprint - -- print a string to stderr
- (%stderr) (w) file dup 3 -1 roll writestring flushfile
-} def
-
-% Read kerning information from a .AFM file.
-
-/readkern { % <afmfile> readkern <pairkerndict>
- /mfilename 1 index def
- (r) file /mfile exch def
- mfile =string readline pop
- (StartFontMetrics ) anchorsearch {
- pop pop
- /kdict 256 dict def
- { mfile =string readline pop
- (EndFontMetrics) anchorsearch { pop pop exit } if
- (KPX ) anchorsearch {
- pop token pop cvlit /char1 exch def
- token pop cvlit /char2 exch def
- token pop /kern exch def pop
- kdict char1 .knownget not {
- 5 dict kdict char1 2 index .growput
- } if
- char2 kern .growput
- } {
- pop
- } ifelse
- } loop kdict
- } {
- pop
- mfilename eprint ( does not begin with StartFontMetrics.\n) eprint
- 0 dict
- } ifelse
- mfile closefile
-} def
-
-% The main printing procedure
-
-/doFirst true def
-/prevBFont null def
-/prevHFont null def
-
-/lpfirst { % - lpfirst -
-% Define some abbreviating procedures.
- /B {save 3 1 roll translate /X 0 def} lpdef
- /BL {save 3 1 roll 90 rotate translate /X 0 def} lpdef
- /E {showpage restore} lpdef
- /V {neg X exch moveto} lpdef
- /M {/X 2 index def neg moveto} lpdef
- /S {currentfile =string readline pop show} lpdef
- /RE { % <isoname> <fontname> RE <font>
- findfont
- %% reencode for iso latin1; from the 2nd edition red book, sec 5.6.1
- dup length dict begin {1 index /FID ne {def} {pop pop} ifelse} forall
- /Encoding ISOLatin1Encoding def currentdict end
- definefont
- } lpdef
-} def
-
-/lp { % file initial_chars ->
- /lpline exch def
- /lpfile exch def
-
- doFirst { lpfirst /doFirst false def } if
-
-% Initialize the device and fonts.
- /BFont
- BodyFont null eq { defaultBodyFont } { BodyFont } ifelse def
- BFont prevBFont ne {
- /BFont BFont outfont
- /prevBFont BFont def
- } if
- Headers Footers or {
- /HFont
- HeadingFont null eq { defaultHeadingFont } { HeadingFont } ifelse def
- HFont prevHFont ne {
- /HFont HFont outfont
- /prevHFont HFont def
- } if
- } if
- save
-
-% Get the layout parameters.
- clippath
- gsave % for possible rotation
- Landscape { 90 rotate } if
- BFont setfont ( ) stringwidth pop /cwx exch def
- cwx Tab mul /tabwx exch def
- BFont fontheight /fheight exch def /fascent exch def
- Headers Footers or { HFont fontheight } { 0 0 } ifelse
- /hheight exch def /hascent exch def
- /hdescent hheight hascent sub def
- fheight Spacing mul /lheight exch def
- Headers { hheight lheight add } { 0 } ifelse
- /topskip exch def
- Footers { hheight lheight add } { 0 } ifelse
- /botskip exch def
- /pskip topskip botskip add def
- % Translate the page so that (0,0) corresponds to
- % the top of the topmost body line.
- pathbbox
- 2 index sub MarginBottom MarginTop add sub /plength exch def
- 2 index sub MarginLeft MarginRight add sub /pwidth exch def
- pwidth Columns div /cowidth exch def
- exch MarginLeft add
- exch MarginBottom add plength add topskip sub
- /pagey exch def /pagex exch def
- plength pskip sub lheight div cvi MaxLines .min
- dup /colines exch def
- Columns mul /llength exch def
- grestore
- OutFile null ne { nulldevice } if
-
-% Print layout
- Noisy
- { (Page height = ) eprint llength e==
- (.\n) eprint flush
- } if
-
-% Write the kerning table, if relevant.
- OutFile null ne Kern length 0 ne and {
- (/kproc) ws /kproc load wosp ( def\n) ws
- (/pairkern) ws Kern wosp ( def\n) ws
- } if
-
-% Disable stack recording so we can use stopped with readline.
- $error /recordstacks false put
-
-% Initialize for the first page.
- /lbuf 64000 string def
- /pindex 1 def
- beginpage
-
-% Iterate through the file.
- lpline
- { dup length /pos exch def
- lbuf exch 0 exch putinterval
- { lpfile lbuf pos lbuf length pos sub getinterval readline } stopped
- { % Filled the line before a CR or EOF.
- exch pop showline
- }
- { % Reached CR and/or EOF first.
- exch length pos add lbuf exch 0 exch getinterval
- 1 index { showline } if % omit final empty line
- { dup length 0 eq Truncate or { pop () exit } if
- showline
- }
- loop
- exch not { exit } if
- }
- ifelse
- pindex PageLast gt { exit } if
- } loop
- pop
-
-% Wrap up.
-%**************** WHY IS THIS COMMENTED OUT? ****************
-% EjectEOF { endpage } { endcolumn } ifelse
- endpage
- restore
-
-} def
-
-end
-
-% Usage: <file> lp
-% prints <file> using the current parameter settings.
-% Usage: [ <arg1> ... <argn> ] lpcommand
-% interprets args like a command line.
-
-/lp { save lpdict begin () lp end restore } def
-
-lpdict begin
-
-/splitfn % (FontNN.NN) -> <font>
- { dup /arg exch def length
- { dup 0 le { exit } if
- dup 1 sub arg exch get dup 48 ge 1 index 59 le and exch 46 eq or not { exit } if
- 1 sub
- } loop
- arg exch 0 exch getinterval dup cvn find-latin-font
- exch arg exch anchorsearch pop pop cvr scalefont
- } def
-
-% Parse the command line switches.
-
-/doswitch % argn ... arg1 (-?) restofswitch ->
- { exch dup cvn lpdict exch known
- { cvn load exec }
- { exch pop (Unknown switch: ) eprint eprint (\n) eprint }
- ifelse
- } def
-
-/more % argn ... arg1 restofswitch ->
- { dup length 0 ne
- { (- ) dup 1 3 index 0 get put
- exch dup length 1 sub 1 exch getinterval
- doswitch
- }
- { pop
- }
- ifelse
- } def
-
-/-- { (--) exch concatstrings
- dup cvn lpdict exch known
- { cvn load exec }
- { (Unknown switch: ) eprint eprint (\n) eprint }
- ifelse
- } def
-/--add-to-space { cvr /AddToSpace exch def } def
-/--add-to-width { cvr /AddToWidth exch def } def
-/--columns { cvi 1 .max /Columns exch def } def
-/--detect { /DetectFileType true def } def
-/--first-page { cvi /PageFirst exch def } def
-/--footing-center { /FootingCenter exch def /Footers true def } def
-/--footing-left { /FootingLeft exch def /Footers true def } def
-/--footing-right { /FootingRight exch def /Footers true def} def
-/--heading-center { /HeadingCenter exch def /Headers true def } def
-/--heading-left { /HeadingLeft exch def /Headers true def } def
-/--heading-right { /HeadingRight exch def /Headers true def } def
-/--kern { readkern /Kern exch def } def
-/--last-page { cvi /PageLast exch def } def
-/--margin-bottom { cvr 72.0 mul /MarginBottom exch def } def
-/--margin-left { cvr 72.0 mul /MarginLeft exch def } def
-/--margin-right { cvr 72.0 mul /MarginRight exch def } def
-/--margin-top { cvr 72.0 mul /MarginTop exch def } def
-/--no-eject-file { /EjectEOF false def } def
-/--no-eject-formfeed { /EjectFF false def } def
-/--spacing { cvr /Spacing exch def } def
-
-/-# { pop } def % ignore
-/-+ { -- } def
-(-1)cvn { /Columns 1 def more } def
-(-2)cvn { /Columns 2 def more } def
-/-b { /HeadingLeft exch def /HeadingCenter () def /HeadingRight PageNumberString def
- /Headers true def
- /break true def
- } def
-/-B { /HeadingLeft () def /HeadingCenter () def /HeadingRight () def
- /Headers false def
- /FootingLeft () def /FootingCenter () def /FootingRight () def
- /Footers false def
- /break true def
- more
- } def
-/-C { pop } def % ignore
-/-c { /Truncate true def more } def
-/-d { pop } def % ignore
-/-f { splitfn /BodyFont exch def } def
-/-F { splitfn /HeadingFont exch def } def
-/-G { more } def % ignore
-/-g { more } def % ignore
-/-h { more } def % ignore
-/-J { pop } def % ignore
-/-K { more } def % ignore
-/-k { more } def % ignore
-/-l { 66 -L -B } def
-/-L { cvi /MaxLines exch def } def
-/-m { more } def % ignore
-/-n { pop } def % ignore
-/-o { more } def % ignore
-/-p { (w) file /OutFile exch def OutFile (%!\n) writestring } def
-/-P { pop } def % ignore
-/-q { /Noisy false def more } def
-/-r { /Landscape true def more } def
-/-R { /Landscape false def more } def
-/-S { pop } def % ignore
-/-s { pop } def % ignore
-/-T { cvi /Tab exch def } def
-/-v { pop } def % ignore
-/-w { more } def % ignore
-
-/lp1 % filename ->
- { break not { dup /HeadingLeft exch def } if
- Noisy
- { (Printing ) eprint dup eprint (\n) eprint
- } if
- (r) file
- % If requested, check for a PostScript file.
- DetectFileType
- { dup 2 string readstring pop dup (%!) eq
- { % Yes, it's a PostScript file.
- pop dup 80 string readline pop pop cvx exec
- }
- { lp
- }
- ifelse
- }
- { () lp
- }
- ifelse
- } bind def
-
-/lpcstring 8192 string def
-
-end
-
-/lpcommand % <[arg1 ... argn]> lpcommand <any_printed>
- { % Push the commands on the stack in reverse order
- mark exch
- dup length 1 sub -1 0 { 1 index exch get exch } for pop
- lpdict begin
- /any false def
- /break false def
- { dup mark eq { pop exit } if
- dup length 2 ge { dup 0 get (-) 0 get eq } { false } ifelse
- { dup 0 2 getinterval
- exch dup length 2 sub 2 exch getinterval
- doswitch
- }
- { dup /matched false def
- { /matched true def /any true def lp1 } lpcstring filenameforall
- matched { pop } { lp1 } ifelse % let the error happen
- }
- ifelse
- } loop
- OutFile null ne
- { OutFile (%stdout) (w) file ne { OutFile closefile } if
- /OutFile null def
- } if
- any
- end
- } def
-
-[ shellarguments
- { ] dup length 0 ne { lpcommand } { false } ifelse not
- { (%stderr) (w) file
- [ (Usage: )
- /PROGNAME where { pop PROGNAME } { (gslp) } ifelse
- ( [-12BclqRr] [-b<header>] [-f<font>] [-F<hfont>]\n)
- ( [-L<lines>] [-p<outfile>] [-T<tabwidth>]\n)
- ( [--add-to-(space|width) <units>] [--columns <n>]\n)
- ( [--detect] [--first-page <page#>] [--last-page <page#>]\n)
- ( [--(heading|footing)-(left|right|center) <string>]\n)
- ( [--kern <afmfile>] [--margin-(top|bottom|left|right) <inches>]\n)
- ( [--no-eject-(file|formfeed)] [--spacing <n>] file1 ... filen\n)
- ] { 2 copy writestring pop } forall dup flushfile closefile
- }
- if
- }
- { pop }
-ifelse
diff --git a/Master/tlpkg/tlgs/lib/gsnup.ps b/Master/tlpkg/tlgs/lib/gsnup.ps deleted file mode 100644 index df96ba332da..00000000000 --- a/Master/tlpkg/tlgs/lib/gsnup.ps +++ /dev/null @@ -1,93 +0,0 @@ -%!
-% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: gsnup.ps 6300 2005-12-28 19:56:24Z giles $
-% Prefix this to very well-behaved PostScript files for n-up printing.
-
-/cdef { 1 index where { pop pop } { def } ifelse } def
-
-%%%%%%%%%%%%%%%% Begin parameters %%%%%%%%%%%%%%%%
-
-% All parameters are also settable from the command line with -d, e.g.,
-% -d.Nx=3
-
-/.Nx 2 cdef % # of pages across the physical page
-/.Ny 2 cdef % # of pages down the physical page
-/.Landscape false cdef % if true, rotate page by 90 degrees
-
-%%%%%%%%%%%%%%%% End parameters %%%%%%%%%%%%%%%%
-
-vmstatus pop pop 0 eq { save pop } if
-.Landscape {
- currentpagedevice /PageSize get aload pop
- exch 2 array astore
- 1 dict dup /PageSize 4 -1 roll put
- setpagedevice
-} if
-/.BP currentpagedevice /BeginPage get def
-/.EP currentpagedevice /EndPage get def
-/.Ps 1 string def % survive save/restore
-/.Pn { .Ps 0 get } def
-true setglobal % protect from restore
-/.ELevel [0] def
-/.Rmat matrix def
-false setglobal
-/.max { 2 copy lt { exch } if pop } cdef
-% Work around the common save ... showpage ... restore locution.
-/restore {
- .Rmat currentmatrix pop restore
- vmstatus pop pop .ELevel 0 get lt { .Rmat setmatrix } if
-} bind def
-<<
- /BeginPage {
- .Nx .Ny .max
- gsave
- initclip clippath pathbbox exch 4 -1 roll sub 3 1 roll exch sub
- grestore
- 2 copy exch .Nx div exch .Ny div
- .Pn dup .Nx mod exch .Nx idiv .Ny 1 sub exch sub
- % Stack: nmax pw ph pw/nx ph/ny ix iy
- exch 3 index mul exch 2 index mul
- translate
- % Stack: nmax pw ph pw/nx ph/ny
- 4 -1 roll 4 index div 4 -1 roll 4 index div
- % Stack: nmax pw/nx ph/ny pw/nmax ph/nmax
- exch 4 -1 roll exch sub 2 div
- 3 1 roll sub 2 div
- translate
- % Stack: nmax
- 1 exch div dup scale
- .BP
- }
- /EndPage {
- dup 2 lt {
- .ELevel 0 vmstatus pop pop put
- .Ps 0 .Pn 1 add .Nx .Ny mul mod put
- .Pn 0 eq {
- .EP
- } {
- pop pop false
- } ifelse
- } {
- pop pop false
- } ifelse
- }
->> setpagedevice
-/.EOJ {
- { .Pn 0 eq { exit } if showpage } loop
-} def
-
-{ currentfile cvx exec .EOJ } exec
diff --git a/Master/tlpkg/tlgs/lib/ht_ccsto.ps b/Master/tlpkg/tlgs/lib/ht_ccsto.ps deleted file mode 100644 index bb24e32178a..00000000000 --- a/Master/tlpkg/tlgs/lib/ht_ccsto.ps +++ /dev/null @@ -1,3553 +0,0 @@ -%!
-% This file is a reformatting of data placed in the public domain by its
-% author, CalComp Technology, Inc.
-%
-% Aladdin Enterprises, Menlo Park, CA reformatted the original data as
-% PostScript halftone dictionaries, and hereby places this file in the
-% public domain as well.
-
-% $Id: ht_ccsto.ps 8469 2007-12-31 19:06:52Z ray $
-% This file defines a /StochasticDefault Type 5 Halftone.
-
-% Note that the Black array is used for Default, Black, and Gray
-% (not too surprisingly), as well as for Red, Green, and Blue.
-
-% The reason for using the single Black array for the
-% RGB additive primaries is to make stochastic dither to displays
-% look better since there is no misalignment between primaries to
-% a screen (as there often is printing to paper).
-
-% The CMY components are decorrelated (90 degree rotations of the
-% Black data) so that misalignment doesn't cause color shifts. This
-% is the same reason that conventional ordered screening uses
-% varying angles for C, M, Y, and K inks.
-
-/StochasticDefault <<
- /HalftoneType 5
-
- /Black <<
- /HalftoneType 3
- /Width 167
- /Height 167
- /Thresholds <
-00AE10FE266C139427851F4EFD0DB00060AD25D6164400C765227327CB0C5A30
-D90786049501CD2D0752018608389F2F159527851A9E07FB00AC12D226A13A15
-AD3E00DA0878006B384C0093085834790DBC770133A31E41940CA900510EC834
-B02746993E00BC0634D01B43F411C90AAB269616E012B140048600C84B077500
-5AFE126B1A40F53903710A8305319C21854011844701B96B00D112790E5A008F
-1150296B3F09E563277C4900AD50017109D4013B6C1A87123E6C0D79F626511A
-A90E86003EED01784629E737630E4778A53F22B65700C94909F5003E5E461258
-336C098600E15804F75C13A22FFA1FCA1BB5263FF412CD2F502269C2094DEA1F
-7A233AFE60017204852605D460136BA6118607307F2779005A336A017B005A9E
-15760D35D825B03404A527CF6C0865AC27DB225AC10F5200D6581FE9610D3088
-2749B538CD48246CC404F21F79310DDC0236CD1F3DF122A92B9A10CC5027F401
-BE50003285059201F8384A9A1A6A12C6005A19B026F6001DE2660D277F1F793C
-2276B901DB37B304F0401F79122E9A1A3476247C0D4704780D5EA500650A9E00
-F00F53278A005606D96C0541AB1AEF0EBA5A1933FC27045323B350009D1F4CD6
-06A33F25D21F3FEA2BAC5B01790D8F551D76013AB7411B7C00A93B006FEC276C
-07970027CB4505E6095A017808FC043A610E8901A4851B58A512860461400D69
-1D7D3F00A60D693A1ED05A13DD41305D12D20550BB27409B0D790085503A942F
-0173FA069B01AD5A062E851F6E1B772655C707B66C0046B005CF015AB9842DEC
-054F279750266F1F7C03D2123DBB64183DB612286C247B2F0078A1014679ED3A
-02DA3F12EE3914841FF24F0CA50579005022F827C33900EC2989155300E51140
-651996421B9112BD344A8318A45B1F7E27A41F60269E17BA5327CC2600BA4005
-6A2ED51A84C300E84A068427529E04862C03984B0BC400862675340086084FDA
-1FC23109D0045AC01A3C5512E54012D5520D9F00D10CA8003C6A4021D7601282
-27971A49016C24881DD53601E20CB837A72F4996012786004D79D7009E0750E5
-3D0F6CC1220065951FA060016CB5005D049234642749CC129B046209498512A7
-04DA269C2759CA04F72807C502624104FD0B71013DB400F11242BE4800813E01
-980A67385B20EB269C005A0627793616B923DB1840E51266BB3D207C276C1DAD
-04E25A1CFC223D68044A75217E12418D00B0316426830036EC2550307B1A9322
-FE01920B2AE9015210F127D113AA00700455AE1F8749056B00E51F5AF410C52C
-043F5A35CA12631FD02A0949B1410C770530AD0E2850C83C11C100E308316D1B
-51B72FE1066C305E0E730A83013D6C0D4DAF5032E115861FB026E0126C334C87
-01780DE24E1BE81350F78F0B7901761349F43C9E115A940B63037C0049910853
-00EA06AD10F42D940D40A90287009327F216AE29EA054DD20D8501A11DBC6A04
-61BD0546E501610E5233B2501D6CBD3B0068098634DF27A3153A7D002AF61BA0
-0D850838991F67E712A5014996058801419E6C0D27C91DF95A2274E70B248349
-286C1F78B201DB360079219426CD1FB335F825BB1F9E318501268600A82C6701
-552F9804D30C2CDC1E683B0585257930041FD927AE33C90A6D014CDA002DF734
-AE26CE341BFC259D126C34590178147D21643547D011A00583006025A5203F5F
-1ACC0B5A4115900F39981F5A32B439CE046400A439068A44BA4A2260106B08FE
-5A12D660113D5A4023BE51007F0A478C26FB1A33C22650F60427E26800853C04
-CB003769A501FD0AAF5412397E2386450DAF0259007F0562007905690CD51940
-F50E3D5A0DD438A106633F1A9E6C0553A112AA2BCC00B44250007F0E6B20A227
-C61F3FAA500176086C0FA15F01792750D404B95023C800DC0BB8075633633949
-C9127B018C07E8385033F200AD22FA5A00D70886047112791AF44813E33F126C
-04F8009F267E38059E330478B101CE760431DE26B431006F085D8600780D5B3A
-7A013EB54719931249B00626701B864000F35E049F11EF6B173BF43E22DD27A4
-2D47EB4900A361206CC82677007911F222BF590034C32241F901740F62159CC5
-471AEF009204640D81045B128620DF27850438B51FC7003F643C0C84325F2776
-267F13E001BA0B2B6C33FD27781498017E0E6C2979013483266C1FED27A42788
-3005955001CC1C902F7919C702B44B2064C03F22842C1261A00E6C055FD120AA
-3A14EA27B61FA71A8A225A07D9502F841F60DE31BA042799320EC91A5A0127C2
-650CA5500F941AC6125A227A3406B5005005EE53238949007727F750157D0032
-932452E0350512872F604023FC2AB032EB26CE2F9F00591AEE4809661386229F
-1BE4019E089904EB00A5276F265AE4009D0CAD00592DC31FB226DD1249A50DBF
-2E9F00490AD90053C63E207E265A06B50B40522F6B00F00D5000E20946FA013A
-7927F312397901C457096E048200C60AE7127F2700F405BE00500D774BDB0544
-852749B540951241860179420067098601AD11E549167F28A53E12BC0727A646
-0B7E03AF0DD85A0BBD0040934D3C01CF05B44F0886006C09780069124EC13F00
-A52EDF5008F8027F2E6B15F24936613E1B860E95044385236C1F40DD04603D00
-820540CD1850017B1256BB6722790E6100B30DE8339B275BEC01D21493278627
-791A68AD1F5AD50CA8009D4C178E0D359E21D630533862329D04B97720523386
-17A401391A67B707E4006C0833D6002FE61FB834FD5027D12789037039DD0961
-01953450E30437C81D60269538187827802704EAAB5A1B6E12833A1FD823A41B
-B527F936059D6A10790140AC295A12CD22A92C0EB517C75001F81FC0350DD503
-BF79117627EE501B9C63046CF73F24DB0847019D27E21F842E70006B04D80E36
-831F6309C301D9069E270086052E8F1C3F5A04EF2550DB00466019F10FA30147
-5F3E0C67D31241EE2361C47D102C7721901FFB4E26A7551249049226019A0D79
-1A50C00141731BD046008412669D004BDA470165C201F307BA631F00349927E3
-01BC5210405D3D04790A925D1533CE279A0D6B00C4400579005A860071057D44
-2F5F01914F27623D1A50A5076803C63D1FA22C0D61961B832AF8174E02A026FC
-14A81F8224934204AC297935711E603AEC4935C550006BCF22AE278512662EAB
-0577006C23C71AFE1FAD340198025087083E00F65001CD375E018604690678C6
-6C1052BC385A00F03E1F8213AD325A12FE20AF2F0E79246C09ED1B47861F7445
-0C8B56F40C791A3E630077C101E14A1FC82D04E557016D1DF3309F1A8F4B34D3
-1A3EFE26AF1FD713A64824EC00A80AF50042D421974A0AE70056BC0433C7006D
-0C63B93D1278095738C30B5300C64E12F700A21150BA0A26950D6513E933017F
-0B6700B904F7123ECF279C400884006D087D4622C22B13E173266213AD480CA1
-2747BF1CED2C0040E21A6806D9345E04A12BF90094047B2770015AF21AB9128F
-27790434B3112FD3270840AF004E9E20F62F0B7F19863A0077A43F1BAF0A884A
-125E3C0AEF0150920462460B59006B09CE0577422F6C228A2D0D793212AA2784
-341A874C148D27A636006CCF04438F01603AF430651F84265B27E600418D4F00
-B0237C075ABA1F52D836497C1D5097085A01DE502FB126D51FE95A0DA048003A
-A504862F007A17DD0E347C0B5BB127048C29A9129B23CA0C6B0E5123DF1AB10A
-CD3F0584395000AE0ED160005A950179A3136130D0046C079E5426A60DF16911
-52008726DA3E00B304D764267F2F12AF219D38E4328B40296812B304CC5401BE
-5B00F35F016C08DE4500F13D04D60759EC1D5033B51AD8119903A00CDE019D05
-7817862E04FC3D16DC279E3910952705910C33A6006B2CAE3B15941259400490
-003679046AC71F4ED41B56EC34B3009B502292360877CA40006D47016C1A8626
-78B23B07843143651FC52703DE6021844124E63916FE222EC304870E46B64A15
-34D2005A4021BB27FE0D3B661F7A27833500A01AE14207C9008504A50CF201B6
-5126820E359A1938851F43C4239E12AE640DA45A227E12308A0D97006A227E27
-5E266D2A5A38D130AC02CE5C1FA159046D00F64901E14226EA5322CC1FF90D79
-4700F306C26C125EB81CFA4110790B419805681A543A6203CF01F943185412F7
-1DC12EEB4000D5051F6ABB4E00E90D860055984006F933019407A64A05670071
-3D1FDD266800EB75123C950785024A1679AD04C107E60C50BA107800935A276B
-1B6C257A1F973E02F91F50E30648D910A004347E01773B267E1E40B100C44701
-E32450F93E00E10ABE00A608771161227D450D79013FBD12891A762F509B006C
-04860A5B01861CD26026781A38E2290C822F01B327E80033C30DAE04F013AC27
-811F699E0186326001800756A73146F5003E159227A5223BB00B2D791B50BC12
-771B8234D7481AF15B00A1127E270360B91DDA2760C46B0150295A401E96226C
-2F47BE3B12EF0DBA28D2003C5C19880CA500692F87016127E8521AFB4E05D008
-E403683B1F9D5B1582290852A5347912851FEE24AE00F60834BF27E71E614026
-AE0DCA083DB315BD2F45953D25A0033689019E5500A547039B5A1E7F12895027
-7E226D277E06490DA7002FE0490A963C15BB1061048E502677D20168094FF014
-4AD8009F0D6A3648CC019B11B2840433862249C93AAD41057B019C0E4725D61A
-EF01B76100CE04FA0C600278328101491178BD06D83159387916AD2150B50A6A
-00980C2F8F1F5A2C7911F6730A2FB001CB7813640546D1355001802D6C1F5696
-0068099E0CD154017C21881E61385A00F211C56A0C51B30EEA320B7F256AD117
-3BDE055E26FD0249DA009F2159E46327C65E0627B621D84B2E9D1FE1270AA004
-2A48C2377601427D1F6A26C704EE00296C265D4C0D52BC0BFC015A0E791FF824
-5933EB008D0B7E316C112686345A1F8827D31FB22357FB641E50276C00C412DF
-5304F0123E7727BC3848CA013F9F00B7502700CF411B723604B922ED1A5A04BC
-400FDC04B44812D828843270003EEF345E00FD04D612A4277A0034E6162E7422
-50BD1AF71240AD006A34C601469414398510CE0047047A0C3DAE790052059000
-6C3E0068CE3456E71279059B26D101A508862F53207BB509EA0027D716752740
-7728E000650947B513407020B14903A03FF8470A994000A508500097054709B0
-01EA129E276C01287E279200D3065A02851260EE0E6A3E049E61126CF00E9B48
-2C880095277A19955A2780143779066C01F823B41A6706BF50266F218505641A
-B456046CD700A804663D0088064F9D12851F96360DBC601C6E30921BBB23EB1F
-50126BEE4119FC0CC578204E0EB0005020FC12502F8B12F54100A963133E5A1A
-79017C4300AD08C5045738C13086009504C8510536CF27007819B401EC69153E
-E76112D72A7A22863560420D963FC80DAF1B5134791FE227AD215031C714DD1C
-3FBC013C5A00DD1266420DB501FE3E00C4055FEB26B820A412920486279A1235
-A30DC34131EE3E072AAF1F3F5A137B26CC5227DA203EF2045A09DA6C002DF50C
-B1086A3287009E05D03B0D7F355F305106AB01821A3FA06C0064AD045A38601E
-CF350CE004AE39C63E1DED3665254D911A7F016D21DE276C3412E5700962BD0D
-5D2B7A1A3AB7770D308626A200DE4905B900FB4C1A603C0564FE12A8400D6C00
-780893017926840D50861FAD274BA605E638692F540D711C9D450C86003F6447
-2F5A11C90057E301794A00840E5FCE78008409B63AEE0C771B960185086130BA
-285122A549017C2750FA0457376F2E5C019F1ECA01A41A8927F32460DB073ABA
-3F1DE222BD0178064977228549126AB55A02890EE33310B827EA14A00D841BA4
-5B002B961F5038DF1249CD0450005AC5016B177740138520742E08B300E76F2C
-0185005DC226F82AB81F5A35AE01FD3104D70B880332791F9913CD21AE27F235
-00CF1A57E408C600DB4926783A1A922E13E7269B014E1B46FB4B2701604300BA
-104D26C01479009F0EEB1A863E12D30040A512CE1CF216B328500D8624E8114F
-038736129322580D7A006C0E50E52AA201933100F9052E12A5226C009A460094
-0A40623C01FB083ED05012F101A4058C00328527F62042AB0DF03403A427CF10
-A86822854410C1471FD92F04950B810340E812476217A4492C6A12F96000C307
-5B047E0186084F7C26782F1290223C7502F10AB66005D25A046E1ADA27AE125F
-0279D80FA5315F37F86C0150E526426C035808C15026831F613C079200406C04
-E3642772003DC06918D15204EC01CB319F279134118726F318C45F269550CF06
-41C05019F5651F51CA00BD5A2791197804AA2F6A1F7926AD5F1A9D118F05387F
-2250C90E50017D3800D530048A265B9A087849395A15CF67009E09CA41007907
-C338501A924929F24334DA193DBF109A02AE600154A71B6A29821232841F3FBE
-34A1087D009427C43F226C1AE3019F0C2E87203C7305B438D12F5F01A20DE001
-B56C2550BD0F9D3F00D213AF79052B98003086276A268208F904B35A006C0B7E
-4412831B006A3495012C820527D604792E4E127800B02760410DD44F0BEB4507
-DD046634E25B0095066139F55E1AE148145ABD1BEC0C32B31AF000B2334D227C
-276C208F26EC541A7700B2390C7800860B6C48A5046133D7183AFA4006C20DA1
-0055FB00AE0C6900563F20EC50056B0A870496277E225AD105B200CC50127900
-9B1FF3316A22854212DD0479275A1B8C095A40225BF70F62C50D791BAC135A2F
-7C153CDB1FB32F00A508DC7816F21F52D30DB144803C11EE05AC21DB480BF600
-7934019C36127F2551BA005012D427B41F92002F99046B9E013E77007D400186
-276C0E7904F40CBE00E0055F3E019327E2085EDB26AF22C627007727F500499F
-05771F84307A27D3224279249427F714B9730D33A31FF32FC0125809C6004067
-1293401EFB27650F7A069D04C42F00922C6034F70CC5253BFA0EB60037851F40
-A600F10240D4004AC40568400351E93856309F3E0086096835592600A9602274
-298504388626A722C66C1B54C200B03E1E86267B1A6901790CD05026BC0B32F5
-0F4BB524DA5012BB21DA279B1E503284173BAE22D011A41F852D01820F760151
-E712541386243E670FCF00E9046009920437DD014A08922B0141D40162430071
-39FE49268E1EEE3256088601A422DA345A27771A5AFE4B0BC800497E0150A201
-681F994804E2085F334972A20C8E1A407A26CA79156404BC0F04C24F27E014AC
-01FD6C0D30B700E2125ABD016611941543FD04602F6C01F808C50CAE30FA233F
-6512921D41782286340775048343015A06840060A40241B969017E0A6338580E
-AB4A34F03047970641C96A08E301B850276C2050A64617C1651C5AB66C225DC6
-79123B8713A64C047901A407790EAD1FE02676127E00AB0BE600AE08391AA426
-961334AE166C27CC510BD72F509E12C227053A6124E90DAD003A09A2238F1F5C
-276C1298037D22781C3ED1501A6A34791F5030D83F068100349E0DD212992748
-623D00830E5AB805EE005ADA00AE05CE5712A31AE4349D3F17CE3512E5265312
-F6492FBD15FB4005D300610DC41E3A7E1A409421792F049F12BC300DF4355000
-860D4700DF0F492151B206E53D1ED715502BDF38610093045A31CB394D208D1C
-3F7942BB6C017905EA5522E5049E0032831F7C00266C017FDD12BA5001752753
-FD4C2DDF004FF9A201EA325439CD0A9C055B01900DA101F509930060E82EB652
-227E1F406F0E9F04E85027A501356E278135127B276A1846F8276700730CF265
-23AE570779009A270684006D04A32750911A9C0350DC00A90434C41659EE3685
-017C41019E12CB28F01F77308604FA006C265B01822769BB0D5A01CD2E513AB0
-005D05F061046CD226015212DE4836680086103E7845ED06A812C73EFE4D1D3F
-6B042B9A1FD3126201760D82380A1D406006BC00613146B41FF727CD2789256C
-1AAF2650036908DD014FF000BF412F6C14C91C47861A9F0DBC5009E601863600
-9723C426A52F048600399F1FD43450B71FD830891B7A123DBD432E71118427F8
-5300AC0B6D0049E11AB55A227906990153A50441AE31980ECF2BB5129F003486
-1F8816A611F50C981A940D27B9380E67EF1F7F2909BC1AA82750BF08266C2C58
-3670045A0AAF00963BF0085B009E27C426AF1ACF657BD81F8E238512E5004C83
-086800770640C4500E7C17CD1F9C263E88153A5A1BD80188065DE400CC043D61
-1F9330A51FC35B0D7B0552014EC61249FA0B89490D90003D62124ACB00ED0A5A
-01FD1AB7490969108828501FB12708633C12DE2F61267E340BE31B64175A3772
-0045620AE94205FB3A660480216D23DA3348820054AC05349400A561267B0DDB
-016339CD04B200F21F9F277B22E848127835BE4822841188007929043B00480E
-F72C6C267A1B3DBE32AE12DD65003CF001A236830D5BB30466A50382106A26A1
-3411702751FE00CD04630D6C0244EB1A3EE1791B603883206C3101ED1545E104
-B301366C27792486277900319E1FCC4603DB78108040CD049A00AB0EEA19BD47
-277900DD05AB0CF21AC72F5099275B00D53449C700405A01C415F82F19834A11
-C63E04F5015A1F952285125D1A920E4900D210943102CB500E6C07F5015037F1
-0B43BA1A73B35A01A504C206DB0B7104415A3A1FB42278305A1249FA0027E02C
-0CCE23B22BF60042BF25AE14772D4A8622F329981433AC690830B500D606AE04
-CB64235A9F1A772560980CA104C8079F0D5AE2013E602298330154FB0027752B
-801E6A0092027112A43F268E1F50318601792603BC0C931A84270B78A80E8627
-640877BF00E42B5B14874531C84206FC0047E44D266CC16022720553AD3E00A6
-27811F5CCB1968269850E9074926861F5736932F5321E9159C01870B5D04C509
-D6013895451279493363007B1F5795047A014408A3113EB1007A08D15A00279E
-41166D275A27781241AF022D860DF53E1CE3224E366520CD391277B30DEC0641
-BC1A316CAE0CF60649D639503AFE4B01C655036CCB1349B012E048186C25AD01
-E9632C1BEC3A05A44E1F573C0D9E01D8501B98127F33509C187701B604380AAB
-2FE21A64237F1ADB00B42F047901D43301229413D10D3FED106001A579006C23
-FE2748DF4B278022A66B1A61AD009D07EB500ED2093CF01F5ADB6A26ED055A40
-1CA0480F76DB015DF704AA0CEF00BA280C6CD6004057057C015BB400F05001A5
-6B34007C1F608E0A689D13503F2095255A10B5055E0C833012EA390079063692
-007738F04912793E04BD53016CD53F01E104AB6A207B3700B3096900D10B3DBE
-0D427E40EC501F84009B09FA049E39540D763EBC4A108563AD376C014DB0009E
-1AC80D4939BB4E0EA800770D8D006F3307E5043DF5216D18359227771A4C8E0C
-48008D19A722D76C042FB41F3E92112C861F7B35651A79FE3B1968AE1FCC27AD
-30128540117F2904F74827C5003BD82600E604C16001CA05791F9023D21AB16C
-095AB222F95E1D3FC1045A00C44F1F9D36138F2656129F25851D40FB07499126
-EF2FA4278A21662ED306276A01C612502D6C46325F14962AEF15591FA72A054C
-00DE308B2278266B4127F21262048617611FC028F612BB50247D0D4C8601AE5A
-04A500BF0532C61EB53360017E103BFC6301850A4CCB4805C44513A14F005408
-BE3F0F7100660844CF0532AC1FD54A0D95125086154CA648276C3D1B8C32A729
-E70068347A00279D3510842800D0640D811A9B4005DD0E61FD0AB2007431500A
-C9005F27CB1278016C0D6005EB0092125AB11B912767B804D60CBD01E10A6900
-A008E30041FA2785175708FD043BE20086049F1CD33044E33C0194053F5B019E
-27C21C3BCB4012E62F6B22986001804B04E4502695005020BE26EB270183345B
-00DF0638D126994B01E929A51FFA6C185FDD006A08842F58DA042EF204377809
-B300EE0A7C006C1251C01440F15001D84804BB78122D9F26D83012942586002F
-791F3EF50DBC65277E179704611FB127DB1A8634521EF431006F07F8003F5A1E
-8523794934AE26497B2660980CC00641B9651AA95F12B1502B6A365A008F06A5
-52206CAF1AD70F6200910A5A0085269E0FE03E20F92B1182350DBC27C815790B
-500069B112E71F80265A9C0E840434AA227E0B853D01B8471F7A279E1AC1003E
-A1661F9212D7532482275A1FDD269E36089604620EAA1A9333520841E9054901
-6AF7005A38C15001CF5B047D4101F008B94134E750088400AE4601A576047B41
-D950227B14973A01AF28008A05D83101B70D356B542F9A0027852D05913D09CD
-01E80CB41A3A6B13D43100842C41E15022F327B61A6C044162007A085ACF1AAD
-6601740640DE34AB791A405600A410BB31026C21F173125000DA4B0D93340196
-0CFC02532788125505BE00693C01970D44B84F074101F5492BD91F8B267800F6
-22AC6C1658BC791F5033D3086812994422AD2D12954B355A00820D2DC049376C
-20DF133C26B911380CA527CF04EE61125AF81F521291501D78D9021FEE1250D1
-0D50D84B1584227413822853F900790A48EE500886032F9E01790549FC39B40D
-C914AC380086243FF01FB1570071052EF90D982F613E0179E114A72F013DC06A
-2F14C42661E72E50216AD00B39EB237E2640AB18F82ED301791473BB5D0D8300
-6C4404E13A4E0E82022FAE003B09A5048C158426EA3406840050D83D16AF1FD6
-26A55B0123F6049B0A4BC960016CB66001850E792640CA390D6CC23A04F43D00
-279F7D013E860346960027EB00AC2FBE4101982440BE279E1237C322AE6C1267
-31D0115801702749852575450BDB044B890E2F9E23C649046C26D308F36A1F50
-3F005FCE8106269D5A0079094F04A8720041A25000AD10E55A0C78227F1A6426
-FA004A1B9E22C812B42F5F06BE681FDC5A1F71F15E27CB1F5103A6005AB71BE4
-0F6901850573096A0039CD790F3F5A3085002EFD234818E932571FB2006F05A0
-40009563146FC85A123449C71939F612407E21794905610DDB4F0F8605650149
-79006A0C3AEB25A51E86279D1BD83504EB01BC551FA0310069F20861128037BC
-0178225012B205C57D1A491259EB0438F41DB022CE3A17E3270679334977013E
-CC00B3044BC7460E9227D1035033690085129B3100963701C70B390D98013FE5
-6A277D0E3876278E24C027E92FAA14FE77122769BB00E511A941088200944D08
-C53E0B8817DB501EE82240BA084504E40A9104A86C2460B501C50834F81E7B26
-04CC502BE734B31EFC27C956007F085A00C20C4C00A5551A960E39791261D538
-158B28E3009B12503A9F00882B580C26F700A334186BA50F852A770056861161
-BD1AFA082BB61F6C314892105B01B52F791261B017FD3F24EB1F50D311477B26
-54B56C2350AD3912BB1AF45001C805520B79006B2383330458A302297E26721F
-65B413CC3E1B79006BFA2D673D04840977015830A22767B0225F3C00D0053E5A
-19A46C003EB747773E1297006B0D83047B0634AD1F4EE73C2162F277122F7E27
-60FD00C227057E4501AD1F6D2763E90727CE3904E87548336424D778003F5503
-E0129D3004B2380186266294058612F00D38E12799216C04ED38007E0758A401
-79045C29EF07A1044800DE0C600093043E630CA3185FF94132B41ADB014AD41E
-40EE500B9C05DA0250345D04DF26B2194702B422C6279B2DAC10FC0086180047
-F30E831B9F0DF13350129C640127ED00B51956D9274AB913438B04D32D019E77
-04470A5DDE05B7012F951747A41ACB5A0C8E05CA0040A86C184EA53D1ABA0798
-01410DBA26D249216C0AF65A1F7E490EC7003DDE2750019E5A007A09E615A623
-884120C12C0D8C34B90C77198928F9139427851DFE2F4AD1207A27843A009A11
-49900D3E98108B006612D3355A248C1AF2109F2F860D3AA05A1081005A12D624
-6B1F7938D231851F9827682F6D1F8C00DF2A0BCA5B1B6C277C31088D002460DF
-1A650EA76A1A3EC51FB22640641248840958EA006C223DFB345721861D5301FC
-0B60018B116C27C4802E65067900BE27A73607CA00EC2F50A51A5E04A6662E14
-B41F503482006609DA5A016BD642196338CA500175216B2FC1013D6C098600AD
-06DF02BD2651CE032764BC055D21BE26A34A00AF3F00A5277D006C055AD10029
-E21C41F33D01940AC44C125CDF095000E005B801CD0C6B2546AF3C10AD08FB01
-A64938F17430019A26773606FA005085067F01C836ED21B2263D8610AA036011
-B33E0AD60F7E237928DB264FE3045110FD1AAC31600D82004497236B12890940
-760DC1401BD46C0463C60148D126A1123993105000F808A20024D90FA9007C0E
-50CE13A4227830521F742E7A133E72EF00502FF43D047D082B8614E86B0C471D
-BF27F7213F9D6C0461980DA453277F3404A901223FBF5A137722792751A70486
-5000782E8321600FC702530BC44111F300BC57248D1034E322A10D70006C047C
-014FDB27921E8400F050279430C500AC0C9400389E1F78005A4313ED3F1FD56D
-0F4DB64721CF00F6345600810840FC3B25861236790154F21EB2279C216E2744
-86325A37E31E9C25644100EC450DC35F10A700E407471986209E136CD03348FB
-04603A2078D750127F018911531FAD3401733007E70043F12771A06A023CAD34
-EB0E9A163FFA3A1AE526D004408E3B1F93269D1F834C278740147927D244006A
-287B1F9C33D31FBF2F077701E24B306604AF004812861F5D32C06B0A50B236DA
-049501875C052CE4015A02972D681F9012E826AD1A5600AE07F3501FC6320479
-006C0653BC04EA4E009208604006ED04B2335A05973F01F227822269B93B0ACB
-058400550DAA2253B806C9016105A4386032C300EF0B49D220C26912609E0D82
-16062DF9106C00564000D9096501990D7E1F5ABE00E64E08D6006405B1015F09
-E201A90C5CB516F601C3450C5B3F0F924913B240089E12792060E56C053FF404
-5113F12F03720F7E27B73412A241197E26F313840DAA046B2F77018C277C223F
-8400AB0E894623CA2FE0123E673B1AB926CD12B65727771F8612CB50268B1A50
-04A331009653277825B01F770185123E922C4F17EB480EDA0746924D27841277
-0040B73B1D6C00D994501F8627CA1DB461268720C22F5B00A312376912802E5C
-34E74112D5389D2F501A86043791083C591AA500F16800F7375A1F7A26DD28C2
-0D3C26CC502285277D0163D01E9F24691754F9006CC306A3395F04DD2550C306
-49D712BB13DD5A186D276008E5601281268F00990C87055A026C3C009E0BDA01
-6A3B00E20A3EC9630EDC4A12FC0139E8113FE3501ADD006C0AA37A27018E22AA
-133804B501FE26961A5704CD26B0366000A504660B7C0236AE043E7813DC344D
-F2059E3E01AE0E85199233561B6D00C66826F054246CAF12E527792D1B982385
-04D100A50589014693007808AA00D41BB526405A08EE00C80B478F1F3B672200
-B551279E0139851F3E5C0268052DBD03E01AA03704B301481AC527E2203FFB2F
-A717F31A642D40A918792155AD0039801D922D409C50008866042F9E27AD1FF4
-340068C12F560069E3781F68305A05E0278A1278411A0DC82647D74926F46C12
-50EA006C0C8D03406D19D5501BFC046B0BA600F40EAC3D12983100D80D406204
-860850BC05660DAD275A346C1F5AEF15B42C561269394B058600AD37487A2284
-3304B20CE046783E15791C63EB0DB000F337A545780C95306B0083402175F760
-0E7903507F107201854935B500780DFB2793056C2EF7065E01AE08611AC6310C
-B36B017906632649D61A5009FA751B490C50C80DAE40106D00F64F01E5793280
-125A01880631D11F5F27BC5427CA1FB43904862748A022C8278520405A05E702
-4E7920A301CD3149CF125E34D74019760CFE11BD2E063B611AFA36B014E6611A
-E1118B022FB001D85A14850027CC0EFE00C80A317927861F6D2700F7501F7B12
-F926D1530A4B00B74935CE00AE22D839047B124CC44801A312D626871F4EC746
-23DA27A4055AD9183BF91255C40E9804AC27793E04BA26A20037830163CA22A2
-4614962308B201FE27A81F5AA10D9305854101960A5E00974A0DB0003D7A016C
-0761CE2695223BD014872D791F9600379D037D0056E901A02586004779D1009E
-047901830B339627771FD75C1A6D2640EA315094036134862745BA005A06CC0E
-B65C123FC900A541057813A527943012851F6C27630B54C022EA075A1C773262
-00480CB3036B0C8C007A12762640850D4A9126006E31415F00D01488287D1ADD
-571EEC3D0B7B3205AE29526420791A920DE23B005023CE2F15FD223BDF3F17F4
-3056DA1D4FEA15B63E0D770063A5084700FB054C12ED5A1AF922A01B33802760
-1369E10A406D2F591FC62650BB045A06A6470EFD099600780DBB193C9D065A01
-9A5023E14D277D0435910165295617C0326902D7085EEF01A90AE6129E31008C
-2A9F26DF04BC1F82E9601A9733ED2A5C36F501AD0053A7043AE343B205EC119E
-2F5A01EF076C2F039E4B0087195ED44001F100C72E6700466C1679F03D006CA9
-064B79128663017B26089600288E4901FE19C0421D6CBA5A2660BE6B2706902F
-500EB94309CB02B53D1E9222BA0DE740079A007627F74025009E2A521FBF2266
-0549F11FB812D73F0492380D971956D926AE0FE8049B4700F33E208616397626
-5A347704F5431569017F1286276C094101D24A007310C01A448622EE1F3FCC1A
-600D2A871F6E400DA53D239512C6791627AF32E100550E863A9B410EDB39B604
-C43F0465A1125335B600C4062EA21FCF4934BF690532A4277F3309ED014A0E92
-0A450079B84800C86C0162961F79490EA5015A036413884D2FEE1250017DC278
-3901A86C043ED5307F00774A35691EFA1266B101EE40007F1A3D6C345B1B850D
-51B40048A306C700B525871F5DB20DD3345700F614AD227A3B21B81F49049507
-6B3B0B8D004F9D01C86C004CC201DF1868BB005D40085AF7126A26A41FBA5013
-5306864C1974275A12B41B45E4017F1A6A2559E60E5200880A5610E05A127002
-A05A278225DA29AF1CDC263E0D831540E13B05F03100D94F35F52CA13C01CC12
-6037AE6B11340A68D33E12ED58019110C52C0896007927840050326B1CA00A5E
-CE07B300DF279E226433E01E692F81124700CC063C6E441AB438498C0151C60D
-74057CE15A26D816BB5027D5142E783519F62363344992014F34E722A6370093
-0477087E2F04DE1BC13004A00CF9008D267D0C319E27EF0D843D016CBC3B23F0
-1B783E00B822D93900C60B9F03720686500470E623AD045A257F1B5C9D24078D
-12791ADA49279300800427CD4EE81450078E4622A4276B1B5BEA27C913B31ADA
-26BF04762FFC401F772780135001CE0978019E0DFA045BE36C27921FEF00930B
-790529E4300457FA3450012F9F003F6201790665E9128645089A0C860627FC1F
-86057201D54A20BF2CFB124D9640790161EB402D694834D600BD50116E004ED6
-1AB241146CA40446C620942D60057949186A305020F63411CC38016A299419D5
-00B70B386CB5276705AD00830950C41FEA5A083B009D26B930008509F700AD39
-01790B502F60057F114DCC0E5300AF04F00C3DAA6C1F44BA4927792695204E09
-BB035A0F6A26DE1FBE5B126CB127129422AB670E70B012FD27B33804A500BF5A
-27D01BB86B12520EBF2D9E13853D0B86013ECB002712A32251008509AB055A38
-5F04DA218D3402792D07F60150318501670DF818920DAE36F100BD7901427D1F
-55B212F70B84326C2750FA044100E63F216626FB330F8743157AAC601D780363
-D9125A386F0E48922557E3009E3E1FA73902941484256A2B5AC3042FFE0F5705
-E800500BAD1485223EA42FC33D018234009D4400844100DB0B38EB203A500986
-0F56942277330482013E500079CB38600C446C04E4652258A5195FEF8B09D21A
-B324E21A9D21F41D9628AA07C75C0FA163228012D51A3DAA4E036C26E11F8712
-643D0D60A9009D0A307C225001A20D8A007726CD521B6CC60C9D01A540022DC1
-013805C72DF41F5234B11ABF29DC05B701357412F45A00E46022BD36D3118600
-428747008D247D1660C7412DD40149F2007F08599E1169CF270CF01AC2661B85
-55009204D0781FCB0040F50A49DB1F61F822A82B049000F31BB8275000C43805
-792144366C279304502F79016B0D730162127A4423ED3600C527AB005AE70629
-CC319D006004459E1FE2321AEC275DDD0063D03F1FED27C3123D7B0EA104387D
-276B1F6FDD651B6CFA4A16860D77019904500C7E1D6D1264A409854226860C31
-79015A06A620E62708D66913C52C983A0486006435AE12601FD12540FE3C0450
-A732580227A2042DB41D6A4001622C7F1D5A27950EA13604780947E21F6C305A
-00970F7E1A69F211B503E600770E61C40149CA27B032CF27FA38009705864712
-77268C3412865C00781250B829D1056C01498407760140A33B14AB4B04600A4A
-AA01642DD74F00E90BBA054D00B4270C853F00B528D01F3EF067049D33FD4020
-C53101D11A43B81EF22771346105A3541B389A016C08D9274CEC1A7D0552983F
-04A500630D8D1A710ED7794935F46C073EE026AA23E311B405C800792654AE15
-D666113EAD0DD73549ED269F013286265A47A826F534127F390A88007B088504
-50BB135A1BCE5003FD0569BD401FA726F1340E82163EAE2CC812B122C4105705
-790075369A2FDB1F50F3115A23951F603097228512469E01D451269306498300
-3ACA46005A087A0050AB0D9E6800800A9400DB177E3412BD5A0DF027A11FAE12
-409F0DD93B01F76C14791FB42CEB01462608BD005012CA5A15770D84003E6C2F
-653F1AE80030834100BA5B01751A8303405C0CCF4B00C70D3108940043A31FFC
-5522E71A4E22A51F6931DD3E0C9D3B1A990E5001E0096B04864A00FD62097D00
-5A38851A7727FC29C212E20669009D08328200C20750D21249F3085BE01F3A65
-1A7F123FE222AF12581AA526BB27E61F62385015DD35561FAE279E01F678002F
-851A4F036A0092055A30771BA90D274DE2470077225DB77F401390219A3200B1
-04F9334EA208F001AE5A0D6FC90527983416F826A50ACA14B239531F7A2782DD
-671258D006870035770E5AC14001E50A8601714900B95227EB26792140B93C1A
-C8375122D42650F80449E000A60D7F1A864927BE3F226CB81691277735048600
-36912F0079B305EF00BE60016C087926E81187046A0D9A05F803864812C44004
-790D50402267DD0160B937E25026FD22BC00683348B9125A26CF129B054C00FC
-6127D101468622405A1AC3125D1F811239B5401F53EC024A93057C2F61246C00
-9204E009AD011E40BD3C2173275FBB04AC2E006C9E265B27A910F32F61048500
-930CA36200599901730C99018E0D2A9E12348C1F4A01AF340085175AEC013E58
-04FE1AA94728C15817AB400D552B6C344F0D8827D92D9D01612F41D750237727
-AE30017C0863F9265ECD02B50E3D972606870B2F7E01700F50E0067B00850893
-036034DF12783C04860D5BEE1268C6009E013B932847DD0469018D0B6D23D327
-5010E300B634FD1263266E375FB2006B0C9F01DE1141831465F03D0D7900D21F
-8324791ADB205B34CD3E1BF62F12DF27BF1E5E35B16C0065B5045AD86A2456F6
-0EA504317D1FD3420D8600E20C7804D3016BE9199612A125F91AA100811F50C8
-0BA70132C700860759E822A23301951A3A6E1991044AF4411D54B312CA27A536
-169627EC2FC21F3DAE1A5A30C616AD2E751F3C99072A7C2663D706B90050921D
-F427C0123C7900B45A27861A7920842FA10FF8042B8727EC1C5136980229D505
-4F18C73492157505C500A4093FC0065601780A7E46077C0050E5054024E93F25
-840F4605CB0A396C2146C70FA400973860264BA01E5026891F503D00DD075A02
-68384F0DF50436791F5B9D124A21CF193A6C00D24510B205EC5227CB33006ED3
-00633E0984005CBE01730C790150F509770092266600E609BE004FD9490DE81A
-467718840E3EAC07610049A60D693E01C40A5006AE02D7005A1777D706490078
-BC1547F2512086247A006008FA2F543A63314A7C1C9027DC2A9F22AE5A22922F
-1378C508580DC819EF2C7C1F73B305DC60006C26791FD909B32F0169F63C08C5
-01B8772340C731B105D561226CB300F73E056BEE700C60A91285248E4B2A653F
-007A126BAF10319520F54A1BE5203F6522AC1D3AA2218527D54A04A2511F9626
-823304A03C04850032FE27CF22592F8638DB1B50FB137A1F40ED6C276A237C34
-9D22106CC45C2E0590006C08B301C22FE025A44901B40DE802B70DEF006A0F86
-00D50434F105BA69024686279A013E7700B5500027943415B22EF8115A018519
-6CCB4012935B227F300A6AA60084217A132F980F3F268517BE42012797012DFE
-055009E300C20DA51E9C042750C0087901873C049E09F15200D867044901A90B
-37EE0D347901680EF76C1761B327CB5A057A019F00EE0CA50688032F9505A162
-2600CB0DAA08E60161AE254612FB4026CB1F9C355A1288046C0E3987266D1F86
-22782746B84926771BA364123F521FF23200D3215ABB0C673C12F25E01794308
-830449BE4427EB0D3906BC0034DB0F4AFE1E3E5F12EF0149C3004ADF5A0C732F
-0EA14936C34F1D6CCC3B1A83226B30D93848E900664113B026C5552782123092
-411579C95A19429B1F50C117D62BAA2700C33F12781D40B11354366B1F792777
-22C65A24D93201BB49395D31541D862F009504850AA5550E3E670DF6501FB027
-EB6006D000AE355001C7095A01FC0C5A4000759E00840C5FA51284045034DF04
-A24724BF0DE75B27952267127F005AAF6F2762A3044187009E04D3285738851A
-3EA00530B500E2621BD8005C0D88300075A40450F9015A0D86159E1BDE345A00
-750DDA0046C42606FD3C0D28E96C0580005F4008900244864E09F1019D0D6133
-E909B95012E000603F0084094F78119704F500C3400BF0791FE14C31640179E5
-00A42700840C7900229A125D4112F8611A8314984F37C01FE92F1AD027B21638
-6C28FD1C92207B2F03881A9D3B00CF0BAB00E01F9E264801E312522FAE15502C
-6C0D8604A908EC6B12638A1A79390486259127E702B75A1F40BC3D1B7B22B305
-5F2F6E048611FA306C2850A50458865000B56A002FCE27B212FA6C2351E8391F
-9524682FE100861A7A41049B4934B512E91FAD26E43F1F77278312A450270860
-3C00B822D31F50327841BD33D93847C44C33DE049E0838B326E332058101790A
-AC48086A014AE3009F0D6600AC1252CF0C416426901F5A366B335004FA0E7A1A
-9800EF0961E11BB8401FDE26792A00CD3501FB2250BD0C4F12AC19674011F108
-5F00A30AD14928F501BC52259D490AB403791140D212279735129F4903620C87
-3C01BB0B6105D30153BD04436C24C5002FD42701860B6A367F016C0D56D10CB8
-053D6901CC41A8198F116C049F08C726026C075A03A52700861B6C294A8B0466
-0049B025DA276C128B39FA3F8D1F712749D74726EE005E35FB01BC063FF102C5
-09B56C1B4CBC46276E268337017F065A9F00500CB54F22AE5A1094006034F16C
-013C9F0584277926DC27923400850E6C3E07CF0037851F3EF42494013FE40450
-DC267920F136571D9426781AA42781361A8612A55112945F0769F81D51CC0449
-F519B200346E2059E1167F1A7104D82749F3472781144EFB1FB22A79186DF30D
-42BF00E6113DCF297C1A64109301E04F006D2604C30AB60158057532861F8019
-79124F8212792085263B97006005CE0CAC02CD4912F23B136CCA335E0394063A
-7827D3189E0426CB5A23DD14BC019F0C78045AAE1A3AA01F881250E405C66000
-552CB567228A0B5E01BB4007A600DA0640E33E006D0EF94A07D23B02FC3F21B4
-1338A900299A152F7C24609E0192370049BC37FE510D7E01600CB6013B950D3E
-6012E9500C582F96137C2051A3069A0BF400B62F603D1BBF12A550307A158722
-C60EA909C900AF2C47D500B32F5701E80B4FD42077327B1F6922A7306401BC3F
-018D11F51D57E201A5096B294989410779007D365630611AFD1240DF5300ED4B
-2F77217D2D1278DB064F0D771AC731700E9D69277621A154126AC422AB008F2F
-6020974F01780C8C5A2481450FD95504D43A12FA26B478105A011A329F21C91F
-92285BDB0068D204880035B401D2056630AA016C275B35436C3F07C804793465
-06D70141F230691A802777243F6B12931D3A7404D03E1CA42A063DEC004AF80A
-86007423924D1CE4266C277B3412822750ED0DB7002EF71BAF490BEC04C45024
-8E016A0DAD4202C00B9D0147B20C38871FF300A84915FA3E2302D612862F00B1
-04317C136227B800E50B33C327DF4604F008BF740034861FAE520A6C042FEC26
-9A5EC200502F6C00EA0945871D3AA71A409920812453EE0B41D012FA00C01EA3
-14855029F0169E274A94115A00DC5001EA0450D908E40150F418600D9A64006D
-B75A1986123F5A34DD15C5052E980E8404A400D04808BC0036821C51980B673D
-21951F6C3E007A2FC726891A359426621CD96A225AA2006A2783390880005AC3
-49345C05EC6C235AF50A51DB04406C124990057E002FA31B5E3C1F66A6077900
-31851FCF5A0079083D126AE706B156277C1230AF014977DA076712B93700941A
-5A3147730D5704EC400E97005D0AE70034C5279E123799218F1464275A319605
-42A8295022FC124C019E26C300B504439D0D48FB006338D814771A863E1F76C5
-0541DA224FC202D90050B116D40D9E085D04D36609F001A74000FE0432CE11BC
-0554D526A42F098500AE39500DCA3500972647851BA431CD1A6614BB7701409C
-01E10B40E91248EF01A1451BB223D403AD4114843E129C04CE520CF42701532D
-FE4F048C4623BC008F049E27D5346001CD224DBB421F866305790845B30D602F
-AE04C000B40D3B7F00E204AF0A952FDA126C29792790225A37781953C007435E
-2AB201FD5015593086017A063285267738048627701F3FF93350127E2779340F
-92184575267B1C9833017812E2661EF52492017A1B864319B90C36F4017E0451
-ED3750115AD12379279322602E9717683D0E9005416C943000BB4D01F7223F6C
-2384166BC50E9F0034791DD860126D27E419680086239D2786116C03B14721F9
-1BC36B0050FD00426C35762750D322861F794738691D488104E60C6108F000D1
-03863312A622EC045527680DA300E60EAC17FA540DBD12F25A0FE501B9500080
-26AB00C60550D4275DB908EF015927EA601F900038970E5115DC27AB03D25B04
-6C9E124A22B32C00871FF93406AE0D5800B305C90150BE04E54F33DC1E0CF179
-1C2A910B52A500E105AE4026791F5BC70FA6013EF705A7093BB53E12DE084800
-FC1A79390D9A015A3F26D81F3D790ED00BF71A9F005410BE3005D600AD0539A5
-2040CD50127B26A91FE148016A119839C203CE267B1F6027467800A12F820125
-A645346818A310E71C5C3146860779013485133FAC004710C22750CF0441C66B
-076310793E1FE52E0067DA6E0A60A10D740295651D3AFD41146C258D371A8627
-0985005527500766D51A3DC81239622F5A009604D540016C2A84144A7E1F5985
-0D79501C75BE612652D000DF4F31900477079302BE275A46016A123AEE70014E
-96278516F56400549C01339427610679009E2FD2345A006E304A91043FB304C9
-263F631A49B83D76009805D0287801409F0DF716AF20E85022C7630D6DB63C01
-840C5B3283002EB422FD4900970F50C23D0627C71639D426B92700C772047F34
-DB4A07F95F006CAE2062C48A21B53502709E004B9C1BBA12EE193D65269D1FE8
-27AE0134CB0045F601C43A044A0BAE043C653F15B422E51EB8336012861BA433
-BA4879064126EA1260246D350DC92F116CB31BE712BF39590E6D05A50DF4219D
-073CF069133B6C10D104E505790929C9204912862250C104822575003D690098
-0430DD28046BF81FB326EF1C9E40017F370BBD2786015A148F44018548005F08
-4A88451251BC01601F9C122BCD3910F437040E6C0049E30D4627FB0475017E33
-50A10DF0065300770CDB5E2695132F942166EE1F7A2C781297097E01660C7C49
-16EC4000DC07842601CA2DB2630BA500DC07B55A1F74FE3E04670080491AF826
-B85025811A6012D92253007FE00199482B6C2741F253136CF76000DA08643D12
-A52953C80DB51A488416599B133F5A057E00750AE2501EA360146C30EF22AE00
-F7571FE52FAD39EF0B2CE0223F770FB900487915509A0048A750FD27861339BC
-61128625DF4708CD007B133ABC622186410E7904AE5A057F00439101E222C326
-F328CE27AC38008805A054236C12E8590D7700368D1F79339440008604500DD5
-25AD350299086A3D00E60440BB50018411A5471D395A09A700C40C6001B30437
-1AAD2F9D1ADE5801E5117B275A36FB00A00836CC00A54212BE462B7905C90032
-E601A20877276C340CA4047B116C1B5AAD009A0DEE395632E103A5086726D31A
-33047809A168002DAD0A3E5E1C8C22AD2F50964004CB3100A219E8371AD827B0
-1235A90D82047600590785015AD1266C1F3DC4049B3F19AB22FA4904C646035A
-10E126C11A8E2E6E1550CC284192127927966B002DAF26C7340B72B912EE2088
-349B1F862640924D0C7B23750036971F4E00D805911F7925E64F208A22E93460
-1AAA12542496461A79258712C819B160226C26D6009E06357B1F640083058625
-7F1FEB3077019B65B61BCB223EEA6E1F59D100B404664109D70027801B52F238
-60264CA50F5308E35A1850399F1340B83A1FF82C0DA809F10079325D00812769
-137D275A1BF027A0184E356B00A806F40C6800DD05C81EB5133BF3790A490378
-FA003F6C014564124FD40A6AE500C53B01FC13AE61096BB2412F6C12AE013B6C
-04790A65019206DB0039F96C0C5AB304CD375000830540D001932B7D23CE5004
-D82FA927C70DB4005B4005BF5312003F5A018F045207BE013A6B432CF61F911A
-6AFB0E9E086901B7067000409E772D0171F80027D4690D794F12944E34882963
-15F726C10ADA01B408D201830B770168B301ED401F7F279A1F854A27673F0086
-08501660E36A1A2E8E1FA330BC07FE002F951A3D5B0F87522784062EF2270B8B
-04EE4A2752C412B229DA30B01F4826699E3E03D6133C684106E05D26FC1E793D
-0FF2043E5B1F86266C127919652D45D5229E1235E68726DF3046D01F93287812
-E70C86005805B733034B26CF1F771245CD2FFE250561BD203EA55B1A3CEC01A2
-3E00E204410EB54001831C5434921F513A9E31B921D9311283225FBE015904C1
-3C0EA301EB5327D526A301470CB95A0DD70451267C22844101DA06A62547CE04
-40BD510272CA1B3B6600D60A604000830D710458C17712501F84267700F32090
-17359A005708BE501B6AB400FB09B302EA0150F7049E0A6C004A7D1F0C6C0580
-106C3B0DF1269E22AF4F27C772264779B05F0050DE34A20A790250D03F0E7E02
-5008940449881ACB60256BC870045A9E0C40A7125B38E00F660045600D924A05
-C8094D38DF316001F9502E780BAA046D1CD0279E360180275EEB0049CD04B55A
-217927EF0031951F6C129D3F005AB70E861F9625F1551F9E27FC134B01EC05CC
-00A92A950D5D01C16B123EE02A5A00A54212841A61384C2495341B7B213DB12F
-F504A2C522A81FF600B45000820777013198113B01D91B3B12942B0484186327
-92126900902FDE12CD23B32D0F6D3108B700491BE3223BD46B00ED05AE008622
-F21AA43D00F83E267912860D7A178C441BC312601F852F92067C0050CB1A9B10
-369E0D386C1533A300671281500CF700D14B24E021792C44BF017F0831CC015A
-0692277B2286325212E92346B5492704B36F0D8621833106C94930A00DD25A12
-C14900DF521284175C2E4776015734651A984117CA354ADF035AF082500073F8
-0BBA5927F100C31AB327F11EAD266A336D015AD90081451F9A278511AE005024
-792A7F16612FAD0A6C04C55C1F6CAC00E826AE00D3340996013ADB4000FC144A
-23EF1F664100C16B1963AC0AF54712D726AF05C73444613A16A40F5001FA065B
-3D1FB46C123AA7401AC60DB24218A0670483007609F7551F43AA03CC11E96626
-00E2056C3F00770486366007C9013ED80013EE3CAE06C64C04DB2F6C0486147B
-1F490D27BD42207C390086107A335101860A500483008A0DF52241AA12FC5A0C
-EA01512F8F1AA312BE2650FE0456368F2A50119E01513C1A772B6C2051B9274B
-8604AF570D6CBC5B099505E1335001DC2E007226875508732D7A199701900A81
-0065AA3E189412DE690447F66F0ED95B003E6200DE0734BA1DD94E2F800ED500
-3277276C0138AD7615509C22AA27E60DB41A98264F87219D4161102D87270E8C
-265712FD23AA08C001AC6C3004A00160E01DB6470CE461223DCA5C1FE927A617
-85042F9404347B2666D00648F803550795013F7911D000E5077926DE12BB630B
-FD03A0077800F112653D219E32003CB32F771286207E245AC71CB30036A01FEB
-015028E31FBA27EA29056DB626820035A42700449705267EF21F9C27874A0A61
-3D12C8014A2566EE0D9C1A94510A27BB3401F4088A1D792777003BFB046C0BB5
-04D86F0060F34001A379005E4336672E5207E45A14C82E09792601973E04D86C
-1241960878016036C6642050C000B20A3686122F65DA3D21CC1CB85023751F40
-BD3A0481460091235635E21A416030A30CD0015ADF0F790146B704F90C9E043C
-810D59E1026C0D5EB4066A3D036C1E46D63A004B1BC4570C77BF152D69B93904
-500C6C02F82FA70179225DB77A143E5300D3401FF25B046C961269315501ED11
-BC6A1E49CD3878274F1ACE0C5112C4471D3CB50EE900CF229D1238862350AF34
-4BF5531F7E3007A7002FBF4839D6065000DE0A6C3C13974A00B9762700864D09
-6C002C860CA365005A9A1D2FEB143E9512662AB204C6006C2A79173F6A1DE718
-5838613143F01247CF3F149926C5341C8B12D6499E0187530C79EC620527E630
-0460E400501179B43BCA40126D1FE62A920D4101C105A6365A05AF003AC81A2B
-50D200BE47305B400EAE08580015A40185219A27793701E26C05772687168400
-60B201EC0567009A3D0EBF009F491AFD74260D8F1F9D2777298F1AF5591FE131
-520CD14112E834AC46F601CA3413F2270ECF6C0560CF00B4057D0E75278C1FF3
-26AD04C551278300A408BF004F93056001852C780051F3004160083BFD391ABC
-2F103FAF6D1750853E1F9027D4215627015FA4008508A500F41A6E278720FE13
-7E2369A10748E2133C62189F05D7017C279026E1622FFA346A00DE06B0630D27
-CD1AA5045033F83F1A7A12771FDC27058B2D6912C73657014FE4005A10EF1BAE
-01603E0585019E238A04A660017E2705663C1A854906AA500037B11F447A224B
-D64824E7115001860D7E41019E0DD8226D277A1A2AE326AF22F712AD1A762FC4
-1FAF24690F970050CE0150099B01CD08AD0B6B019D05FE79153AE03150177927
-4CDD470C69019E29D90D51327900810492420C69239D1AF3016C0D98075404BC
-50259119309349005A2979D90D7405D42846C149126CD14201ED50007C22AD1C
-6734B54003810D50C912A9267811EE18683B1E990D59D912B56900D73073189E
-5A0C860231F3015F099A003DBB6022E23812FE26772E8D12E906B45A006D0C7A
-043C674504A50B7F008605D047277B1A8722EF336427782240EA4F13781B40BD
-045A0DC46221AD045A00CF30780E60008816F820AE27C41FFC33B03F12782D4A
-C23A43C712A53E0A7C015AF813B237F3124000521FA42592005B07B2005214A5
-1E389C14E1099204781286492EDD3F256F00D9395E0147C300FB27C0203F6E04
-27960F5701FB4120E627BA59119227C51F528F05308100589F1B4700C4045035
-86123FAA2FCA1F5AB905D2285A374BEF163D6004F50DA5276B00A70EFB00BD5F
-0331C427A2004D8E227C3800D9127D229319AD26E634B3254101920A5A0D7900
-6E0356E300AC075A001F6D295C1AE72EC83F007E0485096AAD32C665015017FA
-2795308423790860B7046C2E5A26C922F800BA097100941E8B4908B033792582
-125B0486009E41F14724BC7927048401750839A52279013FFB1548D91DAF330B
-6CB45A1F69BC014CD50479094994004185127901DC0D2E6CAF227F345A01DC14
-7928811B5A3D0D9F6C00620EDA2F0AF001B1502D9D07EA3350018204740858C2
-6B2746E94B26B227D209366C1F8023EA9501D9049D4912681EB82F5A20C14704
-89270C79B93D047F0DE71AC827F6300F51D000A23F018427791F6032B312FE28
-12861BE504AE0B41933C14E42E0A60008A400D50C432A519DB6800E60D4F8304
-39A60F7A0565D1014A0DF5310E81233B6621FC1334E00E33EB23922666B60443
-00C1129639499E0BD1044CB320DC1938F426931AAD48346A1288053F624412C5
-671FA027DD124C02D10560018510781A43B50DDA27A40E38501F7F3700AF0878
-440CDC3D002DE61E5AF13A1069AA204D0160069401468A223E650EF0500CBC05
-50EC0443620150C9006A2C591F6EE901CA5A236CA814C62E02E11B6C125A3650
-1286482EBC18CC6A005027EE3F1383269502409B1AF101B64600A560206CA100
-5108C8005028E178275006C8043260238734006C068656056F017D257604CE27
-49FB11B400860638F50F5E00982F7912A41FC22FF101A66126840455006714BE
-600DF16C2350EA00A01A6CB4600A7F005004CF44006CC539AF491667C000E405
-9B335D1977228638139F21D2309A44359E05D43E0027793107B10036791F52A3
-389800F805B200C7330496065C3B1F77C3025A08A22ADE1660D30052346C1887
-315401C2075027AB5E1F7D1296083D0EE96C1F66F800AE0EEB8026C64211B628
-D13906E3541F9E003976276C1F9F5A0149B6451EF02289326C145A226E3900F6
-193FC633FE82002E860433BD023B68248B054A15CE279E26843014E22650126F
-24EB340C80276E1FCC00AE30DA00C25801790D6D2604F21A50127FB94C17A066
-1C51CE08EE047712612749811F6F2561F012418B00F70A359D27C82278008642
-206CB30DCF3E05DF108E267F14F43E129E32F9225AB470002FAC124585266D3A
-0C760134981F78125A9F3D00850F61BB01D10BF14126C6226C0986005A04E600
-8A06990DCA480BA25F117505254ADE18AD5912871AD13E12FC279201780EDE1B
-A55F098505F600910479411CA611850B3D6C044A7C0E34E326AC00C55A0D6CB5
-3A045A0DDC013EFA037B27416029DA01B7083AE10B9E015035D721A326447A12
-84015012BA2F05A40A277A005A9E1F6C29E8009D4901D6096C0085024920C641
-017F3808D70153BB1BE26100F00AAE004519BF27E9301A84267A35008C058112
-CE284BB94726A536D927631F853750019D21B8409F0B634000F8267A04B04F01
-A81F5034AF0579003FBC32A31A5C2FB712DC4E02FC2D4DE6129E1B3FB56B1562
-2D84183AA3270076F922922984226C4611B400C309487F22945A137D27CF1F87
-0C6C0452B500E51F60F33E0468FB3648E914AE2F0D50BC0441623B1A79278A1B
-BD34DB129E055DF417BC5A1F962A0492482186263F6B27F7650C790446A60E5A
-03B8651DD7345C019C0C690D7B0B7701AD04E500B31BEA27840E6C013CCB1F97
-2FA611602686390B69EC135D3949FE126C015439D218593D00AE345E00930661
-24F901500A9801F6095FDF0153D81F503F00AE0BCB059D2F4E7E21871233EB00
-2FA50059076C01AD2DE01B672941950C3471A01A57008E07642575F9003C7812
-CC22C10DB1043F60064C7B26851A3292012E7910F05F3000B40850D102920836
-A22451C50040E02F500C984817F93D20E027C62AFD2154127C2F6C2779084F01
-D21AF05204790C680150EE0040DC772F049D00CA0D2F8726E41F790181089F6B
-218213C34127CB3C12A228D8237B1F92381299340C8E02CE6B1E5032631AE10C
-3EFD01B2650C42CF1A49F539BE4825740E9305CD014DB800470DCD23B31F50D7
-014426921AA555058501662E4FFD1FA22A00ED0EB2470D50E200A54016CC6F12
-3A9E135A2CBA5000D80B5E348513A420EA380086069250007E05650046C54923
-9F05CD1266C034557F3112B227E127C41A44951F5512B84120762766B4005707
-9E0FBD22F1310BD405A4501A79018A5A057F00AD374C03C356086CAF1A622606
-79F100B54000A71B5A35501F76AD0E862667175510FD00B13154208A2F1979E9
-3A0484277803387CBD094DDC0230F74B36E11079006C12D35035620074CF1F69
-355A0683043EFE6C0148E2046C1F7F2F8A1BF6076B00780455BF2C5012AD3F1F
-9E3486135C09F4175038860026920521A660006F067B0F9D3507BE0394005AD7
-0985055027D037652D4660008B49276A3A00E00EB74626F01F405A06E7691B2F
-EF27003DEA45AF3D137610895E278500BE07D2033C5C01C508A2007A1B854909
-ED6C12DC600727964C14E311C1590527861534986B091F9F0048AD3ACB3E0A9C
-05C1274004A308B620D6279C25521AC5227B3C14EC109E017926AB28D3239E12
-6C1ADB6104EF5A0FE303A72C810060D80148F94B15DF76083AFC22A3346B00E1
-502F6C25F51A47A623EE179B02AB0CF801994012B804ED127726953300840C69
-C51A7A3000B675045CC079220A8001BC21EC2B06D90D6D276B278622EF3F1F88
-2FDA27BB3515843704A0003EC75201C63D00833218ED6200D15E0026AE5B2782
-1B6926019048276C187EE725793E128E004A0DBB00A30C6200B684014826DC15
-50018E0A5030FC05A40027853201B2276B1FDB26AF340C9529109E3F0026C458
-0D6801D423901F8613CF3D0B82013490003B6C401F7F27711FDB2A507B1F47B3
-4B0464D61FA73500950DA45D12409E124A0451C8275B34520150A0349219F410
-A4006905AA56046E0C6A015BD300B550277E216B128626AA541FA36C0C479F2B
-0F78E73E04CE0CEB04B66111F200D853043D5A00FB50276BEE611F3F5A33F327
-50236CAE590465C93C1764B4005E374677BD0A49971A82069301771A79411DB9
-69045AB28502298D2F85124609B200490561AA28C7511F63BA0DE75A00C709A5
-0586003CC6015D0DF4173F5604EC4F27DD1F46FD0027D5249D166800DC0EAE7A
-12650141B0048C36DF1B792640E71E99279E124327621AF60DB100F8400E7608
-FC0142B4270640C21B491294226F2F58401F8427793712A01EBD2F6001CA0947
-017BDE0596097902D605370EBC410071E64012921BC4260E522FD3125B38C934
-560DC301ED5E0038D7270C3549ED00C92558F563276CE9792050007805DF1146
-80043C99125634681AFA0F509427792285019D295F0A82017706328650086B01
-F739921A770437C526E422543861144A9C0ACA00793D00F1073E7BE402A50650
-772D5A05D72F6522962D0077F17A013AA76C0050B301DB08C301B3085AC7006C
-07951F832B771CB93012771F40B33C1D5CFD7A291A9C1F3404CE276C017DEA04
-91003FF8015011F33D2386460DAD6F196BE70692125D1AAD014905CD0D3701BF
-10FA15692D920037AD19652EEE01BB53269C3306D400AD31C60F7815BF2FAF22
-CA6311E23AB5357B092CA724F9480079098502D900B70C31841F5A12C14F236B
-C038134A238E3412C41A9F4B00BA5004D966124E0D61DC0529FE1F3E6A137731
-501B86224D30F45012D90CA926900450A400C751126DA80B49006BEF084FB779
-4902F14E15583E1FAE6B0D862280006CAB042F7F2705C00153BA1F3D9B500D78
-29861B4F93482C6C4234AD1A53F51E4DD8019F1B6C4000840CE34A196744056E
-3BE649046B128537019348006D0D48C45A046C0A862B50A51F6C2879275AFD01
-3FDB2F5F0EA904510C76CD5C00E84804693F229314397A0F34C825B12F1A8246
-0A9B05C735AC0DFB6300E40D9D043477237A00E80D3CF7442D6607EE00338D20
-B912533186003A0EA13607B323CB64072AB627D713B8401F5ACC12F64D319E20
-0064D70430E422B9013DA609DC00A0088601C40C3E8607417D0D3DB013D82862
-04883EBB11FA230160269A1FF4004AAB1A29A022DD27003DE42FB118D41245F7
-0DAD08C4003BA16A078601772BDB1FA401460DAC1B8536AE00F1075AE11F8849
-008F04439D00BD5E2681195300603E26A829751F44AF009F325A164B792604D4
-21922750CF016838A301CA124AFA6C1F61890D750037E4530079053B6008E700
-7741008D09487CF7410E6CA4007F125AF81F8424601DE7224826950450B21227
-CB5A047723A416BF27006D2F4B80B50DD6003E762BD00A5AF30750047FAD1579
-01445F00920630941F502296134826B21AF5259C006932FB257F276C01D51178
-277C3201A205EA3E136CF50F6A3C12E10041EE2CA104780A8B02D2671BE44903
-BF39AD019B69108202B80C5A2FDF187B2A6626A80127D10030E01EA978113395
-265A9E1991265016A32751D1122D0C27AF36156B27CF3400770440B43C0370D0
-5F13D93000FA6B0031E00B9100793650EC0DA80227523E1F55C70561188B3512
-79BC651F40610ECB1C9F3B23C960003AE7640570EC00397F048D14792688129F
-00D80B942761209D12C95426721D5FC03B1F50D101A4275AAF066C1AD922C512
-5A3C019209378111710BDC1940C234611E97228604580CE804920D3F9D18AD5B
-045027055FC21AFE0047DC016AC43E06DD013CA561C7720150F2049E0862AF12
-D56C0C5A9D124E008227A458223EAE791C502DFE41128C226C1F61E300AD7808
-7F27A44404C16600470CED03BA50278102E86A0440B76C013ECD0E405AC12252
-34BA09E9014E2E5B394F1EB30AEB0160400ED700A90C500092042F831F790E34
-92278500974933F918B42C50C721F12760287C065700E44900F8123FBE277834
-44D5650579411281B743F23F01790EA72D0D863A0499631D83105500461AD422
-793C1F882640563A18FC012FB826EF49016D0A8D05500D63C0035D07C801AF08
-CD41127B1132FB145000E52F531FD7279E223A6C00FC0C5A3E0F8B1A50128B1B
-4BA52504780AD6015A401F66C704B60EF56500834838AD007F3368299427DF23
-B75A09F704C95501E80E603F0786006B430F840065058D00A11BFB27A10E387D
-266B9F006007BB005312E12F00F53B24007B16A12F6A226CBD4B1CFA0E32BC27
-F123982CAA066600C35B01EA05BC009227794305880933C41BE51FC027F30041
-A51F7E2672288235049E27C543016BBC3B109401830D6F01589A12864932A41F
-B427F101D226AD0B2F7BE12760377612CF79063E6C1A820433C628129223FE1A
-B108F30279077E41128732623F12781F50BC14DF2753BD04EB1FA5307713D937
-5C01852250B209C1044839F54A1F82278B1B50974C096DC02A620BC901E8053A
-00962686500079086E047B173E9F540D40AC12852A681CC00EDF611F6CA00D3F
-693A017916852F104FE8490FDB015AF11A66006EA52705854C22EB27B034F61F
-43D00626C2056C007A3473276800FA6000500FAF19F1500030A912E45022A356
-0D6CDE045A09772C861F4921C53400E64A00A520DF2C9F003B6C01A50C3C6D2F
-5705CF24AE480DBB4F12D8046C2F5834D9146C23A10FEE013BBF062CD51F5504
-DD5026811F4178E20C5402D64414B537E20A6AFD1128DB2170355A15E350057D
-3400CC38015A9400AE56279F06D96C057900A21D8F2148990EE12F0A40DC1FB4
-3F066B007C08A501306095124EDA480DBD0A9B17854012BA1C9300800526B662
-247B002FCD01388B004E2FA03F12CE0158B96A1453A23D1AC40C79018424F91F
-AE40237B1AD6019D400D86012F93003977279117ED01770C8603C8005C32AA6C
-12429401770E9B4000920951B9311369BB3912892F610050C130004387049A00
-F20AA60135A22250AC1249FD1927DB4511EA227D351AB124396A3D0BBC003978
-1F5AB86300770C5AA71FDB2961136CE41A40EE01601585255A03E2350597316A
-39CB2C4997400DF71AB16A1561EA22B4197805E56227810E4600FA0B6C049426
-6630B40D60087C0450F0009026641FFD6B185BF41A63E008B2005A1F9727A51D
-622D428F195004E85E1DB227FC341AB527F01261019C471A70AF01ED1AA92605
-4A78B4126B33571F9126458600F20D602D790FB3620C3186045C00CC40015AC4
-04F9572763D002860649189B27FE0137750E8D25C53805860033A022C000F52F
-A01F50D74701F3065E0CDE032186015D3F049A420F760855C8275000B11AEC26
-9B27AB22D11252F0045A37C84F27D20D633E11AC09800027BF42038232138026
-46C9490FCE0050E60AB305F80D793C00770B85044E861166017922DA3600F708
-3E5A22790F8623EF012750E707B53B016DD91255328604D80097350376AB1D49
-B94C126CF20D3B93400087072FA326F428C90D811B50D304AB197900964D27BC
-6909552A911A790E82005A1186279D1F863353C54E34A112D72706BD31FA3D01
-840D96355D0177097C01612E8A003B9D129526008819A221C94A2AE636B05007
-35A820C84704F20B690479307F223E6C1F7D2640AF1FC426E14822CB0144D13A
-B04A07A96026871FCA4804DC4095523AC80A2D7B1B6AC73E0365B01E41A81C7F
-255AD03F07F600680B9C461F86266012AD1AE9550B49008E046031B512642C47
-F50B5B1CDF12532078D704406201CE30AC27C51A6401BD4900932708E1006C34
-4C8E5000791FA822D94904C9384AD21F50F20543BF1648D7016BE4385A016C0A
-9E0071045F12E06C12520089502F951FA825FE05B401D94F00CB600168108134
-0098522F9605266C1D86122AA0006C05A1325F00270D821F62A900DE0E502194
-2B07E7006A3D08EC005020A326811FE02C00A608DE04CC2479341576C06B2551
-EA004379049F00572FC93E04A10CF8003BA511EA50226E087A023BE83F0D28FB
-10417E1F57B909F10125A0116B045A3F12841C8605309E1235791F4E86062D83
-0D5204B633F427794112D81F9F2C0079EB3C11C30141D40060124E1C892F1095
-350CDE2D9F045ABC3E0DED1F5AC100F90450D7183FE43B127E1FB04AD8009D04
-3D5A277704FB12C34A149D27CA502282128601602F980350C337531E7F2A9501
-5DAC013612D11A3E720CE22640C61A92018049346C2E9319476C3904B415FE22
-B5511375B36C2258CB019D2E15851F40D84930E737B400F626AE12E65C006CAF
-0EDA013EFD561ABD27771093004907B83150860558B72705639A26770D5A3386
-39C76A075BAC227947177C26F92050147900840A3D61412FAE01955B0D6BCD01
-FC08871A662FF612BF01B535497D0079375E016C0DB527E334BE1BE6123F8326
-0477B3004712D80C3EFC7A41019D08C4344E8A136C3A0DB01FEF01B70750CD01
-B20C792A5C00416B079D0039099F006B3C12F64900AF7427018206660F782D67
-00793F22C339017F26961B67009B4714EA4E1F6FD35B1A84003BF63F1245AF28
-01FA1AAE22E906A40027F13801EC04B557009208A303DB2CA527D7169F0D7D24
-6D3403B81B4E2E6238013FAE14476C30601A960D2FAE22D412F62D9F017A0564
-0A6F005AD21367FA3D0D6AEF5A278E215105B86027821FAA2600AE07E85A2779
-125223861241842653D9019934A31EDD2661D3461CEA26AD6005793652125AC3
-1CAD27D421A413C74A03850A4FEF31680CB226CD330686002FC00B3803ED27C4
-0D6801CE6C0D844D358300791477275D991153851A6C123DE31F79316C236012
-6D017B32E900BF09F449287900A70BC45AE3027E059F0DE94000D05306840145
-731A425D1FC7279826853306AF005019C72549057900A50E6C3C1BEF00490569
-F931633F00CD0660D63C00E1310DFA1A3E6812E40A49018F2E048650057F0B2F
-B41AD203EC0A3D8A0079094F026C401FDE27A8155A05CB5100721250DD39AD6A
-2159AB79125F1C8E257E2E04E41CBE1242CF325401DC0944BE0533A426C50960
-400DCD00AE05F935B14804654512921E8512D95016722110349726D8225B0586
-28761AEC4E309A04BA08F13D00790EFC04A545228B2C8501A012BA1FE74533D3
-009F0E5AD8791150019E1285209F2F046BA31F995A008106C750246CC25A11F1
-4012C03E1FDC4A00862769297C204CFE155AB633EE05920C6A0081249D1937E2
-27AE03610A5001FC054D0044B24801DF11AC483367009404600BB73E1F92172E
-76D8007A288A00BA5927751F8341005A22CA1EA32D583E00AB0439F627B38D53
-0B6D0046BA4B1FAB01643C12CA1E54326A13924A29B0385017EC5C09DA0E6331
-80013C6104AE1A70307C23411DA7278623D9286C1040B14809780446CC229D2D
-008605442679006699005C9401783F0EC008A400CE0D40A23C0084125131B11E
-FC2FB901419304791A8524C61D7926971FCD266C099A345A007909A42B4FF31E
-8A26814A00F655013F5012FB1A6C3A01F00AC64B19DC0E920B7D01DF07C56724
-5A9A067A003A1AEF27A4167801F81146D609A4006BE200A54004DE0C60009D6D
-02349527AA1FF72659D5127B278603F406B2007104C80C5C00A404FD6E0027F1
-27BA16366D1551B135ED12AC19C53A26F60D32B817FC591F6D336A278504621A
-E2265BD600633E04790F50E90D5A35F6006C29940DD5347E0D9217F84C1AB926
-F05414D5083B6C00E605C436660DAD1D9F690450A8137F2664330D9E266B30F3
-385020891334EB0E2F7424D65CB2016908E14F2B68358F20792791370F7C1AC5
-2F509F21CC270D40BD0078057C00940A439C00E00F5A228B284DE33A5038F049
-1A7C3B1EC35A0E740061AE01F20B61014A790385500A871AA450238304378A01
-E60FB21ADD2B75079F01369413C7502796216429BC1549A511F0013C610041E2
-04603E009204683A018620A724BC40126C1A79219327EA0C31D0223DE2069700
-AB6C0451B4005905AC5E016AA10050C901A60A1336952285410EA208C3005A04
-F9195BBB2752008D2601720849DF7913511BCC395022C11A326B264AC24716D0
-12600AB6016A08CF5001860B43A51BE83F0D772FA127CE1F3AD83E1BE3014067
-00D60C41CD22A5275A017A4800BF50276CBA09426F00DA07C200780287092F8C
-1F4AA11BC0225A32BA0FD62752CC0DB53060017E065D9C27A201D20761004985
-00920F5C4429D31A3BEC3F1C8B25C6123BFA4021831C6C3E2685FE5704C93000
-D11F812644B4490E84015004FD6812D041EF35A13A016AF5345A12E165046CF8
-08B301630884017A1F9927861F954122B42ADF3301834C26D1218C047B0D9507
-5F007F276CC80879284E970074057F23CA391295350BF612532FEF1F862D6C14
-4CE04022D465043EB40E6C078C017C266C2281153D6E4119DD4613F93E00D80D
-5A3045B135C812652CBF01A20B5085016008D6017B277100790CCF04B507E350
-0046117919509E385A04ED126C22A02FCA239D390885330B6C005A1FB9280686
-0098072FB412377727921FEC35AD2FF6005A0FDE3200820D62046BC13D059900
-5012EA24672DFD22BB12AE3B1F52B012E8175B30F713920C5FF0054985247B00
-9006600EA7268C330D5DAC003BE96C0051E5472DF50C9D00A607FD009E05860C
-9734581F822650FD038810782253F20548861FFA3412C2229C2F6212E422B949
-276139532D661F9232A527F30D6401AE334E9C05DA007C06750D5AAC1F60B227
-C512770D934520C5254D86004B9E00CE0C3F690059054839C54C036CBC1AE627
-951F5023DA1F60B43F0155B800488605475A00F30E3D610145B709487700AB1F
-5526C401B019D6223FC53B04F401B67705398612541FC62F019912603F1ADC49
-366C2648E8226B00CE04B008C5123E6B1AE105AE013D96143869028B49056F43
-16A550049408339E00F30DAD00BD04D20686007621E5137A003E602B501FE927
-D22F03F3005105793AE84D01E2640D3EEF193DD51F812456A811D91AB96E1379
-21A1253F5A017B08F700A50D862E0B78C61E419B126632E12078269304C43397
-25851A36DD2778009B4028634404A26C015A8522641E3FF81A50CA0592127941
-21B000C4772E039512C02F0150B9492771276B2F7900BD50276E277F0D50E500
-C5531FE131AF00FD0A367F1B5AD4126C1F7A2577125D1F6C2240B83D068725F6
-1FC00AAE651149009E43267E1BDB4700611AAD2A04B470026BAC0E5306FC012E
-762680290BE3005F07FB0EA04630AD136C385C02F96B2708920435D401A70C8C
-04CF2F6C1F7A05EE00BF50049F12CF500DF9009932511AE11243CF08AA005097
-01277A2AA508DE64143A500558CA275008A57A12611B960FE901A72389360A9E
-00D41AB725409B3C09A5006C107E2951BD00EF3E018127A401CC35E840AE01DE
-540F61C8276C0D771582380178B766146CC20D942F12A5268510408431139E27
-0561A234487BC8009E0941A54A2FC03E168400D21259359819C9344F00DB4931
-ED53267F1D5434B1188600E010681B416212752C8006318F1F6C10EA0CAD279E
-00316D27831146DA4100FE2287320478EF1D9F0E6900F3621F3DD506F8007C1A
-560DE2045AED1F673359018608621179289120D847019226416822A519E00B3F
-6419550C268534018F2E009C04B536E00447FB1A3704E3203E5A01B96B09FE04
-50D70050F90149DC2F00BB260F543C20ED6C0126940469B33360277904EB0050
-067911A51A860E6900C0083FF5005F3E0BA22749AD37D001AE26FB184ADA0454
-BC274664007A185DBA0FE81FBE310AA65C0F73004FBA3E018227E320793904C5
-00763140AD3445923B1F9B2B0040B304F7411FD127ED22CA053E651AC84B0D9F
-04CD085C314D870E99007BFB085ABD16EE491B644200602795084B8F410D9B04
-F036501F8648349B21881E6736941A8A41126CE405B366033ACE6A12F126440A
-EF05B4491F69B827E52F5A3C04BD1A77144B93229F12EB56267E015A06703B0D
-90013D86207935019E05CB3449FD04398105660190691535B527D71A5A23CE12
-460154B7179F264C12A2025A0ADF00C0611472AD5E127713A35A0484005A1678
-F300860732E71F7227439600C504ED22B82E247E1F3F680CA234E312AC1AC751
-26BC00CE5A2774247905DF0027C601570AC70DB0096001F178043B5C40188710
-5105864F00789E1B3D5D0E9E3E126E009107CE792340AA2FDA0161066C4101C3
-0DFD19B526E7531F60C700B308E44116751D860D28904A24AF2DD42604EB5401
-6C0C7E00860662B5840A3B6C0C79E75F27CD26871C794110FB023D07D9269200
-31BB1240AE350D553A23B16C0052B801FB126C422761400377B200D704AD5000
-7E03852479012F86126A3B19B200D2129E32548C123EEE6327742651C927501F
-C425AB00F926B51FDE411FCC2C016CBE00DC5001D124B2206441005BF3016E11
-3EB82DD1229A1F5A2F6C400E7B00BA40157C2E641279BF2BEB01B46812E20078
-0B6E47A13C1F8C22A438F6329C1A4E26FA12D6500048049D0D6801B83005972F
-4FC7277B3B1ADF6E265086036CD504BD600D3F9D133A63472EAF1A8513D05311
-1E4F2F6C0E26CE195839F40C49DB053FEA01800C6C1F83490CAE044D902605B2
-00E5043C7907A200850D793299007D3001A40C5BE03922812F1A8627790D3BFC
-1EA52C1286269F570C7F0085083CAF00D304AB472D6C05EE4A0CA43C00580461
-38500297275A35F23E0E7900BC09E44A04630B49DE0077045F3F1BAE21842646
-F749216AD44700860B6900BB500E400AFE1AC03E1F814001F51B4FDC0AA70480
-08F6009F0938925FEC12C23D78462FBA125B349314A65A208E26F932A7012AF1
-1E3BD4007847348412771AEB402C6615DE470462460DBF61278D174904990847
-AF05F5014C95046B09D44D06DF0033FB1F5029E56A12834D287801E00F9D3301
-D52450F61A9C12A522D3480CC4045900C91A602A6E401F9D26C327113EA92FC7
-019A30F312C000750890015122C11F3EF2245A047FB27900395F019E4D149026
-82022F8626D322613476275ADE002705834901F9058F007B08D0007A3300B706
-4061124ABF6A045B9919A512DE1B4FC1229E00720ED6345A1BC612E8365312FE
-003CC36F12F46515405A32C3133E8939169D3F1F5A890467BC0F4301C73F1AF2
-13672185265BA81B86126C3248DA007B08377E25871C842650F905A800D00781
-006CB35A0D8122860D6B007C2F5214B12AED15820D54A804992BE93D012768B6
-0DEB2F05E0286A12AE5E00780D9300A50DC10133A16CB3320B86276C22DC279F
-1F5026F16A1A6ECC0099093D22D8400A6C257D01990C40801455B85004850B8F
-246C0197077926A66A0140AB3B0078CB109F005EDC01B6630073B20A27A43800
-709F265C0DA60253C13C07D0003F6A05B300C30727941F56F700A811D72FAE12
-406C1559346812ED47043AE8005418DC27B53906E3641F7A0D9F34E7016C3253
-0D771F62DA12457F1D5DB30FA200D84118F3385831E81F6A21865A0D380162D7
-1BB811A50C770463C00142279D0B39521FEA77008027BB00FB39602DF30030D5
-02381CAD26F30041B75022D11A86052FE821571FA12B04721F7F2F1A7A2641F0
-3B1269E91B52D5133DF8048F227E2F00944E1A7512F02F44621F8A5030BE1278
-2C48600177089401C42DE30DB4502D1A8D226733BD4101791A50A54003C4003B
-6104477913E01BB300C3083E970127A000347926773104964D06C701499B05E2
-3E1BF449C71540560060395533EB123AA278074CE51EB45F0528B24911613654
-06BE0443A6540D6BFD7B003E60319C042882004E36BB500A8B01C80C50ED34B8
-0DE94705C60C5A03C6350181063086016C4727E607A04412FC29B55503880ADE
-3B01F20C6A3C04B50AEB3F1FDE2751258601933D0178BA00CE0692095DA90EF0
-01601088264DDD25B91F9E450060376B258A164CF4540CD75004FA0A52BD3D1D
-8412791A3C7045009606842277049C30E307C400458F045422D8300479013CA5
-6C0D34E602A31985229113661FB52549146CBC12D71F5DED0F69E0026211D027
-6E27822260014566028E50208627952250AD12E16122C51AB100603E17D95E04
-800134CB2679209949177800E1501D81229157006AA4045A37621BFC0C40572F
-6C1FFB263C67209A27D0193F950586005A0FCC2FA212FA5001CE2C04AD3A1A93
-3E1F98226801ED27AF2CDB00AE12BF5027>
- >>
- /Gray 1 index
- /Default 1 index
-% See the beginning of this file regarding the following.
- /Red 1 index
- /Green 1 index
- /Blue 1 index
-
- /Cyan <<
- /HalftoneType 3
- /Width 167
- /Height 167
- /Thresholds <
-8449386C275F1EB224FB26AE1FD23246FE135C3A8D105A01874A27952305C10A
-7B2C46C70CF700BA0635852676217F1A6C4025821438951F4398621578B54113
-47C50C87006533500E8A270C94033D5E1AFE7141087900AE10D72BB21EDD3147
-E6368B12791B539B006408790D609406A022DF3100B00A347D1F54C0274CAD22
-E91A3B7B1DA227049F7800502EB53E01274CB248002EA3085600AB3C12C5501F
-8F3800850D630022C701B305EC4F007E0885016C06A5115736B21A5334E33F1A
-D80D52EF4A306A17AA1A722741641F924902C408A631F0019F4A00BE50016DC7
-072FA4270461EE76226C263FB604FD6C2150F130AD12C2325104A8601F95256C
-068700406708A8006C09A301C10641C720B232C800502D6A3F09854722914901
-EE2F0685003794077300D840016CC23E166ACF125A1D7CD70D841A71C31340F4
-345A01874700D90B5BBA1BDC27AE7715623283122FD71F5A34DE228627790495
-01EF0B9702AE6600823A017800FD3E06D401AF0ED73D12ED29583A6012523C0B
-DE2E601FD9291254FA014FD8103C01A805DF5A1B782700B5077900416A009F0D
-D8193CE10446C449276BBD1294267727D2226130860E2E79018026A51FF902BF
-501FF35F04C73E129A4117DE6C1349B3481F60EA124F00F23406A502ED431652
-04F13D0461AF0C991BCF2F1A7F2779204058027C100440D70B49C26C043FBD01
-544000F319C92269276D267E142F9D1FC827B443119F662250366C049B5D008D
-0DFC00B204CB6318860D7F045CA50434851A6F2DAE571F803001CB0986493566
-1CBB14E750217E278F004C85125C00EC0C3C5800F50E931A51EB044CDB671AFE
-12470486103C5A00980E3CA819865000B9573001D1265A0E8E06329827861F95
-412289360075BC335B1F87300079276E0560EF0EAE01EB05A53649FE9C561B86
-013D0EAD68168F0FB8760D50308508A400D80547F604620A50128728540079F2
-15A430501AC92F68226F27791F40AD04F1379D1A3EBC6A21CE00870634F61046
-8F22A113E302D52A4D84062FC9014911B8310AFB2E781C9F21D043346104B300
-40A019390092275AD766276CAD13E02783006C3903D12765088B4D0D8601F723
-BC5403E0095201C06C0E65AD270B8600DD0ED04E1AE312B440006B3376266A12
-CD00263000B827F97826500CEE2E613D21649E0041E11646229F6C123DA92DE7
-6B04DB0DC33C046B00E40DAD258501A306E10C970059336C0049E70A50009A0C
-6027C665006CD0043E68390D701A91013EB16C1F60F36C2264A54005BC510173
-06A312C45024852D0C74B6460DA801490BCA00347705681BD024F6460D851AFD
-22B03F1FA52C8500397D1468D32C5000E3250840FC22A12646049E3E01834F23
-9220C9139C2E861FAD6CE360116C0546CE00A24900C806E50138D10E4F78BA5B
-0D30BF5A007B07339A21405B1F9E277F2278015812D4347B27682FF812BD23AF
-122E7C25DE2751F30E4C1AB43B1F52EA00BC469E3D0BF7125600920C4704D301
-5526901536DE27871F7F012FE20969F927046CE21F88267C1D56EB22B82F9F05
-601296502DA9047800ED57046C1261CD22AC350D82199A334DC57701491268B6
-6C2063BC3A08FC04A20A4900D5043D50130739A5228F2F197E341B9C278713AE
-5A1FA22B014B05E9600127DE1BB5570070AC018808CF12B92949F546236B0FC4
-01A6268702500868C80191067912408C0498500D93076E2D612700C852229C27
-EA28B6279F1F790ECB004798115F00FC3949791AAB48005AC4163B5A06F402B4
-400E79016D0D3EB54000D8055F3B269E1036C226E5310A780159B105F5461091
-04285AC97E004A07F600521F862A64276DF45A1A61F10194C4550CDC00BA5803
-E364046C257A3304810868F81F86401AB5770E6A3B1FF23512EA2662345A0186
-05630990009D1A50117A1A3BEA781E3F5A19B037C40126DB4100F128BE1FAD12
-FB4B12A53F047C095B01810850E53E1F6CF20241BB35550ACA019D05348D123F
-7900A1316C3661009A27CD1FF15A017E274B9112E26B1A6093067A00469C1CFD
-2644276500B81A57E00E3A27EB159E2F7710D800B00DC6013C06844022712700
-3377277B1239851242B50DF6004EED26C33511AB280096350450C701910A5A85
-0540AF00F83D1BCD27B21FE13544EE6004D1680044B800F830630147A3572F17
-82267801590A86049C39006CCE1245DB3B14C73200679C085129830477228827
-6B215AD626B404F0500DD112AE26D916510C8C3319C521EB153DB10041C8012F
-DB1B4CB4053E6C0080D61F94277F380079AD037534540BC140236C32811F4C9E
-27C30DA9098545EB049F085BF424AC0036771F3E9C1244008F460176D00D49FB
-213E6D26A6152ABC5612771FA64F0D6C00865007950026B03E24A00C2F7E1393
-0DE21D79126CCA079E123AD13E25751B62E12352308700954E2678A40D35B320
-D514AC0EE700B00DF438007D1B653D23931F500487093FA76B0050A408790084
-095086270DA5530B3D831F5BD10DA93C04510AEA01C1651F416012D2267F015D
-A409EB043FDA117900692BD41F8F12631FD0340C791A60E015C060056CB45A20
-D6641A532F7D129403D94501E368003AD50484099337E949132FBE1F40864F12
-8B1ADC5A04B249276C3C00FD04357722E76B005EDF01BA2F05840CAF1D680DFB
-024127F65A018605652E5A1A7B32731D5FBD0C45A100CE055FEA3E2065FA0425
-DF126C3449AC22CD2B04F249792171BE08F7015030601179CA40146D3009F805
-B93C00A619E13D1B78265BAA005A36E81D9A014E043AC05000934901C7270482
-0A2BDA22490479093CEC06AE00C32B65128635501C92186C4024DC48017905CF
-6C0355DC3901FC056C3D20853700CD05B55E23864A01AF0C43B41C477E125AAE
-16F4013AD23E1F6CBD005012C2244FF000C14E08CF0196045031E4126C2F8527
-0078C2013A86462A9C00F8052F74016A9F123900E904326827901AB722EE2E00
-62A0218647247B1D955A0D864A04B500CE12502D94164A7D103BFD54A201267A
-14DB2F51954738AE5000A00EF927A4124E8422794A07B05500A205C027FC0CB4
-60002CBF20613D259412770BA8274AB400C109F35A1A770E43AA14DF314F862C
-048C0833EE00406B2749A70460B20733841F882F7A183D6C402285276228DA11
-9E0153A91541BC6C132F991A50AF0B643E1E61BE13E8361C62BB6C1541AE00CD
-0D6A0074054EBD3C0DDE00B55901DA0740F13A1F7927692F8601F70BB9063FCC
-6C0D227842F133A605862608FB01651F7C2F84199100CA3001D43714E71E32F2
-227D0E79015A3C1DA06C1050AA0BF500B82F691F9215602D476A1229A526E936
-087B03982700F66622CD50199626C501771A88122A5AD90CB004E000C70D9E01
-A504FA12AA216E277F3506FD01540CDC5B0DE5003CCA01B77B0D41820C5AD304
-4E239C5A127727A134E229AC125A0184279513339C2785216900C80AF9129F20
-763463238400501AB0D807276A005A3F12BC4B1A7811E906CA015B376B1E9A45
-125E9D0041860D5034DF432F9D03E70842FA0028821A5A4104EC5001CE0AE604
-AD407904870067C01F5A11C7581F41AD00A13D04790E53DA4000E97903387927
-6C2560347926E51F50387A078D00EF1AB64B2296278D34007E2678105B274726
-DB0128B40030860EFE013ADD068901791285217827FB1B6C0440EB0E6002BB11
-772D92364E00DF08AE03DB27A6278700304C9D1AB720EA6A008F37B749277523
-50BB0FE2540473F601276AA80460AC006105B812702286341578C70147D7209D
-133478277F1E893200D95016CF2E0149F03B720591092F7B0D65D51F9F2D0799
-355018A54700EB0EA40892005B0A69BB0044C7344E0D6A00793B0ACA034DA31F
-D02EAD1BED77044F98531A8F4417A827871F654025F51F5A04DB009108A434C8
-700047C44A2752A4045D05C159276C267C18520DF4126004E50B6E068E013BCE
-41046600D20D9D04277C0032BA1A2D6CCA3D1CD82D12CC1F88264ED04801AD69
-055134A60976005DAF0E9E005A27C6520D33842252AC0D820126B71AD75013F0
-26405B00FE6720B40C6D27C422603949FA15D22786311397235C02D68425C412
-DF5E1F40F2125A0483086C003ECC0F24F93A06E36100480BB400C46C0950BD38
-48B0193E5B1251208D256B16FE003FE5159D3F1A850FCE00409E69013EAD791E
-39CC402680195A0DE3149E2F5A39FD521AA56A08429F0D50087F007949386C09
-EF005F26C41A2DDF1F90238527CA3905DE2650F10C651F74F8009D076C2750D9
-47336A00963A069D01C7344F12810158F3004C9A0687012F751FA901DD5A05ED
-0F791A3D5906863F00B46D0537BE4021FB27B512508640006BA53C1F77DF5D22
-3C501A933001860B2778D000E505B10BD601790D871B57336A00EE04A13449E5
-043ABE6C2501B4520061F90CB2279B206C4303AC086800C54013F15D01B522EC
-25970FFD01A033498213950C5392116300EE05660D49791B84043A7901A4053F
-6012E430BD001B7903FB2740BC531F6C0F7904B924D22F0D863312D026B45405
-8310713E1B8636A12DB201E62E63179739199E69008E60017C19972B05BE7913
-5201C00D4B0478F00EAF00D86626F66004502B7036497E1A50AD3B26AF01CE10
-A548385F1B9112861E500DD63C5F1F9912326C0074043EC226F31F85128D2F04
-923D1F7A2782005A35B3195A0DC40127D9043EF50046BA3B1750B42FFE00A530
-CF10B95025D41AB2385A0442733BB04B0E80046200E82AA61D8C37530596421B
-DE5D006D0D3AC524F3490CCE47006307416C0EA201F44A04D53E12E63B0FA631
-5600E765270AD42094288D27C530017C26603F11A70041AA129609CF0331EF29
-0466DA0A6D27792E09B501FC08662CD0007916A505EA094AA71FD224F05A0D7E
-006033D02650DE4A00C705E31250D0036227943F1B6DA43050861E37800D6C9B
-270087123F5F1444693D1792287A018614A020F8125F269E1BCB2177278401D8
-4600EE6613BF6C0441AE1FE86300792F009D5012C522F614BC521F7B300D8650
-01804E1FC74908D96B34019E48316C05F60080095AA21750E8069422790D2FF1
-1F6227A06C015AC11F3E881D9A01DF661F792553BB035A32F6446C28773DBF01
-8312793601941B51B20B41019F0C297927643486203F760CDB0069E50A5800B2
-074DAD04E74002D057266CBC09E200AA04FA004612EC23C8017C0B9400CF0852
-31860CAE143E6023940B307C00299E1235860231A41A61B93B03772780016C3B
-00CF2656B0271BAE2E089302388D270DB34912EE00AF3F126F22D61236CD032E
-8115C634D46A0150BD003F11B740077A004AF30D405013C7279D003D98138526
-000DB200226A2A499E0550B92FDB05276CEF722160B00E980ABE01A307AB3145
-AE3A1F8D22FA1241D8193C5A1FAB3707E4013285266C207F275BC17705502E60
-39BA2B501F69F20041DB014AF712BC1A41AA20E64A08F85022B74A09DB04521A
-FD26AB1250A423884908DA0048FC0E5CD62653F1004A831E793750841A5BBB33
-A60149831F69B600436C014F1FA4380D78F826611EE627B312306BAC08860050
-12EA204BDD0551C7344980D804F10C32DF1F6B124779C5003508CC0038FC266F
-1B6026F61D86115601C0053E6B277D016599007F0C659E1F54A30550C54D0D95
-07491F67AF09E0005904DE770138A20E5E347E056D005AD00151118B38610178
-0D7C3F20852799058C00D53104F00A34961D3DA0048534009D0B7424B904FC00
-C3082CD70150076B38FA0D9C085234FD1B9C0B7905DF5D19478600960C83045E
-9F0029F8223FD46C067C0B41921A65E61127405B1EAE54008609A5003A125AA1
-49279D50048500E62F81004904EA27792750AE00CB0D9F2E12C727F82D0F7939
-1AF6123901E730B212DC0034791D8627843412B760197926CB1FA7278F31126C
-A33D04B31AC727EF1CC05B00EB0E69345A1A85461B56BF004F7A226B19E7641F
-C43060137B276A2286410F9E24E51A95005B26DD229E045436EB268C122BB40A
-34CE225035D73C1AC45A029F640434AD27C43001A9220261BB0A993B048C2748
-FE2661E8771F3ADF0D6D17A5335A12981F68B95C229F16F30D79315A3D1BEE56
-09710146BD01D25C006FAF601A84006C279A4B26B610F118A2450626E8049500
-5909E40447FA2706CF662683094600900634932650BD12E73D01C678106928EA
-01C80B924105834101DF4306C90CAE03E162277D04614527B33E017E0D60C212
-45AD00497A01995A046CBA00640A8F40127F1B3CB959106C005DF80E73A33600
-6C19D44D12C63404851A4D0DB901794002EC4506D23F03E00B4C007D06850063
-1CE004B06C0134A51F99602281182F91244906C82352D1053DF501477A00630A
-CD704C37AE1345853B199E73005B9A2900E3145AB86A2756CD0C7901408606AA
-67203EE0058E156C27A63312B14C119A1A8B34563A6C2F5000C20D3DAD12E004
-884F1FD22F007F075F32CD1AEC401FFA2F10A026EF4B05CD2EE40C5001F41D86
-123886271954FB25A500903E019B5010AD0193286A13BD345C22AF1383502C9C
-12CC35D92F41C0500B771340BB6805DB4000F10859B704EB1694277914428B0E
-53970C33C327792F00A51A5A2FF60DB568270DC0350B7C49329801490FDC013E
-A321E01F5C294E0D94005A3249B607850056D50127F3266504AD00EB129E2291
-1C4CF500792C6615F040126CB025DD1A85043A6900880C47781A7F013479226B
-018423782DAD26D24A00CB8506397D127826EE5721D7402AE24506F551009509
-8B006726C300466C401A6C10A5032D9123D800531A862A128B319F3D12793467
-01F608A5012DBF1F3EE4511A9202FE400FD8059401793E00D5571E43F41AB005
-4FFC26862A781B624009A700CC03F82DB812A4013E6120F41B385F8700770ED3
-1F7F256701F30A3B86219D490CA53A006F99013E51049D2750B715A52760BE00
-E12F50D300A9159E32C814940475059A3E0C22BE6001DE4705630A8800840464
-2086341B7827DA2C50FA0437A61FF201B1054F1F5DFE00A4288426FA0050B849
-0B6B00DC410CC04630601EED69007E046101B31250259E53277F21C450128634
-04A36C00642581370C77009F0AF600B96B2678316C1860227027FE0DCE400E6D
-9D0940BC36A72D4E08A53179275ACB016D0733CE035ABF0E27F81EBA6611F600
-773E08D3023B934212921A5A2CF2085F007D0DE234501AED5A91042D991B34B2
-27C71E5031B40DC5005ACC05AA0E85193D775308860D5A2479E87E0741791662
-0C9C0F3C7B0427D421AE4E1C80008A0FB73850129F30D822862769D0057708B0
-00663A1CDE2360EC143FB610DA01C05A1BD5227E2F593C04F1129D269205D902
-7F1977265AAC002FE21457066A01E75A1ED005B60040AE18EB6323821B419F48
-088600348F205A0DE7501F78125A07AF043E860E499927DC21405A00BB6A0130
-1343F30C4F8400740D67F913703E259812397C1F6301C70DB31EDE263BC43900
-4926C81236BF04E33350C61FED6A05823402A627E42251049C00C749076C3D0A
-F1003F612DE31243EE0475089D014085072F9327791F40A304AE4612991A8634
-5000E10D7939A033C00095053DC650017924FA1A9E3C008611491A85125A3550
-00B210D82F0462C52650E20542C5306100B232EF27C92162FE00B53604760B64
-A91C86271278D966A60040C112E526B036019E02EF4D07E15000F731A0256A00
-7F046093046AA20F72018C5027884A06940147123AA4135EFC116E053ED06C14
-7C361AA712CA501E900EBD015A35911F4ABE4827CD0E50C860016C0AE9006434
-5A07DF01C84A0EB8601FAE49005A09426322E712681AA9278D003E7721C22758
-FC6C26E604920E7B2B6A016CE83D0C7B125B38AB0186129723810D6B009D4626
-711761EB26B83502FC0840C646071F54308022770451099449276B19862F6522
-9426801249EF472ACC1240F93D1DDB28AF22EC003E19D4275DB3770050C3002D
-851F9B65002EE12257FD00415C04AD2F7E207118A9017A0B610086229729043D
-E012AC2F7512F1227C27733700822904873618C627ED1DA53B029826860CD210
-50C504620C9D0139049E2FA527D21FF62688145000AE1AD4007F0D6B26D70557
-01BA1B85380BAF05C73E007F074787224F9B002986B50DD5149E1A3CC9601ADC
-05AC3D00B404C10A5901BA055A129524AD00570B8F0182086C0D6DBB6700790D
-4B26E01A41934D0BCC330EA25A09AD01742F961F8326DE023EF8500DE22CAE26
-FC114D00F0791B4F8B481A9E3F059200BF0C51FD16D14512F16A0B82016C08D0
-4E31F0045C4434851F47F24C1B70B4410F6B0077095700A106C9278330692795
-22F017A22A47FB49286C04E4591F7D501BA51356D0003DDA0D5AE704256B0255
-00EB7927018A2F610ED54B126C1A43D53C1F7927D801791A8727BC215A35CD1F
-A82F1144AD22F404950E792706E63D005DF03F26921C4F26BF08E9006A1250A5
-003982227804521A6CBB5D1634BF003908D00052BA2F501E9922623E059E6400
-309F254ABA471479005437B500E306B20A7700D8270D62E022BF1A3C9542345D
-1CA50EFA01B406503477007A096411D225A53200D744018627E0331193681F79
-19379549FD38B872400750F14100A2531F9E37F8329C1261E7008E0C5D34E907
-630048F1044161024BFA053185176433B701CB61126CAE195001C90467E40D48
-78278A33CD085B279F04C3123CD07903420A9E65126DFA6A27841F6913E55E01
-D409AE6C1F3DBD5003DA0E5A008720D82491166A227F265D12A53549C9003E98
-054CF004BF11E447015A23791F61C90340DE22B01E78007A0C8B6B132FF80E6F
-0163A02704C200B06301147B1C500E2CA21F7812BB3406810077086B007B0445
-A5213EAC15552FD039991A9E12E32780236EC6013FD600468A3C249E0430770C
-84227834008F3901A60D6D23941AD413762697650039B11FE72706A5263F01B2
-0CF2027805358E267D2C01E20D792072299226FB2DA30D6C08F628A10140DE2F
-550485147A2060328E1F7A2570008635B83F0C92390EA41349860150BD3C1FF2
-4009A65F1F9526BA3905F24A3185260ECD6C00AD04D66600C4046C2648FC24CE
-27B326E027AE330E51FC01760BA302780E66277B0052B5013B0F9D561F84265A
-12F91B4ADA22BC27F812B55A1FD66017F501B3043C694000F3093FDF0D478600
-4AD750048D4A165F3246C540B10D5000C849326001F606AF0A6005790140AF3C
-017B0DC864057E1AEB25AC08F901C60C5A01AE27CC1A6E0565D000F550278505
-35EA27065C970129CE4801C0045A0B498316750950F6472DBC3E268534158525
-3BE40F7B01560C92014A0F861AD36C057A36C04926861FE100C511AD3E0D60E6
-782904A70CF005A2013F7C00860579008640109D063685225A2D49EC0DB85928
-7E154F9A216334940130C31FE338A5008608246C2AF85A12841AA94234861C45
-BE4C1FCD621259C31F703612B727960175385A2B801E48DB441451049F27EE12
-502F5E01CF20B960126CD8193EB6680524913543E42BC900AE21D03A00780712
-60F30B5ADE0DAB5C0554C82EA83F1F63C25A0370003CB841126B00F4065A2F6E
-4332781FD62649155FEC35691F7F2850B50EC238501FBA4903EF2750C60441D9
-0F8801793A07CE01B43101F905C511417A0A71006C12D32758E9009E0438B107
-EC007D1150DC006B12963104E51A459C00ED4801600EBC4500CF114BB5006A08
-77FE3D0D81009226991A7D107400429E00318802511277EC4F0D85006C126029
-7E04941DA552D731008F1B47790040B33C00761169EC084722F4309F1B6001D1
-258E2849B80AA501FB0855009A04BF0A4F00C54000D80A6B345813EC60092E81
-1B7700642FAA006D1AA24F1F85276622905A1B79275AF215B6279F2884219A0D
-3F651249852276279D1FCC04267927ED00498627A50C336C21842FFD39550B86
-1A8204338D26A32D0061BC355A1DBC04E138A82EFB0D27C4590CF926B3420027
-D5239D337B25EA125A2FE23F011F9C4124C60432F91866209E26D9003584168B
-067C0EEF279D1A5104C9186340276B147FC73E1F6B2F8227951A5AAD239815E3
-019F043271DD0DAE29DE2094128131CB3E12F801AC0CE5043FC3089E00308701
-490DFD045A01C825B534E01AC4015D0A5538703EB8065A37CF0879005BD304B2
-099500791FDB24AD35E46019ED114ACD1F5012DA410B6B480068084C966C1238
-A51F82042FA862036C0CFD01A50541C0016622865D04B76C126299268703ED09
-801A59AD01D028B2235A0082083EEA600D9B00DC05BC50270576F412AF01DD0D
-7A06377B016226792143B3003F50018F0A5004FC45086000942C5A387C1E7726
-6B4512DC692258D7661C50BB3E1984048C00771040DD30B201E60D48901A9D12
-502DF13F1F7C265817C212A0043F660D5001A7053E860493097B0078329E14D5
-22B31A3F01DF7900500ECC6C0A3DBF1FAD278C204D8D1A730DB608ED285001E8
-4600B5103A6C4129B9052F7A124D0041D8491FC47200318127771F853B00A461
-2B008522771FA430E74C1FF62DAC0DD262129425C9601A6CC0345A1FB725E24E
-0DD10049B807D800B337501AC605470092340C77EF0F5A1FA62757A3007C126A
-2383002FF9035EBC1B680FBF013DEA472761314BF001BC267E225AB1226330E6
-27AE22F5015A30850060C828531669E3355422F51A79400078073FD2003CFA27
-57380F822297360D7D1F51CE01A50B6E48F61F60E3711D7905AA340C43B51BFE
-0CB44C10E54418D04A37CA06465D006903920984006D3001FE1E6F123EF53C00
-7B0C9A006B0434A826881633931F500D9901800E7526AC20DF67002C46D84A0D
-FC053B6322F729AD15C850227D34059800922F4F8600A405D500891F74279510
-D74000F30DA5016A05860F3EBD0444E73C0D7E04AD2F069A018A005011DD5914
-E85F0DB055067F009F6900D10753BF30DE056A264AE3133900990A3A04A71169
-264EE2791250015A3F22942F048B0AAB016332FD12B61BC3385F18C5269A5028
-8B00A9055913B226EA2749C84188096C05EC60023DFD6021EA27A932EE127B04
-3CB57C056A017F297914D0500B9404406C0EA000D76623F74907DB106C1A7E38
-690EB106C8003B6C1C7A296C1F8618CE344B771B8A106F05AF27F021874819BE
-2D42A576042D98381A8531129B1FC92FE04E1A79126101418612942F0079C55A
-27B650C82750F9008A260464D337A706EB0153C1355A1A9311860040752F5612
-DF3A5A0444C91249D926851F970A6601851B700E29F11FA04012BE79002F8F04
-77098600522FA212501FCB24AF1AC200AB3F0184195AE101B91B56400D853713
-7727AA22CB4515F22F57401550FC04A0089802C336465707B500EC26C12C641B
-92125001D9385B0DD4072760C30150CC0164E50179491502368626FE27A41F4F
-F104C05F214C0F8601380C860131AE13409F2C04751F6B27831F6612F32948E2
-50279E04EF089901A30DF235008608397801E14A36D05111E304B563003D5400
-86270E42AE145024C91F5ECF0347F200730A56348612754B1FA232D5253B6243
-33E919AD045AB20192033D5A018B089E00DE7920632F48D114445B00F8127524
-7D0C5B4701FE51003EB561108500792168EE3D1F7E330BA12640AD3C099562BB
-05A6008D0CCC0026693E07A103DE1F6AF05C239E63076CC60047AB0EDB00B00D
-D7007907A0003A08D5125C276C3453276C1A9E6A1BB05E119E310086062FAE22
-5A401579C423DC1B5AD06C0464D93F0080350C88245E27B339F60049E23604ED
-0D6C007F05960980017627D11F40E21E60FB0CAD28612371340BBE01B40F5A33
-EB0D9727A304DA40329A1F851234D3770A27A01FF33297035000B20EF25A1D83
-125A22F52711502F6A3C175B2C7844B316FB256C3295084900D9123FE83A1A57
-F5198D297C346F2747BC50226DB56B244AC000AF0CD800B550052CE53301EE23
-52B912488F003B9E01F732046C07A4460B35C027086BAF19FB411ABF0194056C
-0E8527069A60278A27B71BF01FCB27A00C5A007A084B8411348E1FE312C605AB
-5026851F7600AC1A7B23671A835001B308D900A87906276AE804435F124AC61B
-82266C0041BC00D506760085D00AE801C349E0019E0A33840E3FBC0041CF1AA4
-2885005A0D922F0B79256108F6019E0C6504DD0D35019D04793D1A8E1F763A12
-D459047947188A0C762FF81A50D40C83265D9B12843301F776005AE4122C7901
-649D0D7934DC21A517BE692F0AC300500B5C3179026025FE34A5269E3000B357
-056D0080492E7900EB0A3EDB27693E05C400E44312861A782F5D401F5ABC0052
-34C401AA0A3D9C05DD29AD156A36522EB93E1A278B21406F04396C1BEF6000A0
-5A1A8222507C046C20CD27B001C95B00C513A51F5822ED1F7F27487BF7165122
-EA620250F9047F3E1FAE25C36804D1276503A3246B401CC1003FE826BA6A1A27
-B43101934712BC263BE743156046045A3F00DB4A1277FA389D0049B51386116C
-05DD1266F03E21CA279B3704F91A69274C92019E08E15226733401BB27F04904
-C20DE20238981A7E236C27E71F63401279229004EC0D85015E9E6E0157AB1299
-22BE3D0527D24601E60DB4013BFD109F06791F803E1C96386C01439A3A0340AD
-00C4093968C80A4526CE3F225AB9006E0B82003BA64100DA55127900A7540A81
-19590148129F500D96501DD54F0690005B08B200C731EC229D1FAA3D26046C24
-D90E3D6900BD1F89287904500A86006312BC6C0D40B101CB115D41307901A50C
-9D5A216C003995266C2785480CFB019E088400A204CD4901FA0F61259F1FDB46
-0727C81F3BF40881005DB47912307B27622A861E6E402F6012EF4904DF4D05E4
-30D0126CBA61153D5A2C92002780AF066B00920D4C27E94112FB1E6012863D07
-BE2AED1234DA27AB0DCA793A00D33B05F43A00823F1FCF27832E6C0F7D016C08
-50017BCD41B5074FA51EE1472E5A01C220AF27D61D40E950012698561283482C
-F716B51B4E2FF23F06DA0EB25A0BF800AD12CA2F4E7712DE34562C6C18A5345A
-39BD50006E3712FB820CA10065472FDC0E490459AD089504DF0BC300B104D652
-0134A11227861A60068600500E79E404A71ADC5B013D791EAE29DC177901935B
-279901E84D2195267F055B92016922772D06EE54227F421874B312F15A0B9504
-F826A41F3EB832F3640E5200278D3501920A7906EF460D6000940F53A8073A78
-D32F00E7340586046D0060C60465178427793315812A782160018F053BAE451A
-BC0DF7500D8300980530D11BB3580022502B7815AF1A509E1FEB3513F71F6B33
-435A27486B3C23B76C0C53BC0040952649FC27CB012F6C24770E34BC13F1500B
-8401A031CA3C04C00D7E3409CC015016AE381FB413FA00B24170108600A86004
-2F790236AB2249117900D3581682112DA11BE66712F55A2240D13B15933CE548
-307E016C279F220861A41F5BC41FAA27D638128623CE009B044DCF03B80850EE
-3F1FD02664008704613F01BF26D71F467B0C770433AC60ED04CB400586013E69
-00986C0050C101A50EF109A30086072EF8206933EE12C2320C811C44B10AF904
-AE5221760032CB223E66075A1486205927AC6C1C3FFE6100E051087D49366326
-01BE1FE2290DD05720C56B0067BE5A1F97420491005AD7046C3F05792C03BA6D
-0061B400266C12C523FC18CE0050F33E108000457B0C5A06834900AE35601EF4
-2267401F93310E9F5A087E0DF14C3396247B2E6C085AE51AA826F06C12013472
-105AF527D112B8501938A5233D831B7427781FE1125093007809A0014E05A45A
-029F5F188648377A01EC10B563056CFA1CB123E4003FD9054600B879042F860F
-3AD227048D0BEA4E307904509A3E01850933E0124401D9380DFE27C2234F38C6
-21AD1AA1640D2F9E1A2C78CC058600790B4E3988126A01BB26DF1335EF27AE20
-FA395712A4500C7C00E85A01C76A002CE41EA43D14C71BDB129F1F8632019300
-554009D245B81F9F320179246E2706C95C0DDA054CE800BA04993141CD193BD7
-552260DA6C1F3EE83B00D42B00C512502B89401A9D460351006C2E9E6E1266F6
-2C501156AD22669E015AC61FA512960547AF22641CE826B5501F7F2785096086
-1A770795007D0C6600DA3C13E75904FA5608503F1FAC2860A5042BB21F79315A
-06A1650078046C0B9F07E50232BE279E123579143EB77903405A048D00830856
-00ED04B461223CC71F8626660D7F00C34C0DB200E5793402861F99263F611646
-5A0D840147A5042AC0154800B40F6A23921250792665A0065E00E12F117BCE36
-A80A4104B53C018623D0360AF20031831B4679006027D6380AFC00A40B3B6C04
-9E00EB19B32600A935501FE9279D2683490188401F793612AA22F45D0CDB013D
-E8580550E1029C384F1ABA12CB31891F79264184006C0947AE26DD04501168B1
-22D6276D2A47BB492771390EFE6A077900A102E92F5E13953B20912F114FF92E
-6000D10DAE36CC00FA26B26C11409100850D7A278B04C90645A509E40134D927
-A70C4EB42708791460F127691ACA0C75008F6C1A45B90BF00333DC2485006995
-126D2A4F971BFA265A0D6C2F4BE24704D2600B6B01FB0927CC4D07C601B06900
-85043294268B1A750CC53F146C0ED100792841640149D40053B917E020CA6201
-841C9E27F63B007E07A60CF801670AA412CE520140B612E13A8E471ADC3E04FC
-64075AA5006B0BB4502177016D22811A530C39EA621AF525BD34F11A406030F7
-1F852241920D851B3E7E0041EE1FC6004796008534A31FE52A04A4602177275A
-94076D16AD1D2F4CB706D4004C0E48AF39CB01A00C28861230BA1FA533509312
-2F9A26831439D42751C0004F11BA48267D00A721842654FE0CAF23ED0D349A12
-693B058F4117FD0D3F6100731FC412593663179D22D92779043392216C2E5815
-50057A01896B1E41CE3C1ADB27783F128C2FF2159D063ED979045001792F5A0A
-730150B700940D6C0254B0196D005AFD21C36004522E8A240FD7491365400750
-C53D0DD901A01040B535F50548DA015A3D2060BC7A016F0640691E78C1004997
-056F400FC40060EE00500BE64B1B7D136B38E36C0733F71A5F2FF10499083B6C
-025A15905027F601AE5F2600A43150BC12CF0A9D4730EC00B94E277900881A64
-B20BD7009A04AD20C626B63909A5007904864908C601EA04A10B512DC768012A
-B422CE0EA0039B27D2126C3A1FAD28D93804F427BE350187092977A30240BC57
-3006F200BD79115C0092316818E1005A0D643981129E19EC7705461AE327BC12
-F650045836F3224DDD02871F80371276BB336105B501F10A9E042798640049CE
-0173344BBE19D62D9F4500B706497E223EEC79490486016C412F5B018A1D6C3D
-02E20E5330F400502A60461AF73E860C416316D42C5B23BD0E31921E55247B27
-61B1005012995C156E30821FE21768268B01E750087900618C106B0750B21248
-DA1238E10D790173AA275A3A269E1FF84A12B34E26861FC900A5046C26860032
-CE2798126200933C26D31791088500652D43EA04AE502704961A8626632F501F
-51C40124A312813D12AA013F6800861AE13D1F842F0AD00154072CD71F3CF01B
-B015E30D50CF12A01F61C60548A41DE912B0345C00275AF0009D4D12F3401A69
-ED0441B8670DCE01358624E43400FE08AC0050358500AD1B3E6422C427B71436
-A427D21F65337F0161981B5027FB18500E9A04DE016C3E05830135C104742F54
-20E629C3124A7B0C6E0052A3345B088901AB2F5B12B41BC1155A276B01F75A27
-E10040D003B278108041D7345906C05022E90FAE400D770462D800BD6311931A
-C36A0BAD5A0E72018224973304782684003E9513396C0182057613DA95033B73
-3F068601AA770053359B002D951F4AED056C0AA341227A275AD70540FA0B4BCD
-0596005A0C4ADF008603760CEB22B727006CC404419E00CF1D811251AC26C822
-ED6B1A50FE119C400C79003FF81FAC26EF2F04DB22C51F6B4000E046276C017A
-08CD117D40067711AD5A1E723600FD2E0D7818EB266A007E29711F57F525B312
-306D1538A4277738128827009B36CB295000B54309FC2EB32050E306BD5227CF
-24A20822C612B21FDF266E2F14C026D41248FD073A791244C2491E6BB502C511
-479712602FA50E70133BFD319C1B69223CAD4200940849F8123284205A376C2F
-46BB3C0079095F40008E0D3E6C01CD6127B55A0A69028309AE410F7F0150E90D
-791F9E0CFA38AC3B4E34C225A61F8B37089F0FDA5A1A65BA006B049D2FDA0BA5
-00CC053E60014A8904FB581FE20050F9034BDD48047808F96A1A8F5714700D7E
-013F8A3B1097017C2F785035690A5A009F11DA4B087F016686225FD803AC265A
-01DD07513B1A860131BA007B2540EC48A101840A7905EF5C0ECF2F5A3A81055A
-A501E60CB105EB00631AE8124DBE1FA82ED504B33350089004348622CD376115
-874A30B83D1955B33A01854A056000E80A780047D70248EE247E0443AC06263F
-A5385A144B851F66277C1C9836CB1BA3400E8508B21A6032A6122CB913523E22
-D80138A800E826CC124400F11A5A0DFA00AD01E9278933573E01933F1DA73205
-BB003E851979118F269D13E86427F36A1C50E1045A00266A3F1FCA26AA3F0186
-1AA513E11FB236197527861F6014910B77268638017F066E25671B9412F02243
-DD00A74901E15000FE0A7700962B0565D43F16C71D9D1468399E0E5C2F7A0069
-2795133179D2550FF400C40D3DFA08AD01E30C6C007A2705AB2D5E3992007905
-66882264A5007E1160C31F6B335A1C6CBA682749B9471F6B12811BA404FB0CB8
-6122F5540CE147127F1B50C500F12E6100753F019D0639930F2778C139B207DB
-5A0040561FC52649007D0B6F0050DB08BA0244CF3E23FD2BAE0DDF5927F415AD
-00E7277B005A9D157430127F1B2C9E1E6A23DD126CEF1A5100862D782650D301
-2AFD1AB022C817B701ED60004903851D792693016C44305B22A127ED1250D34A
-01DB0C49C31FE64200ED0534E127993A0B82049B0690044A09D1018404CA38E1
-065238671F7F2D069F00348C205AAE27E30A3A664004D339B30DBD1F5ECB00AF
-600A227F1A862F1279E704880867F559279E25C712683959317A009556036C00
-7A31049A0C503580126126D1370DC52364F206B86C043EA64007A134007F26B5
-0DF403B9073EA852096D01840B5434873F0DBE21E02AB0096134B818CF12B44E
-04790A3D910034822678290799380D951A46790A5E03F45324D827B52FF82286
-136C2D781B4C6130D500BC5000D16C125FB10478003B6C01872699128646096C
-2849860C2C801937D65204F5015FC13D1E6E2FA2173907CF0161338600A511F3
-22B41235A020D31760C11F68CC0249BF06A90378480592013B5A400DD35F00C7
-5A254FBE129328771F63308E126C1F9626D83347F9125C1F82276C1277224FE7
-01475F05850036C8245ABD1A61F00FAF00F25B1369B5275AD112BE26A0300093
-0E5B0B79006034AA24EC0DB500228613700F29852241EB3E18CF26F31FC8401A
-F600C0501C9F22FB0033DE4905F17601348D25770E4F00990CDA0055BE6C1F50
-F00448E62292014B0566E20751348C013C850028991A39791F8619FB2E4DBC13
-9F1F862812843102F90D603F06D00152D90046ED04BF00405A048F00A205D500
-A70A9D00CE042E961FDD3240F065078601439C0D307622864304CD2F017A0435
-85006D0C65C64236EC40199F10DF0088055E2693C5013D9F43E5089A01560B86
-2F930E520867A40D5C3E05EA005810935303972650125ABA149C2BA923F1276A
-277A104801873512962E0D79275FD67D2A1A78B90944F90E4ADD4108F85900E1
-335300981C3F6C00DE0457EF21B1681A8801E2491F9934128522583E2278EA14
-B21F6C412C6D4436F630563AA8500C7A00AC1150209F27FD2E03C44701C60B34
-7E2154FE19BC501FA62ADE1F4E04830152C7266B27701D4FA53F081A6CF82601
-6A3C1FC326A2006C043DB079005032941F7F266BCB4127C52140B600CF400979
-00DB046B079E01BB1BFD25AD0CD74106BC4F01C509480EB2410027961B50A327
-05926A260E9E4812C0630EE401CA5026A938017A0538A1276C22833E04B15A09
-A401D5660D31850C3BC319E40F97075A0486177221FC276A1F7F01CD0D791A71
-501E9751276CDA01AE0D3E954001EE085A018412AC1FD22F027E08A304D52700
-F458B147045CC712AF5A0D7E27E01FC4611228D623B801DC0BAD3C017E084E86
-0D6230791FE926691F51C03E125B358500742D6C218B5C18833F1F9A24750460
-F14B01C32E0167C8123DB86D2F01A6073884268D330C7908854913D54F00D908
-AF00F0501A38F727913005BB5000E067067E014D23CA1FB211E3006A029E08D5
-29A5395A00B711DC3A06E7004819862771005A0F802477389D26F72963146BB4
-38FE1555369765123400278F0D3F83002FFD0149107A3301E84E0C8317784A2F
-60129D1FE13401F724A90666018832A40C387B43D31549B10EE004A3003BCC04
-FB5200E727C63012863A1278EB3F1E79005005D26A2243D8046C115EB52AEC1A
-C32F610D812D79123A670CBF6F006B107F491994274622A3265AB66B007E3861
-2741D0531A844A046B12E2314984007E411277A53D08F21CC427DC2DAE11D105
-5B00790993004B055A3AAE01500ACD7960E622A61A4DD36C195AAD6805974517
-974104FC3F00B405F62E5700A15D1A7B123EC74E12FB017613E4270084093193
-1B5226F71F6A39158F3D118C00A36504DB600B5300B527E625A53411EC5E14A4
-27F5034F006B3E009822F51F9D2658CA047E290EAD1BC500F13C03CC780039F3
-024712EC4901BD06A20B27C12F0DF73477019E0927A91AC9542704BF4F359D05
-80046C0061307827A235C327F0209E127D1FE2269E2F0D3E077E02F2280440B5
-06371BEE25B75B00CD37590E861A794915B96C123FB100E46C042E9F2546CD4A
-0262B537ED540567B5440A7700A64805BB501F6C0C3DAF401FAA278613960481
-0D5A98042A77007B1D9422CD12A04A0F6C045001E81A469D1DDC48395B2C771F
-9D610E3EB55F139721892F0E861A795039880058954800B33E1F69F804406A13
-F561107C00455F14B41FF622AC17E6117101860D6433D600870C6F0050BC17A0
-2F531378AB0E2670D0410085093074228A1FC027D23600850934D7046A2F501A
-B65B007F0D5C23A51A50046C20CD29007A35C3500FD9306001F32AD021570085
-04D5083B6B401AF4003955B21AD0345706AE356305DF3FB336C86111A500336D
-059201EA084AB80634FE155104842DCF0950C726FA3300EB123EDA12277C0D60
-CC10533494088600339A26CF0CEB374856087D028600501ED92750C004602A49
-B81FF02277D94400C16701477BE73B0162BF1A48F705A5016D08690352AF1FF1
-4C279A15CD22820E39D827AC008E06F627A0128A0141E5129D02277A1D812286
-2679019E0DFC2F6D2650F300BB60216EC22701864812E23A5A018A305A260079
-0B2F87265AFD12B72579279635125A86007927DD0D680040A500620849AD2355
-A10450C51FEC22468800C421E32449D702781A86267912963445CE2E41BA6006
-79003F7811F605377C0F69015E12943C21E02D00530DAE12503677137F27E633
-A429EC127440018E06426101A304F54F0B6C1BE834500D7E00DC2F4D951F8427
-5AEE05AF00E20DAD175A326C14921CA316792D50129D300368FD3E0882017810
-FB1AB50C85F71FA74104BB08406401570BC90069D70127C81C9E25AA1FF6761A
-3D942B77107E05662E86006006980328AC1679013E9F18AE2F5700B806D800BF
-0D5C048D0A3A9E1AE222B13D1B6BA70353C23304FC4E07850F6CBA1F90267504
-DD0092235A0F6A007C0A5A27D82550BD0FEA385633651E940185481277B1213E
-6019B80C6001C8083F653358387E043FDF00BC4A06D001600AAF01D9074ACE0D
-501FBC27A5279422790073173E5B01D76A277A20A435E35013791E3F9A450A63
-01500490340D5EDE05B601E526BE1FF2153B8E4133DB500B592FB867053A6012
-E43F206C286827791FFC4F26EC27680984015AA0002FD22709A380291AD0269D
-05406001FB2C9F27AB0CCA01B227CE203DC30149A0003176228B0DC600B327D5
-3604C42D006BC707790034F35022A213D10B9F1241C56A0F3C5B237C2747E349
-2684223C9126A31576005009D3005039E22FBE059D32500DE600C50974002FB3
-27FA0450BA31EB39C36B1256C10427861F3E5A400092044CD80ABC01781F6DEE
-04500F77FA01900864A4018409E701A13D00954900AD462CCE400DE549128A4D
-1E01B575005B33EE15C73D188012781F5F397A1A850D4C8A1C82301179FA08B4
-006C28830A6111AE691A5AF8125227E947713E12782A83016C1BFE01511D79B3
-09EF009E0C6A03C71153F0047B0059C536ED6B1860BD04620E426B12C7239A1F
-503185129E601A8412922300790D85062FE80040A650126CCC0CAB691237A626
-681A5410B100369F27CF1F405422C64712F8329E1E3F5916B00D35861FFA1276
-23851F963D00EA413455123FA8014A7C00864A06CF0055F01248DD0440FE00AD
-06E76B1F3D55194EDE1248EB2078003F9F05408601963A0DA004BA00DE264AB4
-47269E27E7012F951F5036B91A7834A500693F1FE63005820D299E340C861BA1
-01EE4A00770562AB0142F43E05DA006638E15A27B01F497726811B6601F03100
-78183CD77848009D31FB80274985126C008406A73C002F9223700C61BD04DC23
-65C5055A016104BE085A01BB561F94CB03F06A1BD50C2EB320DA31509B260595
-002B62A2157927663704A801C8782F049238019D27F1224BD70E26C64C04CD1A
-682F8616950D5A00770D831846770566CB015A2EFA0B477F13B3600E86411CB7
-4904F14F25D8492770218627F8380DD1265A1F7F2650B10D4D0686003ED701AD
-08D42E9E0D48B322F801530927E6136C004008E101BC20E930C21B75DB5A04B4
-00D140126D277C13502ED53AA0315138F42764067A0C26882F058624A4640879
-048F0D40C44935BF751A3C5A09D40FB45A22842705A05A23AD60127C0793002F
-76AA3D14842357FB05426002F51FC42ED80058B712E1411A800D8E00721DE03B
-0427AC01DA510089266C12910036970CCF07AE03509E1A8600A711BF32019727
-CC1FF35C128C1A406C145A3892047F2E9724B36C0450AE27CD631A7C3050047A
-0D6A024911861A3E542689009E07E9008F0C790EDE0099108618D923A9790A44
-B312503C12E435541FF92801850B5007E200B64F2178003FD90D50E53F09FE00
-40C9325A14BA65085400E327B30036A420D3403169048D22A438048633009B27
-D71F3FB939016CC946177A22982E41CB01AC275CC30160195930861568430CE4
-394D046BEE197D0E6D3702BB2756FC04B400E1104B1AD30D82003DC13F0C7504
-3CB5410DA66027A129F126C92767EF01AE1AF6395A336B1CA8276C267F1FC500
-3D6C3A0020DE62006CF600794101BC6C0063B024F6279F26843302A42DF61249
-96006212771A7F0E5401E1395022FC1F8311781F8E480A6C009B0EBC50126D08
-61F92050C1105E04A36C125A99102678FA064F0BF7075A3C19E70D4F2DA93AE8
-0148DD00B8316002CC761C405604B627A568137C003B631F7A275BC764014427
-EE1B6020F62B9A125A01F44609D300820A78009A06347C0D764910BA01CF3F00
-F305B40A672C4DB605FE51993B1FC3321A58BF169E27109944197B126C015B12
-EE6C136726840435B127CE2CB133D726A21F7A049601A332C1035007E927B352
-1A810135E927BF310C7E016B36EB513001EE0948D13F005432C2671B79239F67
-02881DFE126C227C1235801E7922940E2FA000D9355C004505DD22AE25C65009
-9901462679B85A0A8C0195068000DE229E351792225512B63A5712BF5E21CA2F
-01951F7F225A9D125F3147E704791241600E49018A07489C042B750546EA3204
-D60053BA36D6510540C700AE1CC95D1A8101860868007205880FD92D426C1859
-38D764147A0D34F1234C86067A00439E24DC199E0026BC4520A72B0463A10D85
-023DAF00DD0540B7306C058500A208C4560AF201BD1453FC0A7F269112F7782D
-5A3F07860134E621B50EFA144F1F7C32CA25491EAB2F791250C10442FB32601A
-E3355000880850E127520BAE044C39D1008C123FD728AB01C817F25027DA1261
-EB1DCB640C51A222902F09940031921F4A7912863801EC0E581FF329A91DEA49
-346600B40CED057C0125AE00CF6C013BD512B41A4FF0045A2E630D497C076488
-006CE51A2FBD26D921497D1484115A00CC5024D23363401F94275A368400405E
-1AAE013F500CBD1884F3124882156C2F92007307DD00A7055AD66A0E6106CB00
-6537790084059201A326FD1E3D9B4205D86727EF1779206F26A55A006C1A7234
-780C309400A53801863400AD1A6C3F06EF421363B10CDE033FE6054A772646B9
-4902940C5F3E00C8127727476227BD44752F5A3E18B666043F5A2A93123CC700
-AC38CD22FE1234C427054982127700950B36BC27F11F753B098E4501F904AE00
-7106D325AF1FCE3D0F65C91F95036D005036D100A60479274ABB41266C297910
-3900EA269928861CDD24AE1FD22E790D6F0461B3002691360085258E01AA08FB
-01359E24EF04B0006ABE1F7B2250B40D497A27E101C5601F6FC73E1E6A278522
-5C30D2099B006A21792750C0138F254EF1069F00860926F90D9E0587462179AA
-00E30547811C720A6C0484004F9B0C4179B801F238501FEC5601790840A41AE3
-4B1095267927DB34A6116A0477076CE829007B30E027AB1F79266623ED12D11B
-5D019E12E71FB55092197E01F00D5A01940C3F5A134AC321D638156CEA0C49B9
-12500DC43A5D1A49CA077B0E8527E13C125608D3026828FD189E125A3B0E8600
-5004FC00A80AC3009E1F7C27FA14C507DF003B6C04B10D7A402BD1154D920050
-1FDF3100FC092F6D2660CF0DB326F515B5412FD41F60F2093D255A04B16C0430
-9F265FBC0483002AB21A5E0D9E176120862BF027B3340456A5126B1A600EC601
-A109883861039E0DF536510090053A02BD34531F47B64A2769BE04E700418512
-5ABD0453337C0466DB35571486339612502FBA2646500478F73748971290045D
-00438504A72DDA27792F81154F396C125001AB0B53347E23921FF5432F6101C2
-0F5E34DC1A3CBC6C1054A51349CA0CAF013F59008747335A01950A8601532976
-A60F86163EC4610CDC003D5022C265053ACD50017E05E6005A0C80005B9B1741
-F900A00889325412DA4100B05022834908C068235EFE71470BA577006C08F700
-346E26843105A4002F8622A61DF72E009E09EA00C20563E5005A05991DB52C00
-7E0C27E24A39BA31CF22F4266C07960FB9245AEF01AF35F261226CA20041B704
-500F9D1ADC3A1B78009802A57804298E016034941F7A228514E1365512A321DA
-1A6A26B313C90045E527D400501A7827A31BF96B0D3FEC6E0240F634A32742C3
-3D13DF1B47C005268337E54604F2395A207E1733C8002B961434D20C4B1227E3
-0430DF22921456A11A9B0EEE6427F2450ACC005012AB46216E277826881F3D78
-19D43E810A48A825C45A0024810F6D0864018C14C22150019D05317F0E79052E
-D1043DE6125A2FD16A008205A749E7266B30551241E826C220E0005A04F72C99
-02A008D70079063DE540046C20983401700D7A24FD04920A7B0130A5005219B5
-22781254088704AA502785003278D140046023791E9301C107FD69126CD90440
-7A1A8301A4791B41860F5D2BB93F08DA015F3E1A7A11955B1F6B973E0560D604
-B60D5001D00FA133600022EB601187043578AF05E827AA1EB6334C0064E94119
-CB6826DA1F438A12941A4A870983013CBD46296C123EAE09F705CC62007F076C
-0E41B93C1278266C1F73266727A65B009237F7490568B91F9E2F8E125A34D122
-5AD91E7A27910E6700BD1BD6472F6C019E0DF369135321B312CA00B2106B2C58
-3F00B4441F62F100B130C63F0064AE0449C60173207D274ECE07B400C53D01F9
-2C08CF771930821F5BF6412A6C01FC13BC913F01D71C59F20B2D661F83003F77
-0DE078290D9337510C96014EBF005226C40032F71FA4125E0AFE0094045B1F4B
-85223B9D1450A133850567AD00C50DEB2DAF12EF250FC54D1A6012D018503F08
-C70140AE0049B30D389C12CB043DDD2F5A386900FE1FCE22513E02A50A750181
-2F6C2750D60DA424852F048B0E50276C125526DD1731FA2179410DEC00AE1B78
-2A56346A25860DAE5A2700F15300A73A049E09C146276B06571F772F84003E6E
-D401BE1150F8055D4002BC5A04E200B21B3E86163BF0660CA562047927E1269B
-1F5022CE279F3601C11A49F42700EB12D2451A51345E017A05810047873B0CAD
-008628A300F95D266ADF1A8528058648046B334A9701850D9A138D0F440964B4
-20D7274BF74826E0069C00428C01EB125FE126AA019D09EA038E055A98005112
-D4335094124600AF04E60CA01C793B019C6C0F38C61A7A276C49227904A63400
-DE08AE26C90E4726903146971A39AC228715357927722667FD06489D04307920
-3FC90E5A0081053EB36F0C8200E1660D79013EAB512379280476F31CB45019C7
-5031CE52017B2FDA227810803304890D533A0EF55F15E927AF00F426601AF001
-C52457BA78330086089400601A8F125321F81934791F9B063A781AD8355A396C
-1FAB370E6CB23B01A305275FFB841F6C165103D24715DE4023A3620A8A01E20D
-B100ED5311D06A279412501A79A104690ADA01508600D40949F61AAE12CD0056
-2DD7125AB401DF125534AF4119C76A012FEB1B48102EB127D6125E0892015AA5
-2F008B062897340C950427FC239D085001E72650D31AAD00A06C012F9E005010
-6E4106B94F276C2C7D054901E048165E30B70EC5003EBC6E0863B9045031BE4E
-00934810B200CB500C72CF260687621F6BC4024B093FD72EB3366000945008C7
-0132E7223E682741653A23861BA4510140F960003CEB15A64127CA123B652FA5
-00850350339B1A830195370D842C78019206EE533513DB580469AD794F048A09
-9E1FC826DC370BC441126AE30144F71F408413751A64C1401CAB12663542ED1F
-3EBC6E1B66C031D31D873703A1089816E8279E1EA339EF1249792799670427A2
-380C5CD300680EF633048422791331F2002B5BE51343F30A3F7927B65A00740E
-8926F3122F841A479D125AB500C90C9502B307430425C46C052ABC1F54355C00
-7A0554E9048C116C2461DD0647BD0D6B26C860249F1FE8276C2C00AC770840B6
-263A00FD3F1B6C327D00660D4B7F1F60D63D1F9061006CBD06AE00DE3D049F5C
-007E0994024B88075204DE41089500540BE26A1FD93A6000790D690676018535
-03E20C3BEA4400CA772911961F822252BB28F90649861A45B5013DA6002F8722
-D8013A13A822EA01780659B100FE5F047F0747851D771FDA5030F45A862D15A8
-6E098C01B50FFE2A921F6C3E1FF029C60A3986142752E4004F08F900500E851A
-A1600D31C31F6101CB6C1F60BD00F91250B62EEF00AF084903BA0A3AD112512E
-61365812820D31C627F026C02F12CF25863413792063B32F5000AE2704C75026
-FA2FC726A91FCE5020871A4E86245019EF4737DC02AC0878005E36B001C76212
-821E4C71C0046C0F60EE7B0450329E1AC240266D1F3EB927D9193CF905A03F00
-7F113701E3590040E4226C277322A512C600B44A01941D50AD00EA7704388827
-7C1F3BBC6000D9043EFB50018411903E12A2063485229628046C1686243B9E6C
-2781164B9D02F2099701A525F746057901620B7750009D115AB001F53E127E26
-92124C86410B950481005A0A6C007F3F05B90032D90189077B015A2F6C4112D0
-1D9212792F0A9F27D7043912961AA5430C2666BD0B55386C04D508AD0C770050
-93045A3060129D27C962930D34D01F4AA40CD7008708792F510EA13C0D79016A
-2F4E10B65A19D204AE6C143F97227826631BB327F2480AD32A4CDB025A08E143
-AF3D0569FD011EEA00A4243F72276B1FE5297516865034A71C9D21E43749FA00
-26874A09CA01FD0540EC002DAD205B12B534E627AE10FB5A26925A0F7528A126
-C71FAE16E92D643F00E02650E900691579FE5827E3310077CC3D1A7F00E21290
-1F7D346720F42F12CB22AD01EE1F790A1B3DB468079D04387E1A4F32DE4101E5
-6C1B61D526FC21C01F933301A20D504001DF0749C50AA80086087900279C5000
-7B1249B43D78002260D00F39874629650FE000CA0BB24E115300AF07D40F40D9
-017D05850A3075C53C1B842770225A9F1A64D4144EE3472577126322722F02CD
-0837A921F904540B710058059F0DC1774803994234BB500149097E015FBA1B52
-00F725A5295E00E94601D35205844900740E6C394C00ABFC015012812663F600
-5ABA046421994707C000349705590B6F00F46C2163F023A5278633128B29E422
-5A37D86C0535ED269E20700E27C17F0447971A53D605AA50215A1B8B41007BC8
-3D20792792006A472DC61FB46C0D5504E500A50FBC300D7D350185096C008704
-9E0BD801A76C1260E3006B1348B539F13BBC492681043818BC2705860D2BA426
-C6229F3710962788126A470CB8365A22981233BE1FB037E728B514D65A260C78
-2DED00C30B3286233E7814B0122D8C22417E1F4DAB38D349270AC93E007B0C53
-00F95A02750D4DC7125318C1620E8505C600E9501234F52700BC0C3A6D3E0179
-B73B042FD8270D69E8015D18FE22B212603E0328DA279E205C36500077D905AE
-4922BB27CC1FF531543985173CB6401E7C2F94006C0D5E097901D81A5AF06C0C
-5BFB1F5ADF078E005A0CF84D01DA0640D103821C790DC2024186006006690B50
-008406339640BA1A476C27499C06CE01EF3A0060F5015AE20DCD0079035B0779
-9E4A11901A3CBD6B183CD21F9D3000A0047E2700B21A5D412F6C06965A0D7B50
-2F7900B618FA2C0E66EE6C055AB5005034B945045A0C7800F479500082093FBE
-16E0681B3B5212F23E0392065D4300C00449F30057069C0EC127DE239827A51F
-6A309B00492593003A880138791E40D12E6C2685204FAD179B2FFA04A02B50EE
-1750DE26A524C85D1FA36A1657008D04B311DE1A6212821D50C43F0C7C320492
-264412ED1AB841002AAC26D66D0443B401674404F46C1E3DE740744732F401AC
-1FC83901A51ACE10EC4B2694064486004A1291361A982285087532A238DB5524
-11A54612F16501960633A901986000A45A1F3CB2158C227B351A9E27ED255001
-850C5001CB0450F71240C412AD1AD56616CD610EEE67058701C0083E9D003B5A
-01416A48138723A40D317001833C04F23F01E02FCE223A5A3E004EB546279F05
-771A9D26BA60176CB25F2784311271E60964012FEB0F2C921BAF345007BD5A25
-04CF0D92177F12660449DC2787013F621B82125BBF1FD627AE1FFB4804C713EF
-26CE0087062C944004C430522273277B480DF73F1F7F2F0FEF6E0D692AEA12B5
-640B770464CE3D1D60AD3F1F8C330094054F7901843404A62E00AD3212B22050
-1461F2126ADE1EB310C700E108610177BA1BFD4911924F257B126C0667E80DA9
-77268401E30E582EDC006C0F3EF809481CC40050D80436801F9D571F845009E4
-007712952F0079A31F5001BC3845F8329E146B2250AF05C400DE3D01960A5201
-79008430633F017B116A1F4FB501D258269200AC0CEC00B9276C04D108C36A00
-44D3019F074C002DDA1FB241136CFE0039E55115D35A25DD1F3EE92749801151
-931F5693003CE57930048534057F27791F3A733EC4394B04860A28C1340CD200
-B11F923300812F04FA0A542069CA0349A622D6004C9A018E0D3B861F5FB000FD
-4005A500C737499F23D91F60FB3E0869E22E5A088500600B7900EF096D275735
-691F7F2560C43B25A016DD0DAC591CBC27F30D673F12860641D81D792F85124D
-14A525593D26931A347F265AC4784001863300A4092F93126A03840838860E9D
-04630BC721F53A04E00840CC732600BA5A1FC65E12E80B4EA526007D1ADB2740
-AF6C0064A51F5A40FB09BD5422C75F123BB77900279536078127921A34DF2568
-F6059F1250276B0DCF3065218103327A0C83015012B63500791FD726AE23D128
-A7339B17E60CA404B408F140126CE60859286D0027980583007722E42750FD15
-673A01C2085AE27900409E01DE0BB45712DF1C480DA96A125AEC22864A04BB27
-A62668C1006136BD2C78006D0CB05A26861E5005429F2809960126890041D404
-62F61067059900541FE327053F9E04265D411886013FD66C1739F350126CFD15
-5204B95A117E013F582CE007BF1886247705F111BF5A00A92BCA278E205AA510
-96016D0E8704810E640150307727476C315500B2044F369B04B647EA335439A8
-1A8A0497003C7904A2501F9326471F63FE11821F79380086047701FB183BCB05
-457800D13E1A7D00EA12502FFD13531BA840239800317601FB12B46C0E51DA36
-46FD5033981B8613502CB74432F31278084979EA15863CA901DC0D9A1B500C9F
-046208C026003DCC682600AC2ECE12B7006C35425B01AE138D27713916E82677
-096B00D60640F02A533AEB344C1BFB27CD8504BF00F612CC1F83297920CC136B
-3C106001D50849C70B5035B50DC94921F53D03CF00B40D3C6934BE0549F627BC
-32A327790050970D30AD2063F40E5A349901790A8F01EC0E5ADA1A5DCB12A427
-793803EB226C0D940227C305562FAD017707850E5E39B231CC002B7600670E79
-276B30AE007926C51FA52F489E6E0D3AF07948046C45277912A803F42F48D900
-600BAD4B0D901C47EE4A2783165F04BB0C8000B35A0078083E6015446F3A019E
-0DDA0A8A003FF801C21F78268015315EDC126A285A018509AE6012772C8D04CF
-005B298C146C1F62129321E2263FC352067A0C5038B70644CF1FB2266C3A8601
-339405397E226500D1581AA500BC14497E0D68EC0048CD21E427C9047E016D12
-50AC0DC820F01AB500F32148E74C003D7A01E80541B501540933E40DAF05EB52
-20821A930D37A128DC01793C04B901610D9C04CC30921B76266C203DBD22AD1F
-E42D970EA75A2771306522A55A1F84279012A400FA7001269F00E919A927771A
-349B22EB1A50279D12E401AD098200D605550A8B015F1FDF27A301761B84225B
-3E0056D50527C4480DF04D00DA0F9B2F0886492D6039DA22AE1A347A0C379000
-491A9F23DB1B9B225B354B9A0150397C1284045F1276D51250228619308614A4
-671C8428633C00C8326300BB5C1B7C199B26F750307B1FBB253E6F0048E201C6
-06DC0D5F400B90006905D94006FC04B001E94205B30C5000E22F5A3E0EBB7949
-2F6C420BD5005ADF055D0171A70C446C30512241E948266CAD3E1AF210740284
-18C827E400AD04F574123FA4641582276120AB347A1F5FC13E01F51C85006D04
-54B317A15E1F6CB55A1186365104F801D8072760A5062FC0269D27A2310661B9
-6B0CDD6020D52B00BE4D019A11894713E0394F01FB0640690444A412DE3F0052
-FE12B42161344286199F03EA6B2750B9265B1A9213581F9234127E265BCF3866
-09C3239D402003CE059B374A9230124CB7460E32F000B104C67A01600C872E00
-C95027A72EBD3A5F058E0F502D7D0D319F014E08F800B9048D0B5A06F3015012
-7C0C6E109F27F03A00DD2701FB084001EF4500B76227792575D01040E3520046
-0DCD0240F81B4900974601A7084F941235FA26C3500480087712852757C210D4
-2D0077055AA31A6C3A088600981156386C314F01D411397E00C6274BC1480660
-BE00EF3204971E8549026907F16227801FEE0426C678007F26D7581A8427570D
-3BD21AB31FF739630482007A2600F9522469D81241BC5025E11F772F54386C1C
-E6279D31A226D327B130CE217E13629B0E47864E3395276B0D792F09C30DB000
-198803641475F768265AAD009627CE34137E243BF30442831A77012FF226B227
-D822A10034822166C71F96330CC5019E5026F01FB605F400C4139D217904F23E
-0D7B017726DB1A46751C83410EF50034D627A6360CB200500DA266163CFC4008
-7902C24112FA74214A97034E06800EA322E413519A410BC0013D9501650A8504
-57BF19AC0ED23F0077046A0D8300500892005906AC035034BF0426D612C217AF
-21E149398F345A3F26C41FB1084901870A347C0F710458F906BC6C1E60CF00AE
-0D41950B46009104500EE461029207514009F362224813D13F0A78286F266227
-780556B4501F62B222EC126900AA2B0A9E00C65124AE5C1276005787125FC134
-5100AD046113BD49276600943405B800336BC75E1DDC3169073ECE1132792785
-164BF027C91DAB3C008305672679AE1AC422E01F40FA6A1B47E44927CF227C1C
-69A70041653B02940685005504FE954D007A2A9021B81CDF451AE927B01F3E5D
-40008A0B3279225AD41F69C95A176CB238491EB827EE12B37927007BE25A026B
-AE12D101930EA21BFE273B0C9C00428605509E391279E2402E6B159239058621
-DA1D3CFA4017791FE62E8627900035A21BDB22507C1F73ED0C4601924A00B947
-720349B400E905AF35087E00406A0DE44A34EF0142085A2F850161A50432BB04
-630D8101920BED06552F860CF459266C12EC1DA51205DD3B0DED016A30790092
-56016B0882009C12E626B75414E93300A804491FED2F097D00970C50006D3C02
-50B63C042C9227005A397D1ADA00407901CA6C27DE1832CC1F3EF954055001B4
-07DC0150EC2FA10694016C08D6019609750DD12150F404850BAB01E149102A8C
-23AE2D12963B19EF27901A6B2F731F5AB9175FFB209E2B11941F52BB39FE0042
-B53C125787237A27A71FF9365B2C7812E601A53E00CD30A72976276B8625619F
-1551D40541C03B0DA72FC526D8276C05813E017706866025790F970158C126F8
-225ACF33A81DD62384146CBA08F7459F0625AD2F4DBD155F40028707A0520084
-036C24C91E7F2263277A0D6C00544026BB23902B6826BE1F5B019A126C2D5538
-672F5A04C05C00DA0840FC530A8600640DDB23AA09D600419727077B015BC600
-7F126C1A4B92126C07CE3700EB0CC600694308B100C6491F7950227F1F5E0489
-01CF1A00B904348222479710611FE2237912500DA21AC44A1FDC27A43912FE30
-CE277734046B12862F018D0B5C056C01EC1F503665193DE376480A8E043AA412
-F84A346712A926D60C9600A337FD10AB1BCA23B112E3780B5102AA0E82003CEE
-4632CA07B400EB0E9F26951A367A27619C0127CB2050BC3E0183146A26823404
-CB4937D8143EA529DE01A40B2CDD25921C6F9E1F3D5E2F9E187727406C04B842
-0FDD05B30EDA153A6C405A1F47E70DC1002FFB149B0489003EFD5A0179360092
-095D00C74E057F00A50CD9489F3F04DF682049FD37AE48107F00A20CBF005404
-34F0225AE0006D2F0ABA04E92A77135A4632600B49790386355A046A3E1A61E8
-4427F7334F991286005A3E1D92207000D80744F512A41A503978059E2F05984A
-33FE00A50DE7611291005087046109487926C860045000F22E0550AE06E00154
-CA04E21092340094276235732653B708F50F9E7901541F864F02722B5A36BD6B
-0330D22166F6174499276A1CB422501D86143900BE581838B9007A0E59269E2F
-D8247927851FCE6A017C0D31851FA7611D832395003CB31AE614BD003ED24300
-F531C400A4053986006C04D9076822B115E06A043AB03F166B86017605C600E8
-258413F45D10D40477395B2D501F7826B31B45F526BC360596003479BD40165C
-D0127927498612408C1A5226FD671AA400F80A9C00416539CC45136CA83E0BC7
-3DAD00ED0A501A884507930D552EBE11F10789013EE662036CF560270C7BA312
-6B29BC04DC018A0B5104E90F9E2712B138C45008E6013DD900460DF368047901
-6C27971F5B19970A7C226D27D31F4EC317A0492AC64004772640D0501262BB3B
-22AD265A318811B0006C3D218B1E5812CD01C008B101EF099831017B1A68EA13
-49F7270F6CB3013B6B00B60A32F7002968BC015009C62D79258327E51BAC032F
-00E03204F26927075E401F9E27E110B16127AD01760553385B2FD96C0A2DC823
-4A0778E82A0153EF1A416515791B5EC546306100498850006217A52A79124E76
-B55D2041CD25A230860FE504B9265113AB0E810195093F613C0D7C005AF90DAA
-017809FD01500BEE0040D90C663F1F55D004BE0040A32779234984276C2F6912
-C85A0DA80055347E0C5A9D04289F0DEE522196601D6DA906389A2786124705BB
-0159117C2771A2601B539924007BD912B367006E05783500EA1D3FD8338501AC
-104F1FB34200A11FBB340466CA31089C00C95026F63400A61ABB39FB052DD921
-79009222C82F0949019006378708EF01502E6C0C47DB6200F9365324F112B304
-E8269E1A338423621F862779278D1F538518B304E3770D337D2666EE02690FF6
-3700DB0DA4007F421FDB278622AE01C51B3FE3501E7F4105D83C01C14712D95A
-0DD1015AEB691F3DCA4000DB0A1237B30D2B5ABB3B26770433D427AE22C8490C
-9F5000A41AEC2295007D058F5C0F820044922612864F1F713C01AB0785400E84
-0176113F9D12AD27F40D5D0180F727C117E0501277225AC2009E368504278F4A
-1ABD68017827851A6301C34E00E32CCB0FB306D5003FA70D3B6B2F5001AA4808
-A3125029BB3F046CAE1A6027D1330695015010E51650258C00640DCA3519904B
-15802E019B34007927AD22490C9E6C0465A92283FA6B0077E904501A9213F759
-1A7F015312853169127A266C047935CB26F81932EE2753D50DA84A00B734E617
-8E286B13E05A26D127B462077D044C1A41B74A0E55046B355D00C827AE143D67
-12F41B40B82F0786042F9D1DCB0046D73B12A23E117F00563865144FCC044AF9
-019E1A8522FB2B4AD30B7E005A9B204686058A0B50FC2263BF3E046CA23B09D2
-2786015FFC002EBB07EB6C235EF01A89117A00D5310DF7193B5A055025C31F3D
-7F0EDF00A34101B70D3DF26500D004FB28C512B5470C60400D50AA018B12653F
-01FA3A790440640AD300A42F037A0B6C0044EA225ADD6E017A25D51FB3129A26
-83196C008F06DA4A01A46C0060D21243E10D405A327706935D086CB41D409404
-E92E9D1A3A91127927DD1253048600359C26E5300ADF0134EB213D9C00853908
-789E2701FA5A137224A4300C6C9D1056401ACA043E5003E534A319854D289600
-C131018A086201B2406E315A1F86255096052C9222501A8A093D5717DE01AF79
-046C3B1BE1059D276C0E49CE12B45023782050B835F11F86123393004727C114
-6600436F3E00FC05B134F744276E227E3112E5203BA56C0061B105FE18B9281F
-F02F055AF522A512780160E3265506AD003EB86014AF5A057211854B13A55200
-66BE184712CD264500CC680E40AF00E81A51C53E1F61A700860CA11FC0704906
-614001AF07426F0F9CCE163EDA27790A26BB04D10840E51448BF0F3DA86C0060
-E3007C2D681F3CE812BF502F7918D11FA102279200309E04EA0C6500419F06C5
-5019CF0C87053EEE32AA0DE0571E40600C5701C70AB304CD490B970251248633
-137A27840047810165C8270A77008635C80D4300C4631F6C92063AE83F24DA1F
-A900C93C761E922E0D77E45D046CED32511FB622793D1189067800E10431D526
-6B2B82013916B520F52650C51BEC52212C4C97126800FE50128427629B003886
-015CE2133ABA401F92269F10C4005E4206970041AD006136F16C1B5EFC125538
-981D8C265A386701AD306920A6530D7703862A0879D022A41F8516602C511A90
-334FFC12C51AE95401CF0E50DD12AE3F00954933BF45196C2AB26E0E26F40A2C
-C9206B008C0265412E602604F412D342014D1AB22C06830B99005B05C04F27AB
-2068278E4605780EF91341DD7F006C0E8632029127008504F40145B6391A8640
-00ED113CC5691FA244067F01590D7908F9048126771D942C4CF5125B3089074E
-01C437056CBF0048D705C601F51F82267801FE36009C27CC215ABE3D016C04E5
-4839A100ED6605C3013F94007A09369F223E9204395A1A790EDB045A08F60087
-0531984934A34F01780CA51A50B408FD01B97B315A067EB626920058A81FD748
-37F72B6903F3014ECE0A50F51FB25100AD73092850C83D00E162126CD640AD54
-277F0D5FC003AE5A2279095302FA0B299726F027CD31A3205A34E10BB201D509
-3B8104E00DB3157D2646A41A2C8617348122490FA004E60E9E135AD31A6C1183
-00500F93267B2F00D40D8737147E2778215F2F41B96B0059AC1D69B50DE826A1
-1F82279A234C1FEC4104D6007A1761D74727F2341382236C114100B12740046C
-0EF236127C2F04850F98188724820E34A026006A3B2394321B61A505265AA815
-41BD0758113A0CA01DEB013E6C3516CA28A51F8B3450D300640A75006C0350BC
-00488527771F6D24B7501E752358EA0E7700DB5006F95C126CB65E2774346029
-7E05409401E931A51BF22BD611AD5F26741F50BB00DF0CB407D404501FEE2F07
-F401406F0054366101D00C63C26E115FAC1A6827EB05501D7D105DCC0048B638
-D96F1B6AEC38C1491F70C70050E21F6200D136601AB05604773EBB07DF045AD0
-013EEE770D2C860434971F841AD7005D2F9E1FD50D78059100E14912851AAB33
-C61FAE23DB143E982204FC0E55C0004327A900CB3E0452BD276112923D01CE09
-4500DD08B300D923AF1F51386606426A047D006C3908B902F911772F468C1369
-279B12790C8661278D1FC930AE04F83E1B863401409E002750C10148A412BF00
-9F043E9418600C50079101500A60009F043E269E0840C5305212DB3F00E72AD2
-154E841A7B124695125300D4671FFD4A00E947935034B3054D810455F33E206C
-3105C2013B6C0D4B8305602C790D52CB4E349B042A7BF2057837641F912F0A85
-04AD50209C28861E98125825880D6900F20AAD26C912B43E239E1BEF4A279534
-5A01A3045A38F80149E027A53800C00B53058315782250B80649DF0D2FD07909
-2F8E0E387F276C2FDF1B4DE901A522F827C61FAB22D2275AFE6C125FA60D8604
-9307A050124801920031B127FE0034BC23793801B00B832761013E04790FE014
-40BD3A0065D810AF6F2260EC049E1941F912A500ED2F01861A40DD62163F5F11
-E407AE00D34932EF3F00E00C4B00F02F4CC2411651A13A5B2776004984005BCE
-065A0B88006506D1401BF024A91D8634007706DB49126DEC2741D609A8006B27
-9218A55A143EFA5622DA6001F705862679083285277B006712842F72107B0A4D
-01C233007927EC223A6C2079C26827E9430A70208450078911A155267118CB0D
-B91FFA26A22890016023861A477E00439C083F5126DC00356D27841F964411B5
-00500BA101C233532A6B3F1297015A1F7E2769B95A2279026B01F83207C804BB
-15E2301AFB1F5035AD2C45C71DAE239C5E088100510BB56022881BA63C230298
-0066472B7912FC01683D0188047500AA073289215A0DB200C5570ECF143FB850
-00E2059422AF1D7F2749F11B6A0158BA00FC053709A50D65CD01AF12E32749F2
-062FE001A445306B980A77006A26F50DB107C80129FD162FD61CB46B0E5AB101
-D70A5A05D166279226C92F791A9500B60DF85B1AB20F9E05C60D47048912D127
-922079481A6C345005A0610986047B00E012723A0D79013CBF4529CC6A123FC6
-03500D79D34A34BA11E204CB521F4FBB23EF28BA1B691346C3113FD13A196B3E
-1F7904975A042D9B1A5331E8003FDD057202AC26CB0D3F64129B764F22861F3F
-5A2F6604A600226398123D5B058800225231D812821B3F6C324B92510AA56201
-8B00309222487B163DC1263A01F00981016A0EFE2679278601388227E334652A
-7B26E632A405460AAE00E22B96019C6C0D38B326D81F9A225104FD5827E11F74
-0F9A0436E9005A2FFB69002793165B3E1F90380E86340095077D2649E3389200
-539D00A047FA0BB226EE3A1ED66C0964AD0248966B123AA2401382317A1DAD50
-2601F03B00C505F20E9D374677BF3F046CB41FE627D168BD0441AE024F9D00E7
-0D26BD3650127B2559F30BCA04329F61006CB07912511FE822A7005A05D72250
-C9066B038600FD0BA5006C1F60E95A2781135012F4223FD24C026C2F640D3FBC
-7F4100930B6600D915497F1F842495133EB45005F801AD6C0060BF05E75D126C
-1AA20C78044DEF1F6C295A022D8800406101850C46FA233ECB123B04BA610CD4
-5A089F00E2042FD14214B05527841A7900C80B27591AD333007E094912013D96
-185E2FDC13521F9F41007F04E427C605387D1E65E90D41F91D4A2261B941056C
-2D479E3B13801134931FA713462177368A14C2014B0DC4043CD26908AA005A24
-EA12A900EE77013414B32240A634552FF501AD09D9057A015A107C26750D30F3
-0C2D722240C62FDD00501FB5270BAD04E210B467176FCA12AF23BD32047F0050
-78F02B50248E002FF9276C225A8B017D4A0B980339B9244B1D7EF7009E0C4CF1
-275AB579ED1D4DF300860A3AB8720468EF1B94227112AC5001A345007D2F0486
-07DA0131783ABD0DDC1960B800F35601DB2C5CC55401D9065A2F8526791F9262
-00318A2777129501792783390F60DB6C0560E90786047C196C264F32A11FC427
-E32FA51AD75A1B449E01A60879035737C86801844934611C81223DDB05395A28
-79015F9E1AA60E35089A01E91A4A7C04910EBD3812A51FD82D40DE50126CDA60
-0350346C2C8712A401380E278406387826A7630127CD223E5A08B9003B5E20DF
-2D12BF24AE5012A9369C13E2004B86019108406C3D0D772681094912AD279922
-F110B200FC4218BE551DE604C1345019C70556B91F4A25C92E12791FD424B20D
-E4780162400A8600610A833500B86C13D5375A169E1E830D30FE12D201984100
-C60450A00DF80049E11439DB276CBE5B1F750D40C415B334500160F5086A0079
-0660008F094726AF15C305DC01421F78CD5AAF12C7580DD30447FB4308A501D4
-334979FA0189075892096D01D72A600047690C961C3A6A26E71FAB23C31AAF00
-F4237C04630D6E0178276E330C9F4701790D86491BF7650D8632009C078D0197
-4800AE3A6000563F11BB26ED501AB624CA0349972704854A00F7274BEC01AE5A
-267720730DF35A27841E406C1F8A340A96540081074800D327AD7A053C5A11E5
-781E4186269F1BF921AE27ED01950D7D22531E78BE600848002C790131932280
-2E12965C1981129E270C406A13C53E1EF4349518A026F71ABB5426FA04C45000
-5A048601793460179F2FE51FCA39A61AD203B0690530ED27B436007B042DB425
-E14812F9375017EF3152129E34D11F9749006C0679346C1440ED0F50E43D2093
-12AF003D6340059600C230A43D129B09E800C25205AE692A0DB41FF5229E1253
-002668DB00872A06CF002FC70D5033840E791B6538D80041A1680D4826FC248F
-DB1A49E8006108AF6C0031E0276C0061CF21A13467008549035B3F0087087039
-02860E993E1677CC2F46ED410CD850056C00854800614309563F23D75B11771A
-60DF219E45007F03792B5F1ABE6801850AFA016E0C770439CB27AE20FD00B25C
-267E00650BBF046A32870BCA10E01A4069075301D62D7722953A12D82600EF76
-2F5C01842762FD3ACA401F6C26A24935A953046ABC0141D10447C2185A32F912
-3BE2009E046C11003C9B1FA534F61A42C54D0BA41FF339048300EB24AB1228B8
-0DE46C1F3EAF12D650326306A341127F0D5E1D950138CD27B3370BF626B536E3
-129D0140BC009807523D0AD55B1FA515CD0086043DA11F6C269220B827F55D0D
-6A02841292390C9F1AC422862C7726E1197B226D2757B712E7279424AC014063
-04913149A0153E04CB5011C4014C097903B30BF301770C6320EE361294246034
-8601780B9301AA054E81173AC450AE70056A0D7600852704873F017A0D53B51C
-500E5A04D9791B6B3B05CA5A01894400BC1DDD2700F627AD00B929488612791B
-50A219840D6C00781A7C0E6A3B26C912B16C2240EB0850396C27E50E45CF04B4
-375905830031AA23D72F630453CF0169385801FB08A4005E32A2008A043B6000
-7F0A6B1058BA14F450017B0859BC7919378826762DA215512F7E189322E0137B
-00487707E600B31FF327BD24742B851B3EBA6104291245E221C1279F1361ED0E
-64CC25AD2D076CC92F9A3950004ECD12A14822ED2F1479278301518D4D056F38
-6910F9006608EA015F3F04DA1FAC2DF327AE1EFB4F01842F009E0530679A10AE
-094F901B5A2F7800E13D12C354087C00A126E01F4B32F205A53E127E1F55D405
-46F612CD1D9E4334C41FFC30086F3D1DB726E31F4A0168F100AF0DDF2364E900
-44C43185043EB529CC1BA6395A1174078000520FCC25E801530EF26BBF003E86
-015A09D04022991935770066E33E017406F616A72E017E3204791A61B508F110
-3CD10931C019D7049E4B26C04F279D11C6552780074A0190084904873E17F54A
-12BF772600F420853305B200EC10491669A4401DE6345A0F6E097A0086117919
-CB4D2FBA0E40AE144F78266C0DF1044C7900A245C800780D6000A710D4260B79
-1A82008F0438A5125F0049AE5A096C01824A16952F45BA2740E0620079139827
-891F3F50961B5A33DE385303B80055E812BD1F5026A6247A27720B62FC1F5FDC
-0FA900376E2355A512489E016B275A3F159234018421753300A4235AC26C2658
-CD6C21D85C047D355301D348376200DC412379265ABC7F01500B86019D17F837
-AD27C726B5215F00960450860129960141B0008227A912388627045A27D93598
-412A8533984329CF384F1FBC56088326F912391AEA269B3405FE01D30C630493
-3515B430500ACC0179092706F40DA1009211772E7B0C405D049200850AD600B3
-21C43808B00040862650E2049800612D7C2053E70CB200DF0555D20EB805FE67
-0EEA003A0DE100380B9D002EA21FE6129B1AA704C4551E6CD4089A01371ACC27
-F02F612277045F01820D5A0344EF2740DE133AF15223E51A36D91671015CD218
-67E4129F026B0CFA05630150BA04650AF95C0F30DC1B95056AC679005D11D767
-2279278B1FEA4D059C4204F76726A431E5>
- >>
-
- /Magenta <<
- /HalftoneType 3
- /Width 167
- /Height 167
- /Thresholds <
-2750BF12AE00DB2CAF27ED016822981F3E931A3AAD042CCE0150FA12A22FCC0F
-5A008605953F19D0279A20673C26FB1F6C2F57400CFC1B62375A04A46A005791
-22811D50E10078174999207926CB340180045ED9173E6000B11AC52261E112AD
-502295278620508E02664501602282276E27D0116202E0690FED5D1FD712BC6C
-144925B51F661391228519A302E6340D6CA53C01790430D82254048F4500C407
-E3309C0477228406960045703C1A7912841D3DBD520AFA0450D70C54F44C168A
-256B376000459E1FB925DD4D2688106001F00EA95D099206CE00BA78013D9301
-86255127DE1F3FEB0AB5043C6A0CF2013BDE0A880355B529FC1244A007E62747
-6C01863006810135C6035A0CC60547E90DB834ED500CC8018B0A50BB364E0082
-28049C31603E007BFD6B0D54A64304BE065436611149B228055FB41EE54C0778
-A23A12EB3355396000564015C749F41B3EE2059B4901C7064D96043177267934
-00A02701973E08C300B31BE013794704613B00C40340A5501A790141BD336722
-8D1A2D50B40DE32DC4019408770160482C7812BE30508A1F62442FF012751A4E
-94002F7E228F04F83D13D5521BE969123BF041267A1A2F7F1F72042BA11F5721
-E82F05861AD12250B74100F326AD1C3802D53000F32D6039FB00BB27800077EA
-1F52390B9D274201C06304770CA511B81BD76201380D5A86216A1FE8315838F3
-1841D800A20FB35D1D7F4512DA621F770D53326C01E7349F0D7A1F64E30639B5
-27DC185400E83A0447ED12683459156C4012AE2FD711A800F7561F942707C300
-B3056A3F00D0073CC15302A60D5C269F700038A4270AB2730063B601DC5E009F
-10CB78003BAB40016AA626790797016C248F0B850450B8551480400C99017D25
-6C0A40D8223D099900CC6E1A6AF126501F9F27DC226C27860B32B36CA13301C1
-0DA500930D78005EAE126A28E0052FEB0DB66827013DE92B9904A8540D8215ED
-2AB114522F7C006B0D8622810D5AB36C008107D000A805F95026841C87257E37
-087B00DA48326C12861BA85B2685216713F21A3FC701430FBC6704895A1F3F9D
-1639893E13C3325A401565F4126FC33C00FE125336E812C61B5A34D60E72009E
-22C14F1BDE12A519995B046ABF4A12614006B700337A00D0087B008F05F90149
-83052700DE5A2776346122D326862F02822690144D9E015F390079B27F045A24
-F23E1FC122510190087500C012F3309A01C72FA93E1127C3269D1F406E2A601A
-C9005904C40C48D322A5129C1AF65024D501339D0FE00178284D83126AE52950
-1FFB3300DF064DD4096B04954C01F505AF4708990449178D2761BF0D46620447
-DE15662C40EB1A77128434477800D43B1EF12A01A732F9268E205AA61493345B
-12BA2F46783DC212EC5F9238099F00F6088004A70ADC4F1BF50140811F3EC01A
-FE0A400E50BB00690B860047D46A2149F746268421AE1B3F5F047700DE490B63
-044AE409BC00790E3EF2355A2797025038610458003CA40C4AEE056C2D47AB04
-D300AF3C0885007F0C579F2686122CA51EFC3B0D7927861A2F812239E05B0CA4
-01307D009932790D8500A207793C04E500B20526904D04AE0C49831F6C0C8001
-EA3F05DB490CF4395819CE260E6C2F4F1E1153D013851AAF2E47633A139D3F0D
-60BD04D56C038650266EDF1A3B7B27C74F2F970530B801680D9D04480050D612
-FA264E1A9C32F638A4228C1F3CA1476E0B7800E21268B401EB2BBF7912642E7C
-1540BA007B0E406C2F5A1F9A22D12DB83E116E01F35B00416420B224D10150DC
-00BE6C012CCC1F41DE1FB526F900AB25C41F5027C95126742763EE3E128C5432
-9E12D200B2193B6A12862F01792485037E0050AD04D700B27703406127426C12
-FB01B852006CB1233A550D35AE4012BB31009226D9073D02FB1041791C8726CD
-275FE7790C6C3B0A84B5620686007E0C6C0154EB0426D42DAF244A90280D861D
-751641E408B300C7601F53E726B519FD0DC301416C066101DA2FAA402379CE07
-91006E123E9E0E5D3D1B9E78004F860551108718405C3B0478F1016009B00DC7
-0A5701C62700DF05792474275ACE00BC2651C71AAC12E334A20C683F1F7E242E
-B822ED04C500964327721FE732078600F378165A0084045AA31377125EAD7214
-61C000DF0A5A02A2124C269F17B754014612CE235A1AD727B535156990016605
-813904FD4934CB059E01357920863D01900D3B70065A017E2656EB129F22934B
-14771ABD043C5A2FE527B8691F49B405EF0A4426F1126ACE3A0366B305E46C12
-418A1A9436671E88219B3448861F5036F0049B0D418F4B089527600042641B49
-EE16BD5A08FB7B00990E874D315C08CD049F0D4BC81A653E05CA22ED27D11F41
-F704B340002B9B1F3B924534AD40317600C504397920E32782013EBA4F00730F
-5CA60A31BE1FE80FBA5D187A00644627BC5404DA4A18FB26AE01D037AD4927A2
-0B3E5F00F53F08C000690E861AA51179065000EB0479276033B369049426016C
-ED203C540F26BB002FDC4901F95000D75004FE096BB9015A3E20E304371AFB47
-04E036B5049C002E8F013485260C5519643F0BE019A522684126920147D82091
-287911620886015933671FED5A04E20D561A7C00F806D53D1F62F300690E9F1D
-EF7804328722FE0041DA461183276D31009E27AD0CEA106C1F8F3106802C7512
-62411B6810E0008618B134541D7F2653ED3149DB004F34C91998355912D20084
-163EC02F4AA541099E00C87B4834A26105279E13318440108526A5122F940DC2
-6C1466B77801388215770D6C27C8610F54DE01AE40E835CC01A42781013EEF00
-BD51297E106C00A5093C9B4025B71AD4009E0A368923A701E90F961B61127AA5
-085027CA5805503A1464DE08A52A7A2701975000AA08CF4312E11A51329900F9
-0D50CF129F0450BF00EE057A1F6C2FCF048C0CA701D435049208276BF9025C38
-6C13AD3046A00EFB075F00E30B298026762E01FC06530EAC6B0270B4042AAD1A
-610047DB1B7E26439E00491165AE0AC01FF62587063DB840226C1F5D1277257A
-1F6C12D45A1B7F360AFD00AF31E11F53C500E5500D7F276E2750BD00792F6B27
-712749B950012FC01295032E77C400B0214179129205CA501AF83F1E6422855A
-016CA204446328409B007827DD361A85259733C40493267820E13266129B411E
-C6780B2E860DA500F7087B015A3F25A12179136EB91AD911A85624811FD53D19
-EF3E0D64E2014DE83A79055100F3032FD227E91F502B603E007A13E521760086
-06D204BD00AD0DF3009E3308940450A516436F05498B02693814963D01AE05E1
-1A6B3E12C508B004CE006B22E848266C3649DC1A3F601299012FC61F54128639
-0577B601F4043BC53F22D619B001C426551FAB00774809B74501613D0EF3005A
-4705864800B855013FB4601FDA23501F9527E61ABC6C034CC53948055900693F
-0CCE009E4B00864D25C52045930D7712C527B2601FAC5A0D75067C00DA059C4E
-33AE01640DF327A532921F662D5339612749B922E412622F9C22C21234FA1F86
-4805F2532278108803FD5026821F5834970C86059E00FD07A6009D0CF52D47E5
-51006CE93B00AC5D0D338C26A70E600690007B24854905F05F0C9213F7305B17
-E812B0521F3BAE12BB22FD2D6724EA12500099053DC16B04620D820032DE0F5A
-00F62FAD35EC1F9227773712B42F079800860628B91F5A006C0B338508399D23
-CA2FA0226C12ED045A389E50197911460050E307B504CF0C790071277B01D608
-600185500BA201BF2C6512C835B145305A0DD8003EF91346DD19416E3D158122
-6C267C018C076C0EB43E0465D42240E04C146C2D861FEF2F5312F60B35951239
-CA237F057400974E287908C86C277F005F07950D7B048C21D1264C830133DF2A
-B42241951F8627991F7A0184086301B308F86C0465E1125A34F56A013AA135EF
-41D01268FD045001840E49B44426811FD10030C90457FE85263E6C1C832140FA
-3B12C6258B1C3FEC3B1AD329445C0F92008549006107D201A2279C5D067E0160
-30B50DCC5227D60FBA325A22C01BA14A1F8C2F0987027800C207DA006F4209BA
-6C2750BF00487A015A27A522CD410CD600674001E31B3ED83A1FCE27A12F770D
-3FE81BA5430B860150CF086A01B60A6012D01647C24A266B321AC1225039CC1B
-511379DF49087201268D005227BB5B19F9045A00C308A20E4185229536130AA6
-01C95000A16A015EAC055900B451046CAB009706E23D22D0310CEA279321791A
-6C1240BC24A72086013A680492003E6004E24100613C01F011A54915BC296421
-962750C7139436019F07752BDD1AB20FE6018A3704832350A41A870A50850379
-4A01610BF201AE6100740E5AC31E3B7C1A49F038503AE34D288B225A0FE0009C
-430A94007C057800BD400D27CC219F502FC51A7C0F37912779208F35682B4FE1
-086901B25CD624742F0EEB341389205038F3306B269E0D3364267F13A8500469
-9F1DAD0D6636C405E6006C3B08D51454F026B91A4CF817920D7E34D50D94296C
-00F6355A0DE9500F79043E6300D65B26E21A620485276A336D1F59FC17B8320D
-F6263AC519AC12ED35B151156D3616BA27F127006EFD04A4005C0CC8047100B2
-06F40386277B12D55926F71FAA279534026D9D00600CDE0440A500E26B00A409
-D64611F8017816A427EF1A3A007A069A5A2467C507DF017D0B920EDC194BC60A
-F0013A6C1AFB12503F0155F6004A81268A1EF34F2BA40979005A349A096C26CD
-1F9726791DC624851A7904934101B92FFC1EB131511284003CA2400DCE00A408
-C00E3F7801945C009966007926440586002D9D22CC4604780948B140106C28D9
-238627A71D41237C30701AAE04613C018031630EDA095CEC175038B0294A9213
-6A32541ECA123C6401AB1F4BBA46006D0B538DB327F63904AB003E582DA31ECA
-225A0041831F752759BA008A287A00D8762E17921F3EB70B60049400673348AC
-11DF0148B244004D05FC01500A6103AE27E237199D2481006A0C9205EE33B65A
-15FE4C207C29692786004ADC1F3EC01240F1115AC26C2450C70681005A991FA3
-6B042F9F2085129E01501179D85A0E9F00D33345E71FBA12A001852C8B2245A5
-04FC0E79003DF108BA049A304EEC1A762886055B22D82697341021721650D912
-851E921245650448B135F905AE00CD0D406009C526A43305BE4409DC015432CF
-4212BE1CE4042E7E258E1C5F1279AB59216AAD39DD5012720051CB055A15A827
-DE1F406C024F0979008A3D0AEC03D21AB42F0B7F055086042E8F01490AE41268
-3E1AFA0D31E1003CD66006CD003F6331F969054900EF1B3C6C0EA50079054925
-C7195000AF063385269827C71F5D421A734501840653D00040E90D9F057E02E3
-5AC40BA700792849F409BF00E9327B016D1260236C31791FE33D126C1A855311
-995D277714790083354D840D6CCE01680DC427ED03380BC02F00860633CD26B2
-0C6831EF4F0A85034AC713A421D427AD1CC35A125236790560AD26EA1C46D361
-26DD1EA3349901D953268441128623521279275AE807AE0026AA1F822760B805
-51218E275AEF6A0D3DFA6713D25A006F0A64057A019F2DF612D422AE2F0D961A
-60306C4714AE3F0138622E4E1BB803346D247D0D9F16D727A52CDB03A3089200
-57B504EC0138F12700A406E922AE1AFA0128AF45123FF63B00841A5BD36F1F4E
-EA14479B00671B96267F0139C3223F7900672D780F660682012774AF0049F612
-3C6B009F0939009D076B41005C2A790CB201CD5007B701EF1FB00D3A6C138A4E
-34C4089D01417AFC3E0CD8124700B3770426833F12E61BBE34E327B50D6C015E
-3779007D4935B501BF12F62F661A8708FC01CD6B0D5B9501AE2F41613D0A8400
-79145020F9267C17477922AC5B076AC73986335A0D77269A630527B758058650
-31B807490093107727BD1A56FD3E01DA0EAF6C005CE612AE26F600B437E73049
-D8401F85152E9D01CB58226CB3751351B522FE15B404396C4719932E6C344980
-01921AC64026E20C723E1AD1123601AC5D01952A7F1E5337C35003982F600186
-12822250CA279D144AC312FB0477275A3D049D00D84AB01F7E123BE43F18D750
-04F900C15A1FED0D3EBC5A049F2DDE0C3595102F891C4E126000D44101C3113C
-EB79002C9F1FD812417927F433B604520D832D06864E1F7935129E3005861C84
-123F5A046B11A02501F109B9571F7E4110FB280D3FE83B027A086E2250EA11A5
-3B00F80CA1043EC92F57009F04794300EA51256BC07615347924CC04DE08A600
-2CE01F8126A3205000EC083D6A00E7072B9421500EDE00A9621F820D27005F32
-A1056C00A02A12861D6C2605962F529800348110680160CB004FD901B405FE25
-A81F952F50890052126CE0125F0471009E0A6C015A38E46B01D74816BF4305F2
-501FD24A38C90449D922A81F7900508E4C346C00E10827930049BD01641AC527
-AC30CE01624004D778205312DF1C5B0BF5472C6412B53160048E00490B55E91A
-AD126026861F469C0B6800F6073FD05A257F1CA8411EB065033EC76A1B7B2D0A
-C83A529540DC0448CA1F872660A9074AB03AD14401CB2248E126C41FAF40267D
-1F6C3E227F307904690BF20447C820A8350750B036E62A4AC921A21988002695
-129D3B008A2E61017C0977015D35960D84013DFA31BD0627D712A1344EC55333
-861F9D2786115A00820E791A912A550969BC274D96007919AB04D3501B810DC9
-28F426A32F07870040933B0DF26C124CB9491DAB7603359700D80486325512D9
-6D013BB507E7502701EF23860F79225A3E08F70036DA2279016611864E04850B
-77003C790DF805B30AE65000CE0F49C94626801332820342BF27008009AC113E
-630DD2274FC8375A04F05212D122AB279B26EC1AB1005027C85508760F429A04
-3F5D01862103DE0C5E06F30147D7501FA02FF500C022A03300860538C5258D0E
-753701FE279B1849068602D0632757F904C45A0140CC005C0486310C62B30F79
-2D600DF200864526911F57336B12B4784A0526A91AED01AF701A479C016112F0
-27B51A34FC27B21D5EE80450198F422D621DA527971F5A00B208E0631AF45B18
-6BFD1F64269000F050047C08600DB430662694046C0BFA00460E812762E50578
-19B422EA61156AB11AF70D4097492CCB396A31970535E2035A2585156001EE40
-1AE46C136129DB1FA75A0C770063B85A1F783900BC0B3D6A3924B11A357D22EA
-1145DB2719FD4912AC5022A23501A60AF2009A0487430030C15000612F891239
-BB691331B951099200409B0E77019442126CAA325C00C803860C7701ED179127
-773900932F01860D409D01D61A7B2340AE1FF9248401790CC41A3DA253146AB9
-5801CE123FA02F4E008B3801CD2F007B2462B626058000931CBA124085179B0A
-BD0D48DA4E1295603001A5087C006B063FB41FDC400A2FE10E9948218F1DA200
-79056CD9069F2756AE00945A0138CC00347D0550E3155A357021DB2811FD6A0A
-E237B51444D602540CE278411F812650DD04551FD52C06BF3B01EE0FA1236C14
-D934582F6C04D8124FBB0D48AE24CF05572F6D3C0CA5016C3B009F2CDF20A500
-4AE60034C521491F862C77095A04DE6C0D56A32250E412A9300050F119AF0F50
-0060FA00682773347A006C05C22606D0431FF634B027EB224C850527A56E0066
-1AF15A01DB0F49E84F102F851679013A693F0DA06C1F61DF0EC01C682A8512AC
-400D549F3E177B046E08790050862696003A05E801C90B622AC06D094C97501B
-8B27821F4AF5394804C109B2502285015C37D9137730A51FEB04BD5327DF14BC
-501F78123F62328712417E077902F308B11AFE23921228C63304821A6C3E0679
-CF1276376027E17B2F0BAD26D201F127B41FA4324986129A58016F0D83019410
-3BBC6B0143C5279E0435822872267E1FA54100F327C01FE51BC4330988054379
-279200BC05EA015BC3006606AA2C9823F127BC320EFA1C4BBD6C226A2FA1167B
-00243BF5002FE1125300BB0760009F6B267D380EA127FB1BA1008D056500840F
-436B0086073F600EE80155C904F7095AB723DF27942968337F00AD3848830065
-F50EB604C7661F405A01D60A780425A54B1B8B12501A8B0F3E5A0CFC006C3A22
-9E27D71F532FE5005014FB32117B1241CD08AF01C8075D03C0630D50058D0A6D
-0149EF26B82F01FC183A564026881F3C7922D41A46005510831D6399043A860D
-2DA70E79013FF243B7811241790565D544347827BE3F12F80049E40057067C28
-6027F121C7502CB418F933499700852792340E791F832F049200500CA900D70E
-406001EB0AB31E4F395B2E4E01E909BA345222C15A400ECD3E016CB740046AE8
-02812750BA03ED0C470066C10444A4277F0878AD00E3611F6C228C1241FE2D50
-1C79AE3E2258A42782004E129D5A0C6CD512AF62089E04F2500172C761A53C01
-DD063EC46A01DC4700FE1AC25F052750045BAD189D3F0D9204E80C5804862297
-1E6134C24019DC0B711181370992013C5A12C522D91A6C06AF5A27A401D1501F
-3BC05F1D722654C9129D206127940BD8009F12882679148D047F3900EC700564
-E73A0060C9233B9F1CCB0E61401F65BC7912358B186105C7551F3E522702A80D
-EC50367900910BE031006BFA0030D9135FD070033CB44004770034CF276B1536
-AF270C2D12D15127A316502691199E5A2695331178A91EE03000D12701A82666
-2A7B18DF2F5A0CB8028210699B01AD39BF0349E41B67D2028B0A7804A12CEE41
-00E1123C6A0FF56C133EEA05A201327C277811D5016C277F25FB3269009C25F5
-1AB22648139622501F94300692005F44017915AD7F045007F35A0AD02B763E00
-D60DB5804B2F6D0027BF16A42377045ACB2712B2500495264822E71D6024841F
-F85A127F00A46C0E41F77C48098D00417700E708603B05790053E43700750D89
-611F6CFA4A12CA01A3386801CF50279221D40426794B165A329F00AF441F7529
-A8263E6000531981265EBD009D43048F0049881FE15A07F100AE36851BAC0D46
-01A41FDB2B770186076AA13B00C408AD0DF74512D418B12FE43D0027DD22A029
-1AAB4A00F41F9A26600123FA11BB3E88046228D813B03D0D7D4107863E0CC401
-8608A000DC09A63D01B922E43004D76400209E314DF612CC5A1F40B813D727B6
-2A0764CB23B30736A10E3A0086315312B9208D3300EE07662D44F73C0DE8007A
-237734049D0DE40063FB0DAC35C7059B0A46821A2FB125C8340F7A391493223F
-690448E8005CCD760C5104A90E5F2FDB3F01FD5A2779286C1FA5502B860A6C04
-5AC4480D6D004893013785126B0449E63B6E054467194AE30C8400406C1B9F01
-D84D1EF5531AAD34426C2C48934F1B8629780D509B3D1FBA5301C005277F2F04
-AB6C008022860D6BAE1F3E58154EF1024979B74F08EF6B00490BA86D1251C700
-A450049026A90CD91250F4304D22861B503177136A3E1FFE2905DC610D4E1266
-D90450BA004B9F1AC412348E234A1338C06B234FC1125A1F84310CB700D90285
-09790048F924A72C097B35B53AE21163CA22AF2FBF15780FC631AD00D406339C
-2653BB01EE2E6519AD3700922D6915FA10BF01370DCD054901AD1A5D129206E7
-6B196FAD0D4686233DF3115001F83F009104EA7D016C27CE04341F9C1A297AFD
-5C1D3CB3401F771230B91C772B831F95076C00C75A08B301C308DB01B350006C
-A73A017AF177002D9622652FD7055A2D775006A502E47B3E07F1003D7900CA0A
-9C4A1461385422E426C53704771A9239F7016B08508632067701820A5F299D01
-8522792794500FFA1A68345612993C04804611DF057800502079E96C2763F558
-25C900ED49350C27D738005EED01C30D5634C9385B12D32F520E26C41B921240
-E6710041BC0E3705D60279099605DE7B014709CA01602FBD1EA012377927841F
-40582F6F229412491BC2400627B44201FC08760E40F800B10DF61A622743129E
-27991EE74026791BDF368C04B0410165127AAE0EDC0068169D24D52700FD461F
-DD274FEC04563F17F40D5D01C63C008605A509C7005AE70DBA631F51C728AA61
-054900B2094612852F8D290285B25A0469B91D41791A77019306821A97490ABD
-7746375E00B464173CC9650459AE6C235027F3335A3F1F61EE6B2750FB005A3D
-0453D800F21161B604EB0CCE043EE7780F2B9F470C6CA31F54AA2686126B217E
-2750B500D35B016A0C6E0456AA056900A410F4199234A0500152345B27C85104
-4A129E40125DA40D950035A71FD664044BB3471F7B502ADB1F71277F1F406C3B
-00903401820B3DCF13861F9023D401680D58C426003F9E1029950C34AF26DB1F
-6B27B20132852700A405FC30500A8E015015DC26480184B600620CA300BB0D4A
-008E123E7925E77E186C2748900126691B82275BAE26005ED10062ED18328300
-3DC60152C73E00A00437841535BB27DA2F881F3FEF2286276B276D0DD9062BEC
-21BC01800A2279C05C0475B600307A1AC5690C84003395267712ED04B8124099
-01F80CAB029B17EE23A6471AF5256C2F50E1006B34A322FC3A0876DF154BF948
-01D86000812CA703E30F5AEF0461DB1A6C129E23D328AB2679019E10EC143C7B
-22C51A52259C27D620B608A3044027C1059C0A3ECB3AAD48009F1F096B983415
-86270559C111E3144C96270760DC126CED0949851B7A00A208C5015C3C03D207
-BE0085275E891076133DAF45EA3D0027EF2F1B69E7065A401FF02646B70EE000
-3A6A27498B0060462D6537D02750058509D75A009403BE07359D0F7B066F0060
-A6210592260086385017F4095C1386349E1F3FAD12502CBF550478006B07F61B
-8A2F7F1F6C04E248016CFE3E0483065A35691FCF7400623550D3126C007910E1
-364BF73002DC4D09BD7C3803782784043AE979192F8A205431B100FD10551767
-26860EAD761F50355A1BA70040B500F1790626621AAF6C0856C3034C37AD007F
-055A8A01791A50A405D40B31F122BD0F9E075700B46627762041B812551F9544
-1AC427E127B212317F5534C06612CD059F2349C5460065057E00509206860038
-EA20A41385345E0BD80050BA2C5A139E3A126FCC1640A500E2500D47B20EED00
-2AA21FFD4F2E6601850555A51A92264401D7501FB323CD0D4700B84D01CD0593
-0E742548BE39F5491ACF420C65B201FD3E0CE11A6332501E6BCE028E0C349912
-38921F7B23D828A2123CCB2741C31382216B9F088101791FE426872F0DCA009D
-042F77DC4000EE5001680C790452F01AD2014F0879276C2F7C125421FD2AC627
-E0203DF91748980C502FE04000C55124A236089202D15008B400305FF010792E
-0192321A85267B4C06603F04B10DC122CC12783C00F9752564078E00571AA071
-340C954129671BE02DAD016C075900A52F00EB331287217E4E2F9D05CB0BAE00
-3F501FD85301DF5F09F601980A5001F924610693005E34AE003D5918D2395401
-6C12FE49395D13EC690B3986266011A62F971FCB3C016C0E8427EA1BB300E504
-AD01770B7B0D690C9C015C34D71D65B8035A0EA64604790C65F7276B3F268621
-4892042A961F5ABC17F45D059E12DB34BD1B8A27791A3B624104BC500D2FAE14
-E94836FB68043EF3601FE500B552046C0C871FCF277D135A94227F4809C300B4
-11466C2284299222F9760027A33A18842D62156BB53F1B9E12E64D2DFC024EDC
-12B72F5C1AA332BC3F007905AF34501FA8014FB0047A26F80040630B9F40B821
-9D015037851F6327D936A52647B94B28CE1281058C00357A26841A30E927BF19
-4500AE0AF00061E21BBB5301D708387F0141C620490285006C09D601499D00E8
-296C1F9E5A007A270AA4052FBA12500184127A4426A321D73550019E0BE13A08
-B701DA296041277B03FA3E01DC0D5A043AB56C0D5AC500AC26E3340E7C4A046C
-3D0B8511A61C4179049100F60585095FA51BDE0E78019227FC123ED11A871259
-AD18DE4A250575115FA20B48CA0D99068A00E6045A0086096C22C62641F10BD1
-01BB610F85003D9F5A12781F983401760C3A6D26854512AC2F0070B45A22F932
-9E123EF4147F268E10DF053ECF0DB36C204286007822C8279D350AF7008B4112
-F061256F1F81492761127704EE08CE511C66A0174CB97F12501AF204266D0D79
-0158C200DA30AE00CC1F6E27800C34EB246F125026E2143084269E27CE154A05
-8B24683B02BD3304862E0082FE33C63F19F600396E225A146C328922F01E45B6
-49015A9F1F6C277639009E1F54E30639D128B61142C62680EB0EAE00F8661F6C
-E90E3D0896127D1F5EAB275007C201543187186C345200D36016DE2AA2085A02
-C3771F3B5C06960433C700B205F8009838A3521F793600B107317927003ED405
-9E35449A30D2219F1338862277195D339B05E400C0671649AF39C56C0044CF04
-50007F0A60B46C1AA000EA50236CF10D60BE1467005504842661A601F12FC21F
-A412792F98005E0FF538068600B411FB4927CE0476257D016F055686066C0034
-8723603204C806502778E1285000C8085100A16C2060A50046B601F11A9B4002
-952683133FEE2750006ACC18BC2E48861250365A126C1BE1022EC614A86C235A
-CA01E96E1F592C6A00C95001624304EC5005BC0C50F00E653E228A4601940660
-014D20AA69103AF15A1EE62D003DDC0C447808AF00377F1F50380EA427DA0DB5
-431A781085016005D1024C12DD27A01F67C51244623F0588126A3448AD1A9326
-F43819DC20B34C04D10B9E49399612C1004304B666269223EB330EE03413FC21
-663B23810E31F50D4A01D165057A0FA63904834F0DE60068DB19A532C4500D40
-8A00600A2EE4143C93410BAE04E51B861228FE12B332601F792784013FA200D0
-510F30F627C81AE70D7F043DB9790C27890447C1205A2FB81E6812499D04D901
-95EA23801F6C3609D227B2264BE946276BC25808740482015033EA079D2D50B1
-01F00A2FDA0E62006C9F0D3D5A1B81287914DC015A347F22AF6C2E0DDC017912
-8541009449097904D54C01BC691F5AB46C0B33AF1DD94815FB3F017922A53908
-750184042779BC2447F1419E0086045B1282257933B008498B1E94007109BA00
-F822C9265A2E6C04B76008792384309527FA17500165C632AD6A0985047E003F
-C82EE71A5C296D1F005A07AC00E356036E00790D5A0A92014125B334E626AD19
-93227D12D900387C228E4D00A227C431035FBD00FB0EA7006B27A50DF504603D
-16EF4B375A28D205B95A1FCA2FAA3F1286355004C400471B9F58008130058F52
-1FC527921159BA27E62041FB01570F9627046E3F20C027FB00C347015E39D900
-6F253FDD2E49861278049209E1149C381EA5145200B2075B009225A41F520040
-12F337B213F85A017C0A3EA512C7433AC24A2D78123FB033FC1FC427AE20F816
-8800600E7830CF005A04AD2162C40D5A04BD401B78134FEA402278276433EF22
-871A7B2747D00586007F0BA50445673C047A0C6D005AB406E9128D2E7726FE12
-38E22260BB3D009A095F01F33102860C5A9E187330D70069B512D9590D991E3B
-6818EE117826A912C9500D810340B534671CAD227C0050ED0142D16C1249C146
-28D405740DD979295A0049933019912550BC045407980D6C01F31A9D23690C42
-920481007932510DD9299E01690C47DD4C2779175031E03A1579FE059D016B0B
-AD08CD019B095001CE5000970F6924AF1FC42F761AAD12F722AF26E32A1A7A27
-6D22D80D9E01417E0D86015011E72448D64B227A441FB1370050AA0649851A3C
-6605277E0160A6048A239E0185053E6001AE1BEF105A00E44F015736C712692D
-8B0527DC1F77127A1A3FF8335004A51ACD270D63B006DE006A34FA2F62E12690
-277C01D7059F18623C13E24807A169237E13FE2087276E1AF400A5088500A45F
-01275621D427901F3E8550176DAF3F102FBC1A39FD3B08604100F35100782C85
-016005934F00BF08A400832751C504AD26F31F8C27750E7D05B400CF60056CCF
-0E27F21334CA01F646AC34E81241D10C5231E11F59F51A8F2977279D1F8F0D26
-74FD1A499F00BF0E3D9A006705EC01B260008416872677056CE2013779279A21
-8501A415005808AE0E405B3047BE00D2502B1AC83A00AF055A36A605C101410D
-922AE61F6D1240CA3BB479115000E4600430E6270562EC790C5387019E49D612
-8B1C34C52699143FCF4712F0433161385818E71D6A3F17792A6C00C604B22A66
-12953E14EB2F1D9A5A0065A30C862C006C094D86002776B9004A97133C6C0ADE
-005006D63948BF2F00A707307E1F53F54B34AF50238638129D22CF00E90EB53C
-1D47C412510CCE1A4F277838CD491E6ABC11ED0155316912966C045BF21F40D3
-00533E147AB75D227901A72FF8026C0C500439B9692D15BF770C57C41B4B003A
-D6461E6C033D6A06B45E0D6C02E1590D813C049E0CF904B74601790FDF5A01D0
-0CA33060411AE235562391004681043ABD401F752350B81CCC213DDA652F1286
-360AB200C0502064C636600178089641126CD8043E97012679092EC8145AE407
-522E6736435E0079A30140F360006FD804B50B6C04FB3B007727791D8A08F401
-34BB270A51941A9C0DEE66254A01C8123D610A4A87279C1FF27E260597440027
-A435008226B66D0529EA27BA1FE3285001EB1FA03600B31CC75A247E20861277
-2FB33C00329E213D6512F1007807A003FD0B63BB12DE267907E500D011793F01
-95075503F84806D066267B3404942F048517A627E91F5CCA3D2261E40C47B61D
-E06001A004306CAC01C008AA23FD1257268C0E27872D1061419D21874F26981A
-B40DE627AA229C501576AD38016C27773200D50E802F4ED91DBA3407DE00623E
-005BD90E6FF6470469DE1294183EAA6500810A900197197A2D73085587267200
-2EDC015033E10595095BBC6C0D57AF04864B27B951206C2B771A3C51019E1150
-2A8F365604FE5026BE12A31A8F2F5101EA0C5AFC12AA4122F50D8A008304500A
-860151337A108600397C2042BD270D491F7B1486046C2FDB044CC606AE3CEE13
-00D83E01C9076036860477003F6C05E2002666E911CC03AA431F55F709760083
-0467A01842B20DC61A40A73A126CB41F3D5B06FA01500FA4163A614434C705AF
-26D71247F50AAC63196BC10041661FEF234A14FC0040DB3A01960934D300AE26
-E800AC6C1F5CC5046C0AAD2F61167F2A79245000AE1185279A1F458100D95A01
-6D336A26AD1EF127B31AC300F12759BA0BF873005082F05A03DF4A35CA174198
-1A6534570176472E5C17841252DF0049C1125AD20DA03049C906318321860D6F
-B3042749B54623E912523286227B2792065A01CC31087F01BF442C7921E0244B
-D100F70C5081126700A333156C380D9E36109B1ACB50007C06922F851F6012C3
-1B448C177A0D861279263EF8003DA41AF2228600AE05ED006BD43B22E31B4900
-B708316D0F2DB323CD12DE2F900069129227631884042B94123B1BD9013B1198
-31017707820050B400F61FA822C5A204F52FB13D217B1B3495244C38611A8412
-42A5005A2AE03E126BC1015D0D952AA900CC05EC014B13FC279E1F55F125961F
-860EB75A003F9D126C1F953100EF2779215AB504CD4900EB5E278001369E27D0
-1C6D04AA0B782E50F9016031DF384D09C8054A920D604500660FE0385B12A740
-0C9E5A0470C86B2560CB1A884904940850027E0E3FD05002790AA234DE50005F
-B079472672C7274FAF229E26F10D3B6C1080056C0C1F7D4A006C0A9E04F75001
-EA02B309FB00B46A1B50BE0857009A35179020F3007726841F501277C1580471
-0D830040600AD600663B1BCA720251BD4004CE4725A606DA014184227C265104
-D70D5AB90C4701A326D52753EB01A30E3CC1045901BE5F22831231D921B9319E
-3A511F9234541C830140B50E4104E2003EA201EC3C1A5BA53E20BD610525FE2F
-CD4512771FCF264B0333B7055800860CE7127828931FD04630DF2687E635129E
-22D5452D651979126C26861F5B3E04F20F3D791EFC265DE00641683C13D6033E
-9E6926481FB030DA29B212C452274AEE048B0B27F22E06842752870F5B3D1A95
-2F00FE07BC30A31F8E2E1A6AE36016500886003F67274A851F9A277F1F40ED01
-B36801770B8301D208B401DA0AC126F715632988344E94124F790D69D42700F8
-71012D779E40007006B70169089E0EFB6A1A911FF62C436B3A01BE0752048F01
-5A3F001253BF05405B00B40DC727A92FD80450CE237D2B9301D0400583005037
-CD04B35A0C6CF93900DB069201650A79046C3B01AE126C2F41B26B0961AE13FC
-013BC500E56A0AD44F126445016C3F00FA7803490A79F33B13B51EC805DD0068
-0CF406A8006B354E18A027F01B5A277D13692781005D327900F109A80D2CF81F
-3AB840139F3950185AE308530FA54C266038F2521B802700D709416604B400D1
-591F6EEA3E22CB1BB6659B017730EB1F7F2586058300641F7B35069E00D6266C
-2260B119C8128725791A4696245412AA1A6034E9228A204FE625791F9105D800
-4E1F97360075237B0C4D924026861F9B348820EE12B9720B34C726AF2D006B96
-277912924128CC50156E2E8E1AC126E1105A0346C60449FA22AB193F9B04C43D
-1F6C26D15A01850759007604820DA93512B027D81A37E819A20031CB04409650
-2FAD228C1C5E3E0AAD2D0068A1097804331AD3266708A503E1325639EE0D9A00
-AD5A1B6C117B04A40C346C277708A201E63200C905792B46BE1242A500CC3608
-A000FB365A277B11E50158DE1A9D2FAD1A3704B301600CC400A7095A391D47A5
-11840150BB4004E6003D6A08990235AD25D50D50048600409433791F8D360077
-0D59E8126C2354A005880038AC27CE28F326C322E2019143007F055AAE04790E
-41862162BC3A137B00CD0847DF25861261BC39138627FD50A748009A50157948
-00B90F773F22E02C0BEF39AD2FE51F57F700AE22EF306C1460A31E50E20A7500
-7E055A3F139B591684481AB50DC85329A5123D6408DA0060F76C1353F241276C
-2B489901E07F005322D912601A812550B826F81A49800067043EFE741F5AB507
-DC00A50B63B22DCA01268407DC0040EC16497C0C66017E099712782C7A1FEE66
-21942F1395265EDB0C77005306F00DA150337E017504FB27460DE349006C0E04
-37F41039CD2B129C1F6001BC511245884A085F00488501448F145A018627BD0B
-377F01409E1CEF26B31FF86B0428DD30049800693D0075258204C15022861249
-20C929097905E504D1106C3B1369F03C079D21F40DA5056D0E5939BF12E71BB3
-6C112FC90D356D246012EA2641067948BA33A41B86126033B81EE522B4153F65
-3C04AE0B4A043AC401F64500CB3401AE27E81F9D26653D19EE12BA1B9C4B009E
-700235B5218AC46220AE6C005FF9074ADB347F0472C70027B926D43916C72706
-3DC2500F970049FD22B42E0083325B0C84013CB66D0D63C72250E820AF16F70D
-9F40017828D0059800763DB8491A633F26C904B33F04914A306E005A34D22F9E
-00790661279433019C540064F5168527964E0170EE3A126A01465A27BE029307
-770490314FDF00D0522661BE751C50790D85591F7E4A14842A6C0140D5049600
-5A2F623912C83D1AD5660750275500850927861A378D256C1441FD3A1D659502
-740DA1600A6EDA67002EE51F3E791063076BC64104CF5027C2104700AC3F1385
-340179078646315C1CE710A318683445A62501822FA100784627601F7B26CE03
-C23998116A0148E11FA9267B1250CD4020A53905AD00D60530BE1054009F1AF7
-0BD00E793D1FD8263F5A019A0D39791AFC004808DE123EB53B09A705F73E01A6
-0FC75B1F792640AE05E100A5520B912A1C79F10C1EDC334FE504BE5001C905B3
-00580DAE0634F91F87002CB3224A129E6C045BD203AB27DC15510E973800901F
-60EA275901EF08B95D27D45005C600AB26800050B901E50F5AF212BD0D54FA17
-AC0EE600A30D68275504EC22A612338603D100F008610CE60481481D69384779
-1F8622D3502776356C4200FD50006BC31BF92147B1036C1186279D2386006819
-E4276D1260D81D7934009F0EC56B1684236C3F22F7014DBB0030946C4105900E
-3D6817972E602293277923D15A115037ED51047E01F4360CB91943861B7A0192
-24F51E66E212780133981C7B26754518920F3479277E125033F93F1F70278604
-3877268532067A018630591550FD01B22A5E4307C0531978375A22902779296C
-12DA2F950AAF04E2007F3B0DB400C004AE2F600DB34508790563861F42BB4D22
-CD016034D5279E048F00BC23468C044FFE2D530127F40C52CE049C123E841441
-AD03D423B21B45A101EF4812E9400BE1019C400177BB14661ACD31A41B854726
-970035CA0D5039AE0085092FA426D55405BC11CE3204FE0040A701F00966D304
-5D089E0DD416B15000D902C24F22DA4105C5761F3E861A7714D8386300FB480D
-9D4304B500C3269E014C12FC225029A8420596315A2764148F219937129E27C5
-3400E70A5D00970E40EC04570D7347315A1A940037B9126707DA774901AF3012
-7C2756B106E76A123D0879005ACF1F8531007907A6661F3C5E1BA32F007E0590
-49126C4004DB510AF55A236CEC055C3449C35A0080083983276A00A25A226AD9
-1C622694351A8926C72F7A003E6C1F95213D670B98511C823600BC0848D000A4
-04840E982E05C515DD345A3F1286195AB76D00649A0D6018F45001E408D95004
-EA0150DC005A11944A279E16F029508514A31EC000FA12D0410BEE5324812099
-401AA73A1D874509EA006C2F5000C25E9A26EC2F046C0A52AE1F86340074BF08
-F00446DF27C3330BE500B82762137C3104B1002F8612D602233EFA1549A800F3
-1F87380CB247019D0BC00242AD0D6A018E2450C404EC0B49AF1BF72E00B70DED
-50278212347B276C26E41C4D92237400860AF84A00EC3D062AA41C3ED004743A
-1D93126B3F247727801A6930F24101D70665347904C8073F6C43355B276C01AA
-306605D201B435008804D26800DB5B28921FC9219F321A015A1078B426FA123A
-D40455D90F4581245A8C0C78014F9720602F8F00AB22C46A1254A1217627699D
-0E7031C71A770D4F06DB78122D7D21772F4BED0053DF4012FD1A613056367D00
-7907418949296B09A501E2571DF5118D013FBC016430A722691F7B327720D44F
-0BE801572FB300D5472CAF00C909A90EC62287157A3050A512BF1B3D602FB600
-F40B9A06A351207C13962F580C50E912603E0D953B01B60C60017E0D51FE37BC
-49003792019E60247C2F159A2900A93813B4213FFC023BD2074AF90E6D003EE3
-4006DA00A60740BB015E0B8A2267B52C550060C605E45012881FA03A1AAE5A04
-780C9F01BC14DD235ACB26049E18D327783A0694035E33CA6C133BF21249CD02
-AC0CCE056000973B2685207912824F127919801F863275055801B60AC304266D
-004FE0019310641A7C29CF3D11E600BF420DF36D18792AB21FFB4E14812747F3
-4927D804711A7F16E159206E3400B219F54904CC511DF869075F941251A51286
-1A368127A41A7826941D5736F1207926DC5004E43F019424F43E1F853700CF07
-3E6C0E8500349227DC26792784059F3C016CF134600094105AAE224FB50C5000
-9F5A067F013783266E2746BC4C1B6CB509C502F13F06BC01FB355E00EE2647D7
-4927711F8D3FFA398B126C27DA25B0490066048B4A296C1B860027A5035A076C
-0226C7089F046C118F19A841CC01693D05B80CD1560D6C017F366A0B860127D4
-2F00C5246C4304BD5301D305610BBB013C870C6203499F1235972712D2401179
-03B40A499D2552BC01F52849D10AA3005F08F111406719AC124F0CBD5022FB01
-35CD002A7926DE1F40B81BE16109EF00981A7A0EFA0450336B365A1F90266441
-0CCF5212AC00660D9F00E34A016A0848AC0A7901810532E326B338089E04DE33
-4CC44738D933BD417832501FD322B8003C60082750A4128327771F3FE426AD1F
-E912B534499B04417A1A8600E12F6824951F39E851236CFA12B227CE2F006AB5
-0050865804A550286C30FA1186046E2F5F05B3227B1B3DBC401F5AB702E72791
-25860439791A8A63126BEC08A904860D6C2C5015AE2F5212E30148269E1FE000
-AB0BCF003B9D1A88032F7B20921CFD286C3816B227D01A2FE91FC0374F981483
-1A61F812415D129A2200790C840027A400E5790164314CE11F79F00B40C300F5
-049711784F0984003F6000E01250B909E933610D9D01F1094E8644029008405F
-0080056CE9280D3CFD0626C44600DA0D75005A34DE1B9E15860D5A01F95004A4
-750030880D5C00D81B62E200B53005A03E1A85385728D3049E00874104A36227
-6FAF5A007F12672295275BE70DBF2447A204DF3450048412A55F0C84009E7500
-405A0CFC015A09C7015035AE00D00660EB27B01F50F60D673E0E55A50A850495
-002F861D54315D3949BB0132D9245AC6227727791F6B365413B1401D78123FC3
-0027AA2BD617C1501F9B42195AC9791541923012822755C526B013416600E948
-38D9306B22831A3BCC6C1D4FC33649A10E2F730C5ADF4A00C34901EF125F3E1E
-FE4A0FDB3400BC06390DEB2744BE490483084379015EF2123C670CBB5A21D300
-32F21F523F1264A31B772649B846277822861F6D2687390E6C0488125A359C1F
-CB2640FB124625AE6101E608AA0DCB002662A105952F038806A50CEE009F017A
-055ACB27B361176CF70E680179340DEE370BA901490467D80052F1099E043C87
-017908C05027049C1EA50DC200E3095005FE2D0197270142BE1785263F0F982F
-137A218400A66A0A307F225B931240CB6C1985015A11F82EB2153494270050B5
-00773E019A2786460269BA05F13404D500860F6A00EF0DB702E80DB40149A425
-E02FC201B3086C0090052E5CC46C10229D347C236A276CED401F7A13FB501BDB
-38862F5922CF27FE320085043CA004338226961F51A2044AD5278521A23A1DAC
-22653F20E51B4AF520953110AF6B127A003F652A4B8E248512A9600C70EE6B05
-3EF700B36C2261D505B131C7402377B801C5083CF669012FB309D91F79266C00
-60DC05B3731F7C2CEF19C80D5808C578132F92225AAE229F2ADC27901C7C4A31
-633A542FFA0860007A24862051F24715BC78004906D777175A00D702AE06500A
-C4013E690DA649006107AC3E0E841877461AE80D49D94F00BE09E60066269200
-7709F55001790C7301BE5C0084093E6300D36E0033CB2752EC05B21045D2006C
-3A19CF214A129D5B1F793604F50D4F3868025A07DD003D501F8926501EA04B26
-60389700A40FC746216C390ACB05460F84253FE9244005E550007C07467E0A78
-015606C03F09A400C50575159234C7184F05D529029836511CEC27872B04F80F
-A12F8420791A86275AB400793C12C027F41D925000B906D763267C2A07993C1F
-752EAD16C6305A1AAE3D1FC22FEC27961636A527CA12B3541D41F44A0491196E
-3A1A950133A222E859078600C73201A70BC8501F8100A11AF925A1129619E96B
-01D304780CE200860D42D31F7D3104A50EF656246AD85A04B565006CB1355E1E
-BF27DF122FF61B3ECD345B20DB1A7924831FD200790D3DF06514834111DE019F
-0C6B00B25F376E266312FD34B600E3105027D3236D0B8D016904DD4728933B01
-9E00C66812EE5B0D86043C7812DF346003930885007B06E0500F70017E2F0B87
-0626973D0EB502CD5E26F963087C0130AE27772350D7412F61019D2DD927880D
-4F346C2B550D40AB1758C12847A91AFE04583E01EC5A17850034AF014A1F8C34
-129E2A0D8E01990C730199590062A30C93008504612FF310A9275B269E6C002E
-AC04BB5F2773213CBD401E01AD09E00492006C24612F7C05934A02EC531F40B5
-3912811F5D12C31A5A4022864601D12761FC004C059B12CF265A12B948336800
-BC22FD2650E237B96001DD672240500D790440C412488603F8059A0D6A048711
-E82679086C0160BE00EF05B379002F91360086043577279116B86C223FBE2749
-861A7F0DA600E04904F85026D4225137C81A3CB940217926EB2752B900497101
-860AE50140C15A0E7735008706D0581267DD82277A1F5339B214CA0AA526F816
-34982705C96F0D5AAE01F008A24E33F904B100329A219013407FB75D22770047
-E24D270DA91B77305A0592006A034F1A852F0078F6019E27AE1F5635DD155038
-621FE627BB26A51A5812AF22E23F127F1A653A1FE05B08F34912D25007C20082
-32089D006906E212C229FC27771A85385A007D0962FD004A86046B09E001500E
-991A3B9D0C3EDD31691FA5224E1AE72255FC1FA343009408310DC7004BCF0C5C
-4003831A75015BBA0041833000E81A3F652F6C3E00840D77155ACA125000BD08
-264601EB2CB41F79146CF7013BD90D9F4012AE1FA127F00D5ABD12347E17DB00
-940A8000689E0DAB50007A085A0046CA3A00834906932651D4019E4612852297
-30601F95235A11F3501FDB2F9A36750079055710C422B112C82CAE3E16820E34
-F126A71F40BD6905FD0350CE1B5A13BB500485087B00880A397F1234F526A847
-5A268632019F26ED4935D70DAD3E1166D615AE54267900C805B411E323AA26E0
-3E076CF4354979D70E711A8D0D6300A5043F9852057D1AEC4C27D9086C019A38
-1B54A30561347127F21EB8431AD10131C52040FD339D0467F03E1FD028B5003F
-850C27B4004D05BA0BE9004FD72D6401AA4A0A60044BAB143BA3400176078449
-016C05D129B8501278005C8612348C267712478605970038FA27CF32B027CA49
-01C4610E7700E603B511F2691A7E0F97005A306C1FE24709780436A10E95275A
-1D7F2C6201406A1DB42D04A227025832A750043CFE4025D11F6012AE35640086
-043A982CC51369D60827E620A6065A0179310C8626428509A464126D1D7E0C50
-049901770D86164AFA6C1B65DD6F1F6B277D3804A10E7B3D12C327ED1F3FD063
-00DD5D27EC1A32E21F9E450460009D31CC2906E75A00AB27C50036ED23447A12
-6201730D6B01792F500493276C364421790538C4005027B81BF30090042BA822
-F8611FDB490AF54000CB1F78D004920055851B66C21AF00C27CF69119E59087F
-00F24901D42D41C760167D248D00478742008611D336BD2260E4005AF4127435
-01B705DC29BF1AB134521FF42DC7053801C12D0240A5019D0CC66C1B52CD2677
-008A0DA20150227C300A9D00A9600D3D6412871FE1266C034EAA3D1AD5128022
-63A10F5CC707AA28961DF4219D1AE224B31AD2098BEF5F19A5582265E4046C44
-0C6038CB7900503E01820433772294560F8609503A20EB380BDB00418400449D
-003482013DC32FA43E228514AD0B5000E805570FFE2F04C35A2B6A2584149402
-39A71F3E9E00E3572592480E6F385A12D96303781D60AC7A1543870F33FB2666
-213FE6004104FA50276C32840BF712B2551F7D420179BD00F136AE0D9218F80D
-670185315001F6072D7902348D21DA045F385A05AB0985005122A3122700CB3E
-01860B3D85139E2DBF0E52126BB81BD0275ABF00A50438B327FD12B0700E67AB
-22941227B16C125BBE1FDE266A0F5A03BB094E209526792749BA441F6CAA3D0C
-F004AF00530ECC4D117F05602F500B790139AD00F709850030B9269D003B085A
-EA1FC450098300AD056727B56C380BB700D51994296A0138CC1134F62050306A
-18497905602D9420C64604A46C1441B21AD64E006E1150BD00D63448692D40EB
-61017940964D12FB2CBF204AD5017205861FFC2706860C9A08458612E9650679
-01623F009F2F015034FA570430E42905790B9300EF1F92276CE35B04FA0D9E01
-7809CE0150138027771F40FC2F7604BF26DA1AB313C927EA5B1B6B27A422468E
-075014E84ECD27048000932749DA1A79128D07249D5C1B7F255A04AD23E67004
-50860672039F0BC60039D922B8003E781BF0233BBC6C013D840DEF279E310C7D
-268D00F90CA00430C11BDE042F7E087704930037A622E7344F019249346323F6
-1935782E14D52750BB16D8265AE17C05740DC651018C4938B41A446E3C06CC00
-4712812F691EE03364229E27DF00B307CE5E0AA01C6B3250008427790096082C
-C510910158ED123ED3680A34116BAE376012CC013CA12CF5354FD90031F0053B
-E14015830D3E26DC1CAF29DA2582275AA00270125AE010560A8800520EE65925
-6A1A7F01E4451BB4125A2774194C8606531350BA1FA4266A12F75A08405D00BB
-6818DF01C24C006CC8019D4F008D0B3B6B079504491FB8213B7A22AD14F60057
-34D30DB25D1F8725B500C706A34800B4510D851B5B346C3D1A7F0040EE01B166
-12FA1E69354A77007F30D53E046CA8013978C27D015012EE2F4D881364035A01
-A50E49791F9662016CC80048B87900450A920E4A01ED09337F27A4320569BF34
-49CF1FA22E06C400B6355312A165043FC404B639DB0E419B3A860E5500E132AF
-271679C61295233DA50D406E1F872A0D601ACC3F1FEE2286441AC01073004AD2
-0141096C2786127F01691543F50477345A2676391686203EF300479B04E80FAE
-26D95619970D3892043FD712B81FF149056622BF1F522A9E002540F72776009A
-0740E70DBA22921E3DB502CB0943B90E502F9006276BBE60265ABA6C1D42C019
-FE01498E28009608267B01638612794B06A96C003DF079166C4600672EC700F1
-0140D45E1987004B9E032F6C07EF015A2F9E11EC05B243E33A04A75300AD01F5
-365C2AED33971A60E9821FBC04DF269F2A8C00319E12E60AA901EF5E08D70269
-32C017562965019135047D274DE123509A015A069D3C19BB0D78009609FD0E47
-A6065A04BB5026C61F592F6D400AE16913602780331BA022F91A5AED124C05FB
-004708A56300770D3EB615EA4F1DDA5630F4173FDF3B22FD152FCE2350003BE2
-0D921A7920645229AE05327B0B3DEC1E57DD1A7D288814D0005F41316E002691
-4A0D85402676127A008C0C6B03B30C48006232771C5A07EA22C0540B63276C1F
-8512309427A513780541A500C93F125CB60ECC065A00BA452786346103945031
-EA40266D1A5CD71F772796330B830179049E00D17947008625A001E956007D03
-9D3700961F792D8714D03B229526CE61076C017A3D00B00D4A97005E0A960141
-8505930DA15A1FA827FE01B20823961446A222CA6301833700A226BA043E7927
-AC04980EC45512F93B18D95A05A427DA2346C74E1F8726D612A30148C44C127B
-0439D822AE00CE3549B7004B0A53D126F9127B1F50F700276D1F862779310AC8
-00FE0ECC270085145AD801B02F028B11E11A61E614B036FA1A613B062EBD11FE
-0C761940D7345E12CF4931CD01A320794E02E7055A40208527C822A048278604
-39B41FCA2754BC275F1FD1310688015A12803279E5014FF6006D1040AE0DC850
-0C491B75FA09501AD64926630679016BB30C31C61A6108AE015E06F72E6C0593
-27FB0D7800B53549850172107F5003790E60F775214083006B30950C7845A537
-F300B00DEB631C79153E7846E00CB2043384227A4837AD0086054B396912562C
-B415EF5A1F6C345A27AD0D6605BC5008860462400DD8003198123DAC0EF400A6
-0B6B04FC1B50D5196D40038D0C6C00EA50126CF42649D74726C80D1A4178128A
-27E0055A30681F78E36900562FC1680034F41FAD279E2F04668800509C402D92
-1D803900AD55217918A9402D641AF317A72FFB3F20E227C51A4801B30437A01A
-E003BD2D0568025C3E1F8539019E2751B50022673B1F8F470BC800EE085A4026
-B51BD400AA0878009346018905A500D1048523981B2D7927E512AF6C2454F026
-68C6006D1B56339219850EAE013E9E05F24D34DC13783E04AE36027C0B6604A5
-006036B026CD04571A9626FE01B5043813AA228E01277AA30A6C00DD1A50E33F
-11E83901FC124ADC0E63C93E0AE2003B6A01DA0B9E003C6C025A05870C99008F
-26811260E50860276D185ADD13BB12D74906C35025DD045F39A306C36C00F954
-1769249F1ED063017D27852250CC263C0DC228DD267A1F5A37F70068F100A51A
-593C08913704861A502F9D38D51241E7345C2E8012693712A3005B2FC2208726
-61B41DCA27861F5094D9006C1D3BB74000771284274D924607DA0E48EB174F2C
-923E128501771FB025782753960031A304501A8B2650CB12861F772757B612CD
-26B91A3B673E12E02FCA2346890EAB00843F227C278C01772F6B04AA0D8413F3
-267E1941A21234B7277E0F72032FF1135104F43F056CE5602079129E0840B213
-49920F3F5B0C45C301F616B55C0CA901E2095F01B1056400D6084EE600BE5A1F
-7E0D99016509D9004056006C10F92D0616820D9E601269C220D2490BEF00C332
-6038A4056101C906B85322AA0D55008405CB0A3BB969228227F2013F97055A33
-B204ED0640600892004EEA04BC53066C00790432C61F50F307AE00561AAD26E8
-12901F682D97025A01E42C055C87019504DA36B2500A6BC0325D1F86124800AF
-0466304BE20177072FBF1FD3339C1F7B286A0044D22779144087274C831F9D26
-931F3B8E4004D026E51A3AFA3F169A0EEB34AD3C026AA07127F14300E7073073
-0134AD1F531189017F1250D778203A6004FB4833D06C139E2086194707E400A7
-105FC30D45EC004164259C1EE3375A328644276E219C27B21EF2540179361286
-253BFC400881005634F600CF2147B64D0F6DD51F3FED13435A00781F9E380094
-0CAC00C530942750F000841E9227DB4F017C046C00700DA122E334108D2457BC
-00F31141C40B5302C70F6021832E7800508604A75127792277135ABF3F2201A9
-04347F2753A40D9861046C9D3F21F727BF1D470C6BE814862B087D043DF42F50
-00EF723E137A2E741F52307822A413CE500E7C00A90FD92400A208F800501093
-3912A126D14801C663046CD41B40C10D76400989126B23974400820D6031AC1A
-FD105104E34F26DB2879237E0FD60A3EB3116003AA10863D26B221ED36C8017F
-06855000FA063677269A013074F13849A601FB08AD103CAF46256B0CCD01B805
-E0005009DF5C124CC40A94013DF3411CE22900D15A056C007D27A5003FAF004A
-A326BE215D05BC642703CE5126BD02DF06AD0086096C3D01C12F6B21750150CA
-38631942D66B015ADA0966008234501FB4142E66A6045E1AA5502FEC00CA0736
-A727BE007906652E80C4276C118B01600BFC01531D86215734FB3D226C00EA58
-09844812644026B21FC53E1A6AA70E651ADF6024008D08317C276C1B5BCA0B2A
-DF008C1F6D2F6827981F8531D238791F6B24D6125A0081105AA03A0D862F9F10
-F21A8C245A35D31266008B10983E0D9049119A003A84277A20D14A2FFE1D8527
-9413F9288919770CB9348C0D2CC120418823A615E6097A005A9E015027DE3D00
-C70E497E1F5AF60A6C2149D226BA0D41019807BA1A3DA54E186CA84000CA058E
-0C5ACB1AA44717952F01B705DE5D0A4704779E012DD3048B4313B94A27D95619
-B500ED2701649C125033F10D9F1B830EF34700188600FC10AC2D9B27C622B402
-4719B226DF045D345002DA059C0B50EE401ED44A01DB1AB43241F95F18A30C63
-3E049300600CDE004804A107EF295C047901A458077E0038ED046C219927E138
-0DF0128605946226860138B204309D12E003553F0078D72464334875E80439CE
-2707E963276D1FAD01457E0527C200FD60277E2F1277F262213CE74E1FAD3406
-7B04830D6B0097123E7747B73E006CA4195A3E05D0003C5F22B06727A2305801
-770984043D672DFA6B00791B3ECC13B4651F72267E2902A358043383236B0079
-0B5205C80150F41ABB1239AD50236CB554267B4711D3501FEB243FFD17B06112
-792FB5015B109248316C1FB62B08FA1ABD6111865600772A850FA56B1834A300
-F7260C582B88009F3A50129B00E3288B1538D5611279390E961A55A5004C0CC2
-005A087F0056C927FC1EB334E72B50CC04267B1EF83408C501B560246CA80491
-0AE4044508BA4022E81E50DB17880B3EC5084D9400820841A911E500BB692712
-77FE14AA2FE927C0248E2776380E7D276AE53F01980D390BC701379600319B12
-850069335003D127920E46C74B04B300CC3E01774933790627E3173ACE22B01D
-F43804EB5912491A7DC505B21250227801BC3780126108F2690031A01F55BC01
-EB0435D81B9D27861EA525EB3A0C6A007949016505860F4FDB0D61054979217E
-4012F63919C74934125AC86F1463950040A0056F00B21F5732E9184823FD2E00
-85305A3F0F79CD39006A0973058501690FE41BB75A00A603511FCB275EF1711F
-5ADC1F68BE065F2FB412C8229E1B4A00FA26641A7F22780C5AE510AD0050A241
-0072A8044F0979005A9D260681CE5F003F501F6AF308D3266C0449C6239E2F0E
-894B04DB0B45752585492770015811D03167126CAE22C337129E27BE40249801
-41BE2FAC00EB2700964603863E017D9F27003DF4043AC26C0D39CA4026790E85
-0160B66C0160C94B0A9B04F623015BA526D61FAF163DD85000840634EA268415
-8C04A5093B00AE2F02820E4E3AE104446C00830D5DBB73147901D32EF818AB40
-267E23EB390BD06A21502EE76126C4142F6AC03D012FA714E179013E612F980D
-F92E05710057B11FF03F24860038AC14C90DB439FC490579019E2F03860850EE
-480A7900F953288213742284154BD8500DD15012EE1F02D9781D509112521FF8
-5A1261EE04CF27A50C3811B9263C13DF206C3749C02D0D82005A354B95122DAD
-224499126808D333501F79BC58166CAC22F60078268B1FD92B49F50141074FB8
-440D97013C6900BE05551288275302FC0C960134930D4BDA00501273F1216C02
-31BB10A40056401A79AB34DE4006740166AD1ACF5A087A006241046C1AB627F3
-2250E1412C840031D4136B3A1AB40CE801CD093D91052D8527009A2F546B350D
-B70131D8058A0028AF013A97147B2250D9417B0476A50146AE00840850E73441
-B908F001417D045BCF0150C1385A00F76A014905E941085233931AAA0E620496
-08369E26DD1F5A27822453D712921F66A13E00C11A9E277A1F47B8013D850B7E
-22AA3404840E9C5A26801FE712B16900500B7915C827BC0D3582112BF9203EE0
-0F9E2685005A0A9100620FD71AAF6C2052A5068F005A366A2B50B1125FA91A65
-B94106C00C9860267B4926AE34497923851E5A3F00F8076F0031F41E5234861A
-DB27B11F610497177E2765BC0DF53E1F792F008625941230D8269F2D1278BB04
-48D80150F14014C051126C007C0AEE00B309783704F22E04DA582F84086A00DD
-5F186CFA1FA529E9014B9926D13806DF005B34830127EB26BE205000952650E4
-044B80016098226B2FE61240CB3B1CC2279E015B3F0594013CE34430D31C9F04
-8600E23B04FD0857178527FA4100E308A000690AE101BD0CD604B86727911BB1
-5A129200EB05600D6C017812CB275F00C90A50317400B20AFD610EDD05409B1A
-810D64D000288410359D27007A346800E729A7328C1B3D6C2748A64C15865012
-950D4AD51FAC3205CF44086600710F3FBE0854004FA11345C40548CB4C0A8501
-63FC3B107E016033B51EC63205BF00A5045AAE01864C0D7D2450BB12F628C01F
-611786046212F227416B2678228B30DE004C052AA71F5915EF2A96145F32466C
-2D5012C6016A2706D32E66218A27A42FEF26914907FB401D85259F1256268F13
-369D1F4FC4005A04C13F1D5EF922B25A096CB11AD223901F7905CA0160C104E6
-0026D83B00C52748F704297F1140851230AD27CC1FAE68193BFE791A65357B1F
-862C11923E1FB42F046CD722A7198D00480C8E4C1A77279235186D21F53D04E5
-07336F008D0D7700A80E4EBB39490DC81A9E00B04D016C37AD6385104ABC3E76
-0D54399E04FA099B00841F50EC407E420DBE3D0BD1006909B300377B206AAB04
-E1013FD56C0153BD043E791249F0387700923606790039EA1230830C5E05B510
-5A2595203F50139D680A8E601F7C00346BA50150F000B45B017C05574000D66C
-0C28BA00EF0CAA04F75D01DB760F48A01C405A05ED266ADB5A1FF03C09D20E50
-EB079D00AD611A6BA62280274BDF4827FE236C0079A5016010ED3F0DD1139422
-0133D40179042FB400DB1A7F23641AE22FAB0A3804B60177189C50337F12981B
-50D8019E0D3C571F4EA4053AEC1B2C63E901AD256C1848E012B04913CB6C0355
-C6014BFE3A5039D64906F60CAE6C311ABC4106EC0DB3771239CD2065364E22E3
-1C3EF50D862D02AF411278275A276D16419E27005AD1087A00B13E11A3084401
-7A0495571F7B00633349791245953801D609C5045D0B87019C15E921532F9336
-571F86264907E95098266819CB5C1F8127A6003EAD5305722260C16C264DE447
-00FC0642C8314587145B2BE400BF77086427860EA8780B27841A930CBC032679
-018631501F8E263FA412710292006A1E802B752700FB5401339822603E01E25A
-0D9F07C804A10C986025771A9F5A2364CB04AE06D600B5300869AC33149829F3
-22864A2D7714AE25BF4200F62BB223CE0C2CE02700FA49125A307822B41F3A5A
-4104710BDB06C204A5015AB3731ABA430BF1375001F5076C0E50CB02319410D2
-00490E921A5D128522951F5A01F5043EC6114A83192FF815C4015A4000C74934
-D5005B2799502FC71AF20CAB05DD00792747BD19EA0EAB009A04CD40801078DB
-0346CC1F9E31007927862479276C3601B304E14515ED01316C208338601B79E1
-3E1AEB44026C0D6304CD00FE5127701134A1266A108203A56604B35B0D8336A2
-01F03C0065DD12AE32BE3D1B7A266C2CF70E48003B042979008811842248BE35
-781248E8227B279F1FF200B204CD396301DB0D7B2661A500943405AC54008248
-33DA236D218004663AFB0542E90A62450072375A17641BE30B347E26612FDE12
-3C630827B11F50288810690949B71AFD015A0AED00CB4A12623D00900D49890B
-FA4912C64E0152057B0D5BC31FA530931F613D04CC00E45D068801D81B5A3A15
-883E269C1FCD177C0E50C4400677006808834C00E51285238E1FD87B65CF1AAF
-26C4279E005B08F03B9600AF0A5A047036582C6C2608BF5027A81ABC09297F1F
-EF670E38B9270D941A980CF511A616881F8634009F12B52BCF0E9831AE4104A5
-5301990679225AB51AE149006D0BAC0053F8278411712E43BD3D127A1B8930D8
-1FB75034D41F9F390086042FA526C4239700368601E60950BC0D9F1A86471CC9
-146C2F41BF00F04F01DD0869035026AF1A6C258927CD27F71FB446316100BC06
-60401D0A38820D76016212D31F9A2B046B3F1D4DFE3EC712A806ED45783E1086
-00683648DE12520126D26C0461F0055D00B03A512ECD015A0DBB692782015B26
-6C00FA048630771FF028CB129E01417C018536EE5916C43404A900DC50039C1A
-915027A3046D008406279A00790757AE2365F20C73006727F846186A277B1235
-81276E3501A52750E8049F0E6F401F7E2252B62EE860009309F501A10D90015B
-059C0ACD395432EA01A2F94F00DF2D4CFD5327750150BA12DD7F016C26007C1F
-8332009E04E52255EA0579016CBB42793F1C8D204D39CB315A0493006138DF2B
-5015D71E3DE506B25121490FDF00470D86005035F40D30BC129F042F79219440
-1A7E3A1EC40D6100D30540FB15BD2F49F6125326E51235CE173F9D34E41AA312
-57CE05AE00DA5A00EE05B85A0E83003D6248279912D20D9E340081063FD83050
-1F79346A1A50D13E1C78227D0398126C275C1F8F23A2093A00AD0DE924613A05
-27C2129E502FD70B51CC276C16AE34139626A41A3908AE00E60BAB007E127626
-E01FAD0E7907A40179044CA613873B1279C65D226CB65A1C65C11746A650206C
-2750B801E3086AC94106974730F0344AAB0E5838630A7E0169B94102A4600084
-065A01438304750734862278411D9212653F23FA30AE0CC508F8016C2F6004FD
-431594116601BD5A12E200B7300D6CFD01AC14E0274FC2040FBC04641579CA26
-7A401A8E0CA27249335F08E20448991F6801A250017E4900C80B4BFE5A1A7727
-5A34DA22A40186085632EE1E8E2649FE397100436201D441012B92084A01DD37
-0492096004E900CF0F673E2486135412E75101760F82012D851FA411D022AE3B
-178432501E9B27DA21BB1250DA24B54B0FF5320BBC2650D00C7901691A7B2686
-1E3EB000C2541B6CC622A7268638048529742260A900265935680986003E9F30
-5638E95103406805C44A00D44002F100A6401F853700B60EFA3B25C50CF73460
-2C92002FC4049D067A0F6527FB1E409312674000C6095812C02FF31FA3330D73
-B914F7279424794222D3277A30841F77059F4900F527770027C622AF26DB5E08
-E22793013E5F05E000BE0CF404790E6C278601407D00773E019E6B04992F0092
-1FB427D4125000BA51257F12369C01347900F60B48DB21AC05EE113C8044B10D
-D3521FF21678DC08A5002FB31FDB3C157C2F5A13AC1B790DC5620FF75B22405A
-098C1B5A277904DD124285226A31F31F9B00791250CC00B205D15A227E279604
-870A6B0550EC203F5600690CAE00FB5500A10DC20640FA3A18D7336104A5486C
-0B8600780C39B200771A54EC268F206C277C224D33B200F01AB3320CEC1BBD5A
-1448E11A5EF539610695005BE2346604DD0745EB0B4FD40D416027B00078124E
-2E7904D62705822C0195346A001B8312447E0B6C005AB304F90882266A278630
-00982B0579AF13D2003F9D0FBD50256CB501E00DA2015F2FD138B405733C2087
-2E0C9F01E31A6C223FC42794007D08A134BE3F1F84321282296A1BA7540160AE
-029A10BF3D19DA3443F22949921A5038C307790041CA099E0067CF155A394978
-089A5B268A0430D500387D01500EC950227F38058F119D1A5FAD26791F6A2FAA
-04781991275ABD00CA511F65F51950C04106CF5095265FC418F3268711349127
-9F31CB01EC0452D11869C03D00722764E3046C400092073C611F832650C10858
-036C4226E550016CF8375F31A50FD879025F12AE27DA1A6E045AD20560B60AF1
-02753C2290122F78267C4F0886017E045B07C30060F9126A2C49A417624712E8
-4003810B95042FD91F47C11044852268A810CF27A40334F00DAB4220F6278532
-008C05A401F11250D03E08FB013C62400A9400469A006C22A5122E05F9003193
-01A22AE5500E6C007A0D582293123687034F11E824860D5028B316F21CCE12A5
-4000D3123E861AEB0E9F007914C0264D10BA00436001274BFB461B4E019B26E7
-132E921A3A782649DB00C608E4571ACF0035F227AE21CD13991F793203880BD7
-0431FD01AE355A1FB82AF826C25D0085012C6FE700B3082E742085134077176B
-01C55A005004CD4912DF38501F962B005BA41B840DA014EA27B81033E30E8902
-5AB56A124985227749067801BD22E21D3FBA3A07DB6024F327891AA401CA1E9F
-015C2E6F375704FA50277C0149A5225128BA3061088501961B770CEE3AB60984
-0078CE5F0E84004A7901E35700C9115A2F47643F00860C459D1C710D542F6938
-E605A64B27AD1F86500D84267901930878006C0D40A812FE64053C601A4CFB00
-B90549DE00A22686300D77B73A1A7A2B5D0DBD620970E512346C27DE216D017F
-1A914D256536ED1D3EC639AE04E00C35CF1E60385A04AD64006CA03F1A8201AB
-0651305F357F0D3BD0059E0087326A08B10CF52D006CDA095A04F23E20DA2752
-CC267B135A3F1FAF2A073EEE3141C30DA335129A2786049212A420B826EB5F05
-C4003EFE01B50D426612DD005A3C01BC3F1CDD14C7315021AD27E21F7934511B
-AF0DC83F960D42603586227A2AD71261E73E1569EC01B419780027CF360551C8
-0495008630C1385704C508AD00437C01791A5A3E1363A90041F5128B2F5012FC
-205000B00E4E2078C50CFC1941EE6B12501FEB23BB1B92306E1C60BC0D36961F
-85129D4F0688003D6604A800D76C0456B41A640585216F2650BF06671AB423F8
-016C0679371480275A95197A279500882C489B0EF06C12619E043E6A0EEE6012
-85025A06D30092277E28016C279E12EA01B009470597005008A50040990A47F8
-3FA00349B120704013B547096500E0287740277516D72700EA09B57B20532F86
-08A501D1269B057912E75634CE68003E6C009005520079AE3D0C7A044700CE10
-853914944601C6346A00AD4012F71ABD5022742E16E634007A27A412D604FD00
-5E34EF3E0070328428D81248B404DC0F40BC045A1AED22B90436721B41CF0027
-50B7009F3F01CA4838BC27773E12F00453DF12C4006C27501E64FB5723B21FD3
-27881F5A348626116C317E0B8D00EB335924F81F790E5A01FC0BBC520D4C5D26
-6C2900EE04C7266A1F7D42017637C2482A04A00A27E11F9D2E4BD821B627065E
-C62763E459219F00DA4902FD265E05DE3B17D16A257F0B32EA0EB3510C6AC511
-F2005A38611E88217C0154D10C9E09680096561F6C2D80015035D14605641378
-CB01B02F0A73F611792C5A1F8F2F0C98006A0AB55021AD1679385931D806BD78
-11490181327802600CFA04CE0061B701EF1AD625470E9C017B0541AD3AC94922
-86330484B2119B01CC48366A0D9F00D84A14F04F096801D27726508E046110BB
-153C960A49E02F00A70D49067E276D227E275089127F1E5A9B0347A500559E01
-893603A0253D95452FBD15B33D08CA0DAE2640611EE727BF3408F600AE24EE1F
-85127934A552082982155B9D1F3B6803E408D0054EFB1A52E8276101872F6900
-A50C88195C3C00D228BA0DEF123BBE472F6C22961E405A2950016BC46027DA1D
-B96003277E12A1005BF11A48D734821B7712BC501B792D0BB03B22A52792153E
-00F54631A756078001603286019E691F8127AC13F004AE0DC33300E827B3012F
-820C29E2381A782660D21C86015B0A86046C009B502F761A8912BD3F01790D45
-7D2261117708A600BE0AE1003EF95024E30147C400B1401E7E263B77017E3404
-A010D94806E3501FF9023E971F7A256C1B6B275A93007810BA500CE607C104AD
-79164A028507953C1275EB006826DD1F3D710067054AA607940133F906409855
-00860DE9004EBB6A1F05D50040EB2EC11DF712541843F901CF03623A541A6805
-98410B791041FA1CB85E126CC206F30047790DF91FCC2253EA2642E10149F600
-6D0459A11F5CCE02AC30D1385A2A6D265E277E226A00970D8A30127E225AA40D
-64AE129E23C4431F8538199A350E822651B601F20CA5048500C90742E11AA000
-3583277A1F663B0DFE27BB21405A00D234154AB6460E8704C32E22FE1639E624
-41842160DE0327C51F65433184073BB27826861A6C01476D0040CA7708369222
-509B00B334EC561BD44E1FC76A04793600900440591294153BAE2C6B00A6330C
-9105279510399E27DC163DFC042E861778059D01DE0CA0039911D81AB533501D
-EC5907D6043DF10045DE086C015FF3005BBE0154CC04B3126829408B32E4389D
-21AF122F7F2664D704B3003EDA268700521169F10DA626549E076C04D0306113
-A37901955A0060D10EAE00503984053FCD0AB11ADF23510E6B0CCA239B12A929
-8C0427B15B0B7C340EDD177A002F8604A53A0048A00D5AE91FD526B12F50DE01
-5A0897501D7C4936D8521FBA5A077C23B0004F8D4100E6275B26841F6530F43A
-60018F4304CF6C0036A6278D144C871A348427AA1232790D2D8A226C2F427705
-CE096B00590B466204925001EF0A3C5E124A880AAF1B3FA477003A86197F0B2F
-F6209E4E00AF400827D32F11B3340479278F12B91AF25A0170277B049400F92B
-A1045E34D906681AE240002CED1CBF4727A10C48AD13622673E1132BC222467D
-086D008408409C27CF3E12F704B900670B7F0133E913650D95260ABA5011A200
-F7124EC600530BC338570978123DB9630C6D00C73304BC5600E70A4A9721D442
-00F50AA800EC2448A613D71FAF26FE3E1AD3344B8F1A9F30F31D6D0157E5042D
-C81F4AE101C17700633E1A790CF4568B0C45741F86471BED096C24790E2FAF20
-FE125A32AD13821F3EF0005A38BC52106CC67806690486015E37CD0150F6003E
-08875002980134AD1FFE1AC7236C007705AB2E66128527AE22CF6B0050C53549
-EC3A601E71357929AC04429324821FA814FC26A0024E17F82A831B96610D2CA2
-1F3DC6036807A5501A3D62274F91015F2F447D057100865A00790540C4006B0D
-9A27CE33155D920A79043D5D401052BC01E3279934001F63BA07F301C2650147
-DA4B009D6612840046D01B734101C0501A790D9A01269204491255A7264EFB1F
-9021772C107DC46123EE4112D3670C3E5F4701A30FF119604600DB5025EF045A
-3F1C8F2E058600279E06D901C309631F83360ED8046B00702E841FE2279D0147
-08DB243FF76C04639C1B50EE27761179BF03D50D35C01FF80150C717B50E2CA9
-22CD125A29AC400179106A9D0536F927B51BA423D81F3A83126E1B5AABEA0427
-80277818389526601DC83704E3503495016109DD3970038927D12750FD34B81F
-E62F00D633086C00E407B7671A3901A4178633522077B9049D3262385330D621
-9E350D8E174C9D00A80CD55A1FAD681A792786279314D201EC5B279B33E80DB3
-00610E792267BB56127B015018CD400582003D6004DD401F6C23854304950E86
-1B3E613649F2156B2E7F02F80850DF2EA5003FC14E12690078096C0086084FB4
-05CF013C4D934000BD0B5AD80DAF037E0B46A62707BC123EA5287F1649E511AD
-01860967004279018641129540B54927854405DB4B770D5000BE05F400277F12
-E70AC60082046E0957C401793912F327793A01FA4609E200500DF0006B2F5240
-0BB5065A267E203EC65300D90A49009F2EBF0DA54912DD26B21FC32D5900AD0C
-9D00E45A266F27A500EB0499089E01E41B9F228613660948EE1A59009F2FCE26
-EB32B02AFC2340602F87120535E052249332007D1550F727770049892353EE05
-5000B506347A225A12C61A940F50A50C65C227015A1AC90E32992704BA31DE60
-1F842F50D9075A228A1AA71FB627EA143AAA20D15F056C0EA061122C84223FC0
-64204BB402C719792F901CCC01509505308827A427ED1F6C2683340179296C0E
-7E0198147827FD336C2B0BBA01E0137F2676275F32840C3C643F00C71FB53804
-8527DF2086125B04810D64049200EF1A47C59C15620F7401F94122C3340059BF
-22F21179007726C86C2061A30049EB472DA427DD223EF43B176BEF119F045EF3
-0040861B702606B04912931947B53E017A3A5B0D7800865D086F0031B426DE31
-0476CE01B17804339E05387E269F00F8046C123FE31348F41A791271048608D7
-005AFA22AD00F2335038E8078C017B12C9493963335607B80BDC00C82350B904
-D4502779015FA10F6C08760150AA3F1FC627A2206B0E7F005042B400CC2BAA12
-A153056C9E1A3F6306A138D40D5A3D0EF54019D50C6905790062057F005902AF
-0D4586237E391254AF0AFD01A5693700CB043C850068E22704F65026C2331AFB
-268C470A7F0051BE23405A3D1160D6125AFE086B1060224ABA448A0639A40064
-04CE39B4325A1F98390F9015415A0BCC1A5F3F20A52560008305A011D0473564
-217D14780159346C129D25FC1B34CE26AE34F72D00DA4C016D0AC933AE27D91F
-0430792585053B681EDC2C0CD304982F5501672CA80086260185319E1FBB25F8
-35B31FCD269421790036DB01B2781F6C284983240BE774225AF91DC9270D6C9E
-41018805964901A512E7671F993808850DA01BF62A007D3A15A327DF34860968
-003BBD6C1D50B233520E6101E54605BD61046ABC1DA101850DD24D05EA29AE16
-F22793008702A9400D942DF410AD06EA0053089149007C03630B945A119E3CF4
-49137601790B8FF75013E81B4EE20D7801874C336C12E026B01F8615E13250AF
-4D0D6C3D01830A730E5E306C06E12FB7511B6D3108E300C1113CC850280EAD30
-05770C41B149092AD01F6312CA355A3F042CC510F45A1FE5006B0549871FAE55
-047000AA13D127F1105201E92A0B9201FE22931A7B305025EC360083266431B0
-008D41127E21754A04683D22FC1C5AE204AD1D6C277C203DBB6612E54018DB23
-B916367927065A009C26EB205B38670A98013E810048BE4212F100B43D01710B
-FD04416202C50728F704CA59279C26DA04A71285490962049B12CC4927643492
-045D00B56C0160A01F95650022C16C0F3DE550079E00D7794D0086270196492F
-A737B80CE20136D51D88246C01491A9727821260D721406A3C00A80CD1009F0D
-52D51240E512553C1AC05A04D00931C21FDA4F0886003475268600C40B4B9803
-2C86049E522784064AE800C3841AD52E6A0540BA0026CC2753BA179E26601FA4
-277E1F5BA418834A34BD12911B429619654011E50053158929EC0039C327F822
-50007905A50C4FF21F841439EE123FDA023AED794601A178002F7B246C2812B6
-3D1864BB3D12D2037C1F6F265097274F05EC2D84B95A01CF05B046006CB607C7
-5526771B6E1F852E065AAD019B06FA73012F943A508500790D9B4027BB5005D2
-125D3041DD135AD01E3A690DA6003F7D1D690D4061048612A5581B85A401890E
-613A04FC0878015A09E60545CB270097076C27EC6F003BA9007C1B41B73A0176
-1D558F0D79015BAC2BEA3F1FD2253FA306D64C1F9D0050B323530427FC33195A
-BA0EEF1AAB41056CD90656008A27530FF0009E0A6500A55E0D7804470D7C2476
-341A9A2E12791F40F004B337DB01B976223C791F7F270D66E21D00F626B0195A
-00C6126A1A9A4A38F801920585320050BE01F42750CC109A2BA922F13D1FCD36
-02DC0D31791FF204C46C2448CD38B5492788300D61E91F58D600520FC15A22DB
-27AC65086CCF27A50434B025D8350D76159E5A007B016A335A0079277F300786
-11A66B1360D405268504720160FE3A237A1FEA4D09C26922502FCD12F43F26B5
-1BCA1FFA2FA2135CF70458E10086096C335812465E3E00F50949C90057B6223F
-A578470E6337E729467801ED3E00860EA91A5126F6790D6C3E12871A6C3B01D4
-09710150AD00497C2763E5093F6B2950118F005A0E7912D1006BB90147841140
-85219C3105830A710339F5401A6B12FE5A0075074BC800860440B112E0169626
-AB0AC911F4431BD03406BC003E994627B034C80E5100A90C94411EA3330177BC
-0D7934580893004C386B007808DA003EAD153AA126D212AC00FB079E1A852795
-152F9F3808860152072DCD0195048607D9305A0CCB27732265C7004416D625AD
-6000B00DFD4E1F852794136C26FE10AE00>
- >>
-
- /Yellow <<
- /HalftoneType 3
- /Width 167
- /Height 167
- /Thresholds <
-E531A42667F704429C054DEA1F8B27792267D7115D0079C66A05951BDC300F5C
-F90A6504BA50016305FA0C6B029F12E46718D25C017116D9361AE52352F13A13
-DE4027EF44035A0D82015F047722612FF027CC1A37019A08D46C1E55C404A71A
-9B12E61FA22E009D0B3800E10D3A00EA0E67FE05B80ED25505DF00B20CE75320
-7C2D61009804E25026864000B00838C421B300D60A850092045D400C7B2E7711
-9200A10DF40627097901CC0A5030B415359304630CD301FE05349B26EA1A3912
-F926830856BC1F4F38CF29439833852A419835D9275A0427863812A9278200B0
-410196290186500496005F21B526C727AD37F8179D01860B50017FBC5A267923
-41DC00623748D30153357D045CD8216CCD58266CC25A23A40033752184013492
-153F5A276B019E4812A555236E3700A90FDC5F1FFC620B72277A24A626501FBD
-12E85500B8035338DE335A1B96503F1F89279813790062E04027BA452F95164A
-82016C095AAE49005F12A538048F00821A790B26D410A700600D7800C845A200
-794C04F10D6C26784F14AE400EBA2F4DCB19791186007A096E0F5A34E61D40A4
-69164910EC00B205338520F4002677BF124AF5173E8704490890014A07802755
-C6119D274FC0264B9E04D719C03109D13C10F108B5611A7904327E012EA716F6
-0674013EE36600773519992240D0095A01863E00BF6BF20E5301E825CC0F5200
-800774115A39A61BCC29B53E048531C44400E96423DF0DAF00F168014A1FE326
-B71D3D6F0830FC1FC434439E1DCD12F64605D4551F7E123EA505F2324B1FE026
-A1007C0854C3123DE100782F5A1B904F09AE109A6730059E002F84014FFB1EAE
-27F32DAC1FDA043F5F01EA086600F91069386F054D8D5101832779142FED2248
-A112CD4E0050399A2FC96C072DAD25CC640EED61139F27C121E24512290461BA
-3E1B852B7424BD27F31FB300E6077748007B13E02293187E2F5115A22D762688
-371979BC59087B0150F414BA58106B0A7F00603B048A00A2325E00A408FB0158
-386901CF5304632FD723AA310083055937B404CF450EE5276C395008EB40226C
-B112C9263B6A0E7C1A78006C0D8419A2501B7912864829B900AD27F60027DD1D
-BC004489015ACA053B6B1B79D9045A0E501CB5530D7A013F8704278500760D6A
-0570AE50C43A17814E05AA01930B780186346024941236EE20630C7701F30BB3
-0379094C01C41150CB043E15A049319104634001AC249427E712B757276D227B
-19E126772C8622C41A9F0C39921284026A0D5DF527B82092266C1FA13D048600
-CD15A51F5BD50A3D52079800BC40019D12E336B526F60B37B327CD3801951D5E
-0D7F1241A306633250D612AF3E1F6CE40DB82812AB24EB00830439F31FA40B4D
-C5421AF634A51F9B3C00116C049E00E23B12F9325A18C24704D14101BC6A0453
-A93549A2266C1F40CA3AFD622784015C2F76EF0026D8123A9522772DD6015307
-69401AE010CA0B87326A04BF0B65007E265CB200FD20AE27CB3904770C6E01FA
-0A850168BE1A5F2B79037F00459E21DF601A77115BD7233F5609436100488500
-6C0550D80C41ED462FCC77163E990E860239700887003F5B034985006734A121
-CF61006C27E031006CAF086100E8491ADB8F24FC26480D68A14100D838651B79
-0E8433500DC72F00CF062A8700DB68260053129E22F51FB40D2A69AE0552C200
-E8099B123DA430C200960540633D00AF1293203DE4500FED40146C3479066C00
-49971FD1349E125231EF175037F91248E125B42D047B0036B427ED300569B003
-D21AA639CA1FE52F9F176034790186045A0050C404FA2654BB1AF726A0189534
-F41E3EC5136A400C279E1281195C96122E8022933101792C00480860BE781E53
-227D0D9501ED27AE21F91B9F2686411E78E5115A3C057AAD27D3004807810054
-960A348A1F6C401E84275AF30D732077265AAE01EC4B27F7004A850427974903
-CA24B61A50ED26BB113F5600603AAE004897018D079C0032860D65F71B49860D
-7901479F0C336E2778016E0D63047C23F400AF1AC323AB1FE7266A3A1C960C69
-4700602AD7016D099258078901FA794933D401A50843FB4704D30D58C712AF5A
-CD781F4201DC05C315AF2647098F00600679006A08F560015034B315C4400D75
-1F5BBE6C27DB3914E14900F80DA05004C600419801D212FE300D831E9E165A37
-D5136CB80035830A6100860A40620178E40DB224D41F79122EC9254A1FB95605
-C7195034C104E61D55BE1842FC00B210F1229927AD1249098126770D3D6C4008
-9101864B00E2139C36A91250AE24BF122DDF205E3B00B9085A3E22CD270163A7
-2678380684270E3801A412872C6C34500360DA6C1250DE402DD81FA51238BD0E
-91047C4A1AE9019A08350EA61A9E5F0179285A3905DB3D22811C613449840168
-C83757037908A6019E441B5AD71AA52FE327C41FA1324F266C197C048607E960
-056CDB600F3983277901951277278A310062921F7926852F5A06D90154C55C2C
-DB0156F300B86019DC0DBD3A783101DA0786042F7D0045A30150AC127122941B
-EF680472B83A0A8600F34D1DED79B55A27F14C0C9E00F77E1D4B24B93903980B
-4A7D018B5A226C27F92F008E24502BF07850007F0432BD23AF12CA6F1767B410
-E204AD0B27B51F5000DD2FC64022722D0CF3300D75267C105A017A05D909AD01
-F52F5534A64022B314340177EE00A912EA245A00AA0869D23C04C40D4B01C214
-8A3677214613A71F93341180133B9E472D6C0541B961224A1DF9410DE9651E7D
-3805C627E4047F00419F1F5213DC2F5E18963D011249097E0033D31A59270BC8
-00791A842755B01442D12F04E2009F085AD40C61BA043B12CB3E23FA460C8501
-614000882D025A296C1FEF4D04780CA21A6C125DE705BF60006CAD01F80550B4
-3E139524841F7F4915D900660B9300417FBC3F0D642F6C024CD23F22F4125013
-81275AE9601F6C00A50BFD0086036B06C95022D7055A00A722E81F511279B06C
-00619F3204CA0BF359257B125036BD260DE7009D4F02AE4104BD68D127E61FB4
-6C043FBF7746379D0EF205C5003BF0012650AD1D7A31821340A23A126B964802
-AD64096CD61E3AEE26B20BFA47A0009D53009238E349267D07950034860E3890
-1F3E5B1693270069FB2F5A00E936049A0F741FE12758FD0451229A1FD826B338
-0D6C9C01962BE200AE0A4605A432E6267B2A6534E32782380186277926FE0E6A
-018109F0013A26C13D167B48229230008B0162A50A51924B326C3F1B8212D831
-52220088055B3D1298632200A604662F5A3F1F86224F769B12643F0DCB26AC02
-7205DD3F00E831531A9B2D045A9704791F3E6B193AD13F11C34613691BBA28EF
-23BB4F1F52CB04E211BA344AD3790D5003C63F126ACC2945BF3C01790D3A7212
-E0007B04860961A00550346C1A4879209227D1128904470DC6059E0FB21A5BF8
-0DB600951A792FC926922766D1055A0AD701B15A0E6BB41CD62F16FD2901C807
-B10DF5266A00770A986B3045A401E02F06F24927E312AF01CD650DA5093705FC
-00BA58016A1BF149277F1DAF229405E20050B83F14CF0E57C500B20D5A218932
-07AA00750488013D6801FC12792B4766009802233CA61B882260B50B51008108
-5E9C23AE1DC7452CAD35501FFB1A30E215BB04C80732F8016B0279225AB96927
-7E1F5A0197123F6B2A5333C201A10B5000B51144961F84276D3500DC26513F08
-9C43007E471A862360019028A226FA1FB90DCB18712655A1118907508420700A
-43E92768C279206C3A22EC27790033C2014D0A7B10722F841267007B27853208
-79268605F70160DA2256FA3E145AA51892276B00A809D64127EC6D1249DB0677
-0034861DA924F01B40D1066500880B5A06CE5B0084490076275B3AA1511641C2
-4C2FF0004B0CE0003FEF3249D300AE07E4115F3F1662DD401A86012FED00A512
-F941199E04EC60226FAF10D865003ABD4014E00F79043E016127830BB0013879
-23BC3400FE27B131009201481250A0079304860DA65F126CFE5A27D222AB1FC6
-27F822A501E94D1BDF2F6C277F380E8E2F0979D02F0DDF4906B8502278158305
-530BC00038A527E04901F8385A04A3015A3495274AEF1B9E233EB412C926AD0A
-F200690D88255812981E86289C2050AD04850A2F911F64377805F27B2A049B34
-4ECB520D792C6005834B0D6C3B01C205316C203EF35504814D05B334509347E9
-004AFD1F67D40053129546127B1A844E15D22AE7003FDB125230C540089E263E
-049F00600A50019107500C6018943E049F00BF12A44801C15027009E40013486
-1B3EF804AE30C91F8D2761860C79129B2769138C462F7711F902B908396C007D
-046A42066638511FAF23D900B308DD004509CE013D92126127BD52043ECB00A9
-274300C0550EFC0422983E14DB23AE1FC633AB1A851249E1009105780DD51F9E
-2F5D00D71A841F973404862C0D77EE3E01D05A04DF07BB3E770456B01A6036D1
-00621FE25000C7701F49C138EC6A1B6FD938B64800CC5D107D1D5005EB27681A
-AC5F116EC2630CD001613654006F4001F4072FEE1F5004D407B40CDF00BB501F
-74265FAD11D62BF21BA531E9019440057E29603474275EB66C125CF90650DB00
-770EEA5823751E50B7246D1F7727854800BC50036C00750A6400D350348B1FA5
-28CA16356C3E01EB1DA00C3A115807BD4115A85A2605A5611B3294233B6A0026
-A0340E82248718980F85042F7C1236F20E6C044027B10041116C23821334F227
-47D761177A00D60441EC1F4C239A27821FA126E80DB5691DAC59006BB9412F5F
-2178277E1437870DD4002F7B26930F500083116C1AD35A139E0EE604A00F4922
-813417862C1AA446267D15B30DE004813B09D501B20BE1345A20A331CD27F026
-97290BFA02530979225AAE03C05F0D7F2754AD40D66C1262E1003DC850280973
-AD0051B21FF5500ACE4E01F303692BF73748D71FA858009226B67E065A317BB9
-01FD08B4501AA50C78014FA334499831058700F6085A04DB0E791A5A3904923E
-229F36097A00943F01C30566ED00A13948E5046C013DBE5A21CC279C0036FE01
-7826821FF501C605D74800BF6C0537C4014E0789305B12F54C2C941D77268104
-F908790D59017F0644A21F69C53C11ED0040861A39B64501F404850027910232
-860E6C007FDD4113F90E7805468E276820AB274FC0055B00990B83062CB21A4D
-0142D312F40426602E4165028C006B20C92C0AF4260E6EB22A6C1945BF334995
-003FAE12DD500ECF0154E91AC512FC4F33901A512C6016851FA422D079082A86
-03770D53A6206930AD0167385A268C1D98385512FC5E1B6CF1366100AD410097
-06425E00C4109F26921F40BA3A13E25C018638009B6227841250FE006812974C
-2C2152EC1BC55026F520B5163901822B6B26D53104E100780689113D7922B61F
-5132ED6C045DE4770D2E921E763CC900A91FDA243FE83A06926C1F63C400430D
-C8358600770A27C8650181470084277A133386245102970B49CD04B30AC70157
-0C60401E57E00DAA32EE3E05870CCF1950C5069F4100650CEA049E3000922702
-A11FD118792F50BF12E83C1F682D7C00E360006CA83D0FBF4814E54008D104BB
-260A7927DA3E16CE9C0F6F4207AF014061064970C01FA10C8600A7611F3EC551
-1AE800AF400E68CC004526CD124718BE660052A5134B851172055AAF1460B83E
-00AD065526E360017812A522F55A052FF01F28B918FE05B161006CA53B20E512
-317E226E2744F734B105FC003E6F43006614C1274700933312861FF135B85020
-782350B412CE490E6C279D05E11B3B6C0479AF01DE17573D098A1A5022922C05
-965025861F5A316E40B20162088A0131C10096284D8519A334E503503E04CA1A
-4056109D6C0C30A42472135AFA01279E78083985009C3D21EB3401DF0A30E526
-9C350086045312DD277912913A1A9D2EE90494401DB46C085D930677325A400D
-E14312D260006CA4014ADA068F006C1983269A12B31FD5257A016EDD5A22EA44
-006C0B7A032FA400D30A644004793AFA013F65128B01AA500D40600C47B512C5
-28FB04D00065F23D0DB70141A300DF0E7F3D1FC32550055A3B19F70D31D5007A
-11891AF05E236CEB07BB2E00FC5F018627D2093BA26C043EBF6322FC500B8A05
-8646209B5A007E0BD34A2BFB22851A9E01F94A04CC4F14653856007F113EA212
-3BD74600CB1D9D2F0486072FB8401BF412673D14AE27C8005D356B04550E4AB7
-411A4C047D0762B427D1265AE0136B288E17E634B7004AA80DD55327EE3219F8
-26CB3579046C267A126931851253017F1A59F713921A5004E977006BFA8322A9
-65046C9E0C4922AD277900349B012E80154B901935CA0D64008C255016E51050
-01950633D127601AAE6C043FBB295012A30848AA01502F6B3B0DA73F00D506B3
-0FCB2CE3004EC301631A8527780168BD1A4A8F270485369E00C25A22771250E0
-17C127F780015D0DF427AD129D3F117601840E408507AB013C711F4F86122692
-4400820F5C8F057D009522EC1AA400509F0C49C822AE27D4330477263BBB5A2B
-0DB337120ADB0040CA3D1F69EB5A01D10D5AD91247C1013CD805417F1E50E33F
-1BC501AE228627DB1F427F00A40DDB0037F60F6902EE66267D330D77E304B318
-85531F8D277927861F622384331A9E26E804B312F1245336F90062DB470C6C2E
-5001EF08873706900149092FC82292007921D92D05FB39BB1AA60034F62650C9
-009C0831CA660434BB1FA10042B31F4F10AC018533D83F1DEA003578056E0067
-B312D97B002499531B60A271277C115901BB05471286279A3806A96D1D609621
-52EE0D9F28049D5A0C7E345500A80D5AC812692F6C278449237927A34000BE04
-D0551F3F660CD94000EE0B5001FD097801AA0DF95A007C0D3C613F099501810E
-AB135126B904E50F8630A225CD41205DB5764E12792AA5176200508849006130
-46C55E1B791565411AEF53012AE878074A23C82D0A6CD92F5B3853057601AD27
-61B110E1279E1F405E072769F20432E0002F03AC1BE5278325792DC6095001BC
-682900F7320AB6006B3B01B36C0F27F74913EA681A7B01319809EF01B108C001
-CD12581E8B213D6C00B01188315A26AD223BBB621250D04026770440C62A49A0
-17C34E1FD3276D227C0A97195B1F97276C01790468F30D4600D93D01E60850C4
-38B112279E0FE904510B8A01DC04BC296B12A37B0C2760F56C0362E63E018907
-F111BE2E550D930745881A500AED00AD3DC70B3EA86C1345CC396541009C0AF8
-00A41A67FD26521A8C40128649277912D05C1640BD793400960536BC26F5451B
-B326781F502D5B397704D4105DF4138425E800C6057601866B163FB03A046AE0
-15B1226807D9046C00863905A400C431F50043D23E00BD14E61AB33C00952383
-1D61A71F85310D7C016ACE1F85277924D82F9E26590E7A00B9381858BE003914
-861D5022B41C6A27994417F66621D230036BBD365A2B72024F861F5401799E0F
-F508B75326733562279400349210E204CA5401E006AE50052EF200500460C826
-7948096104875000911261E70DA500FE334A98052F9E057839501AA412F54407
-D8007020921D3E5A008612994F33F72744E8611A3E6A045A35860379490B6032
-465A13772AE904BA0A2F6D00E05A22F034045400BF0CA2007F1048AE37FD4920
-68DF043F9F48D90CA5007F054EC7005D0992003679015AFD3E0089049B14FB2F
-00C10DE7471F5A406C3A15DA0EB305DD0F42B8046C402777189E2F5E3D1F9E6F
-1C9225DD2C0BA401DE29A53E14D83749CB043482266A1483013EBC5020CB2701
-9C61277A361A95269F0EEB00B407CA3246EE3C00820EAA02510B78E312B123CA
-1BAB10FD37A300960CD626A91267344AF812A43A048E0A4876E33D196536501F
-EC016C055C0B8D012F86126B04347727CE30FE1239A427DC1F4AC41AA20D5012
-7923E21F6110974722823404B9001ACF0189045E1F7F2250791F49C600B10843
-6900C60CEB0037CE076C12924B1A6C127F00C65B017B0727974100D609AA23DB
-0D6400860A53FC4008DA005CC0045A2F6738552D6C129A015B1FBE26682B9023
-BB264054006C0D7A2763227F1EC9246C03840052A0078702405F15BD4D2FAD25
-069F45F708BA6C148423D61DA833CF5A22F826C15801970F792560860677013E
-81056C27D826C52FA70D3BC04105D451159F6125866B277629A730CD003EA501
-E612782C5B36F91FA7277A238757123CB54200FE39BB521F94112B9E20FB5F17
-B95A1F732F6B1A9027EF193B96122DAE238C2A1049E101AB0B8504F45021D10D
-75099601D6086C019406A12FEC5001DC07B401500554F93E1FCC3218DE276CCA
-01794000DA1A7D395A0027922C043CB650023C6D00500C97007D092FED1F4904
-A80033E91454B726E6129C0082086B0156920079306A01ED0D3BDD0512A51DEC
-126C2659F40C862F5506ED0B9201810D6304BB3204A56101852F5A084201EF34
-4AE40D6A40007E0835AF05E900B449037247B9004A9201460CED731F7C5022DB
-1BA235009027862EE61F791740FA3C1DDA2186053992156B2E40E27912399E50
-058642009C0C3B27FE1BA20E9301D112AE6B025AE27B002779B312EE27B81E49
-38B26C175AC9691FD45A2279320B8A00405D3E1FB027E91A45DF1CB821902A7A
-004D95FE045500850694023B654100A7691C7C22CF2749E4471B6AFA401FE022
-C41AAE7926670583003CAB1DC927F04B168527793211CE3E076931DC1D5EC76B
-3300B805349400662749BD136104AD005134C15F1287570076125CAE2451C600
-9E0A2BAA006912EC22B2621F50B45605782762266F28780A3FD113482262F309
-405107920261E40E50049100460B95410DAE00CF601E6CBC06F95804710F7C34
-0A87014908B11FC4263F5A348F3949E121AF17C212D62604BF345003AC065900
-92085000830D6A0477003FD20EAC19BF5704850A6501953D01C00B419A5113E4
-22A30E80064E03974A2174FA1241C202790840FC3C1666A20D5000B20C36A627
-D63400F50E41831C75461ADB2677017B0D3EF20479219D13C400F405B61FF026
-509E01C50C33961FC76621823400A122D827B226F22F01771A834204F33B247E
-1334CE279600AD5A2668F775146403881900B00DC3092F790D6B2795334E8647
-0E9B62137E21CE30B127D326A2319D27E61C6C38542F771FE12550BC4112D869
-2452F900267A0082046339F71FB31AD23B0D5727841A58D7267F0078C62604EE
-1F802762F107690249851E970432EF00BE600648C14B27C6007E3911D4014F31
-6C385611980086083A6C1AA35A0577002DD410C2572785127708800450C326FA
-3512944F08A701469700491BF84002CD0D460052E34010D07525792762B70045
-EF014008FB0127DD003AF0279F106E0C7C125001F3065A0B8D04B900F8084E01
-9F310D7D2D500F8E055F3ABD2EA72750C9002E870C60017AC604B100F0320E46
-B74C1230924A379B05CE0320409D23C3096638CF5B267E1234921F5813921A5B
-26B950276BEA039F198642346121B412FE52003FDE12A44404694006FB014F39
-E0134789119A014DBE002BD52060DD0C6BB9610631A2279D26C02F06A5602707
-D801F804513686115AB56C1F5EA117B354046D00851CF5013EC15F1F7A34AB20
-6127821564A43F1274F504AD00E427C81884027410F21A3EAD6C2648E9412251
-306C440CA771015D05DF5A00D50B426C2F4979BB0E3E5A2FE200500CB30542E9
-01B004FC0640D9056900900B405F0DDC06C601E248006F3E25BB1F7B3050F726
-9B197C1B5CBB006332C8003C6328841C67A41486301986225012D576125F0484
-127C3950019A4B355B229B1BDB239F1A490090370C7A341AAE22DA39602D4986
-082F9B0FDA004DF00D48C42705D556003E5B22841B7601A327DF1F5F018B0A55
-05D6008209AD01E4129D27501AEB229B341A7727A919E9009F260170FA00A412
-9027841F5AA522653071275AA70E972DE41FAD22BD3D206C26761B9230CC049C
-0D6101B9043C7901DC28A1370D931A822052EB05AF0DE433095401B54105E801
-7A3D004CE74821F300B51AF020C80DAC50126D017E04C927E421CD4800EC680D
-7E4914BC00A51A58D10065227E3905943301863A6C26B21FCF4406B738500C7A
-0652C33F26E2219312621F6C148C295B00CF048D2C771260AE0985015A286A12
-DC5E31158026781FC201F83F008A0ADA0D9E013A6F4415603E0878005AB30080
-0CBB045F1683274AEE471C900D4BAD0B6000D9482FF403A8127927456C044879
-F03A0D6E9E482FA51FC5267900AE306B27790E6700762B00CC31B2395E0E8507
-7701AD2F5605C32702940D6C22EB03387927A412CB5D1ADA5A0EEC018F0A7901
-99345A0EF46320AD300D9750007927A332BC27F64905BE34693C0DB400CF033D
-F52149C90DB535500BC74908D50160103C6B13CC207929831FCC12F600BF0485
-CD27FB1B4C34EB3A532AF04006D6006B097726E8163971278D13AE015B42356C
-00B712CE2EAC002668CC3D0026C00862049F0C501B9A0DDC01A93C8615EA7949
-087812F33244B72C5013861B983350FD4636DA510E6CB412FB01763100982340
-A81B5313FD2F5012EA007D1A3ED100784505CB3B18FB017704860038791F8211
-FE631F4726931F50A204793C0097048A1AA8395433EA47B6049B364F04B20055
-316C472777305001640E8104870E6D019610A55A208E27CA2BA9005ABF11F105
-77248618BF07E02C583F017E115AB9045215FD6C1250F339176CD63F01861841
-5D26049E3F0527E31F540099056710F66204D441008926019609289F4205501E
-86265AB00C6D00782CBD366100C16826A627BB044A8622EC5A126AA90D481CDF
-1257B40BDE019E400079E25A08C2013A6715FD5027E422770083059827006D28
-5908E66C1240F108B404A40CE6179B33A728D123AE26D71F790035B612500183
-0C7A320381216530CF0D6B2750129F05F66825DF341A922781073695270079B7
-3B125FC72254BD09FB405A1FA564006CAF4027DB1A7D0026A54E0BE8125EC61F
-5ABA002673CC4008E0043AF521C70B63049D0E86380884036A12932F09A40033
-86014078C45A267F341A93263D5925A5144D12852F791DD8410686123F670DF3
-27BC1C59AC0DDD16A0253BC460257F1F693557276D09EF00790B600085085A2E
-E269083EFB601FD9239F4937C700A50540FD00B05F1F863B0D8E019A4C00D622
-A64903CA6920540AFA042F810033921FB100D20C34C1280A86044B39C43E733A
-1F79277F053485043079E53C0093561F935111804927E93E1FDD255AD31551E5
-3900FE6C1341B21FDA2D004C079F01D344006AC308D1046C27B900EC0CAC0092
-2658D201B54F1F6A117B013F633084007901520A96013DDE00C405AF50226B14
-9E32F84538BC01501FA379002F95127700E40950841F579D1F803604D85000C4
-1C4809F83E0F6C00DC2E580EE301842677A90DE867066C127B254F921149FD1B
-BA77016108E100C710B31EDE6A12F261145020B21232AD002EA604348401794F
-059400338C1F3FAD601D3DCE6404770B64B512EA2A690D6EEF0F2F7F1F3FF70D
-487B2773225230C40440942C068700CE26EF13C70448FB1FAE27D61FBF5B1282
-1B623F018727DC490466127F17920DCF04255ABD075034AF1B922C0FEB2F0164
-09E671123184275FB26C1760BA269D1A77059F2746B54E003E5A3A22CE2FE001
-3FF2043C830170310DA4238713486A41015A3B009D3E08C001870567EE0E61CD
-1666D51AAD12C44012F75004CB01500C85015025ED279E1A357B228C15B23C1F
-5AA400609801A93306960165F11246A5112455DB38A23275088522981A369112
-4A0086440694264BEC10CE1AA50139C81FAC01F432477440E73D1E6CF4044467
-01B443046DD626AC2A0041B81AED1244269204327C0C3FC4501D8212621ADE11
-B3048D0057166AA31F5DC824A526DE5017EE502BA004FA2F9B17AD4F2085266C
-2ED1401E793801883A00932549009B306A1FA5279823DE27C10E9C065700F349
-04C000435D0692033EF212523B1B68E016BE3F0982005079F400780C5A0445B9
-345000B55A056CEE660E2CFA18B600792F507B0D5A96066C2F415D1AB200277E
-04A000309D1FD23C186BBD3C1A90114A9E79075B037900CD0DE25A01F560003A
-EF01CE069C49276C471ABA409633068400500B69066000864102C20D791C8203
-D14006DA014DF80C5A008E07DF5A1FFB5B0C6CF05A1AD80179095E0D6C00942F
-7C1E40B63C1785395431F51FCC27BB2249AE05D9770050365C209E27DA28033E
-6012B222FE185D01E8690D27D82F043BB779013E6D3A0CBC0027F5341250E900
-C605850E62C1185312C74D0D75025AF900530C7B003EC90A2749D338AB4D1F7E
-41228C2D12B014783E2386320BC300ED2D780C265AD614B528E737B01FBE3312
-98225A36B80C476A1288279610379F22C626A42B0D860527BC183804812649BC
-3BF139B548136B00E360126CA701D80B9E0487006C098501357D0D30BC0FA500
-E504550D6CB41FC62D476A00922779203DC87B00418B1B5A2150AA05D6531A97
-47047FC1270E70209E26ED35056CD8375A22E4298B12338627A523F063216CF4
-006F0B5905973400C0074799216404BA5A00F6632681125001FCAB004C396C0E
-740049840552D30146E9005E29A525F700521BBA5F017E09490150BB34429903
-4877C10D9F055800710B5404F921A93708CD022F72226312772547E34E14D464
-1A9F5A227027841B3CC575300A85057D01D9400FD407AF0053114EB20BCA00E0
-0F65294687390FD0602200783DB449127B00509C270079088600A80AC54907DF
-0140500DA20133931FC021FC26D5611B6CE50141DE324F1A7E38049D0768B43D
-1B0A791FEE01AD22CB122FF42067347D1F9012E2007F1A3DCC770031E32758FE
-79156900E95026E0003F642DE916AE1FC726A128750F5A92265AFB10AE27E634
-B5125B20AD2D00EC4005FD01CA094A872600FA4937E4219D1CA7345086167529
-E51F6B27723F24A400EA1E01FD69053DAF43E1085A02DB4C2AD30A48F227B31B
-63267822973F146CAE04D2195AB6104E2F6A01790D3CA10E512F79088700D70C
-A44A1FD0340D9362C9279D1260305A04935000770CAD08D5046C38550BBD6626
-0C43A51A96123904D7279F0A2F7912921DD012416C2F5A017B078901D93200B9
-053F7F006C0A5A008104950B41864C1292267E123EF501B05A119D0050770B62
-01790546F725A5019709F2029D4B1681276C9E3B2486166C04289622853406A2
-123E9011840150FB3E04D90060BC3B1F7C2788380477EA00AD501D94014AB400
-C612A52273276C22E4400059E30137117F003FA005F93C19D927B93E1F6D2640
-C21A9E3250047BEE600F6C04C0714C1E821262C701B0365E007808AC02DC3747
-EF195024864E1A872050CE1FA926C72FFA2650C70427AE00502FB36320791334
-8625CF122FC026F027C6310D82125836612E5112D13A0ABA034908AF00EF2EB6
-5012F900BD601F6CCB01611FC3310D60A11A850E5000F9084F00E45227148639
-0AC629F01F3E6C1F922AFE0FB5018C096EA8152D865AF43050DA1F771D854707
-7F045FFE00B159067801EA22A8133A01D822872F00A63D01B5451A864906F928
-BB5222821F96112977CA0044EA3B0CE2033585017606690D7900603AD91F6AE2
-0B5400950841DE045207884B0294097E005C9F043DDE00AE06BD6C0061901F3D
-D6601F7F4B0D66007D326C1B3FFD003A26B6400877AC002C6C27E81F9F2460C8
-266B0DBD4706DD61246C118C04E954057A005C35541FBC2A056CC425044307B3
-02950CC900B55A129D471A842F12F326890E74005AB627793F0AF34313E55B2B
-00F231137922840433F60E6800D35C0C38A22704679927794912EF39A31E9E27
-E8169808A10337871DD331C0661B6EBC3E1FED42356612AB1C40C1641A751384
-401FF74401E36A1241C40B37DC26C81F9E098A044F79AD690458DB133553EE06
-9201782C840D379501831A9B3350038500A52F653B12CA2741A615EB3C0060F9
-400151A41B86233A654127683E22E73201C7085094006036B32ED73F094B02C4
-6B1F62870626CF720C50CB00B2104893004EBE315004B963086EBC3E00C50EB7
-305E1648E00149057D2C6C274FB906416E1050009E2F016CA000AD1AD35026E7
-0150089D23FC2704950C349728068B002FA55A0192085E12D627B12E10481BEB
-2F016AC71941AF345512DF01B45A12D72D5600CD12AE1AF64909D400865001DA
-0A6904A1791A501294276AD01153ED00B10DE2018A0A62A32340DE1547D20351
-166C1F84FB5F2705A3013BB26C0E37AB1F6C395A35D81A783A069B1F793419F8
-2153128F1A6000940886003378BA5724C501F01A6026F400AF27E9155FF50E3A
-530D89043380107822DA2F7B0152CE3150C71950B41CF3760428792351AB3E01
-790D66E100820C6FB33E0581005A0EC93F207930049D4806FD67267227793515
-8722AC391A9746319026470EC926AE08DE0034A6047922496C277A1AC6380F6C
-9C013B791CA00CE604AF004612945033D4125100985A058E03EA099D01AA26E1
-5F12EB018C42009C06E02648F74B27D720B46409440F8D139A0D8501974A336B
-0448860528851ADF6A265DF900A3288600AD0C3B87470081057A015E34511A45
-D212EB0027F4491AC101369F27CE22501F9B26E127790462A50C66F03B16863E
-1BB200E2045ABC02405D05F85011BE01D46E3E00842F771F57066B2746C1099E
-043AA70053F100275AAE0D86256A34562A781BAE00EC0D417921FA3117DD2655
-126C27500E8B042F8524A40DD650276C2F8101750AA5023E5122CE1FFE006938
-5A2FDD3D04CB129C380DB34900AE4001C7083F5018D012601A4DC50F25EF12AF
-2DEB0DC500AD67058533A150149D3B22854B1F5B049400FE0A5E12A41FF73200
-C4265200BF4E01960C5137930D2978E00D773F00831F662D0BF2591CD7013F91
-BC13FC016C2A41F65B1F82301977CF082CF9013DC500B407CE4E277D207301C6
-4904AE64003FC630B100F1621F44B4003F582C6B10B200CA12B321531369F30D
-9E016C2F47D61BBD00670E91277A1ED95A22D1345A128E2F9E1FB9680549F737
-92005BA6276726731F6C2678123CB9410E6C077F0062CC05F709AE3E126C2946
-BD3C018309874A1A94128A431FDA2668CB1941E964004C33B61EAA27E805AF78
-3504871160EB22006033A10FD001500DB604D660053E976B1F5B95117A1A3E5F
-01DA083FB92B5D0F86411B79A401831A7A4004D96C1269FD07C101931E792360
-0440D1783200852750AA04870854127822B5195200A530017B0A9204FD247A0D
-70013498206C0440E53D067900D708A002992CF7045A00E020C226E841125530
-6B26E749A70582006AD12F5A12E63D04D12E05790E7F31059D015021C2148C01
-64086D0F8124005AC425A8480A813ED419783D1F882678276E2146AB125000CC
-0A45F22764EE0E9B1AA156149222DF3004E327124B0CD23414962B00C833177E
-205A39F20446E537832605C0471BDF133DC34227A334F640026EEC3F0D6BF91B
-A327781A5000D427E54500C913B3266A1ADA21A3125536E11485227A1F943460
-018E290478A5029800781B3ADC1A9D0F5004B74100A26C2261F235AF01EF5A24
-B90F96076C26F422CF31BA394AE2270C7E002CB51D99055A00E56305C200EA09
-9E002EF71DA622862F00A4053184266E3400F7086C0077A50B4771FE5E2368C0
-0849832250B00041DA1254328908A000F941179B5B00800C5A00E6057E0150CD
-3A0565C222503D00DC0C61C43E16860FA676295301860A95015A33478700593F
-01AF0CCA4913A554106CBC3C1ADC345E0FC201612F43F51F92237E34530BAB01
-50126C394F15812F7927DA2DA7048543005D049012974837F77804504626BA2F
-5012963386145735DB66047C335304BD5A12854100E704BE69274AB6471F5334
-BD023A0590005136F50D9E0361388809A101C60E601A6B12A5560434B327F02B
-862061179E0D5E1AB22A008304BC5F269F30046CB1045A253D09F2601FD42F41
-B515F526B30DCF60266D2F09FC0031DF1F5000924D15D12B407A0DB1046C3B00
-DF07C514FA277C1F9E00C30AA800FC045000860E3B5A129E18FD286802D30856
-123CE127850E7B07CA491A5D3AC40D5012B9490CEA6C1538D621C34A135A3F0C
-94015A0DF0017E199250B51FE7129E015D1BD112ED236626791FAB27E0307B00
-29E86C0777046A11A634DB27792695104BE31AA44008790156EC1F5038F201B8
-79410C9B4F0084046C0A721C814705E300AA79214687059E0DF9260986009F06
-F14E258F13C0502779216A009B09D2305C2285276A1E3EC76F1F60C501E1277A
-490DB450227B1FBE6A00B004EF249E3501FB08AA018E25850036912600B36104
-6F0D792ED21FAE24DD1C86289926EA00391079296C2641BB4A277904A600D136
-50006D03951FC9650F3DCE1FAF25D3067100AE04F901458E093B751FF127BC36
-0B9500771282490527C43412FE22CD38AC00C73C12932A5A3F0466B6183E5A2F
-7544BD276247277712C8003E5F0C940249B94626774A05E63F03DE0CB1631342
-EF063F6C1AAD0034860138A50094300C7834721A6C005AA5266F207917EF2767
-D805429B3D1EFD26A3019205840079376500CB06610E6AD65A05A700DD077300
-922F6C15824812F38418BD0C503F01AE1A5E400084365A27941F406333D22450
-CC005A1184147D4921D926BD2F1AE56C008864077C490D632E5A04F04F1AB412
-D53B016CCF00AE25017C05ED0CB400663449EA1DA929F31F580EEC0138861279
-4A1F92310094092F9022A2510C64CB1DEB6112DA2750F217C801AB28D73F128C
-00D1394C04AE0B5227E1500888005035E31A6032FB4204C15012792FAB1E4925
-CA327C1F4F14FA0EB521E6340186073F5A2D78F71291267F0AFC5314BD01F20A
-56C408A20085056C30B74005DD00AF3D02850DA163042BA72045BC26009E19DC
-249E43007A06864C23F1340D7A1464D73859186C422DD90F8805720068088601
-811A5DC91CAE00C7400551D636BA5300D60432EA4605752B049C48078A01490E
-6041127904E747315F129D5A227F1F95012FCA215EBF12573AB6125522921735
-9E22DE00800695018C0A5AB879264601990950C625AE22DD0545005C35D900A0
-2F0E9422791E8035127C226C12FE1D8802679F23791B67C23254003FD14809EE
-013051EB366B017E0C31BF27E93501811A52B327E9075003C132A30196047A1F
-A226D733B12CCE27B13504842667136CEE125B016C127B19449910279E16BF58
-1A32C31F3B9951FE05B64D2C670AB405F3003FCF01BA1049760D7C34069A0078
-0A8200D30946F4015A129A2BF620601BEE27440164C75B277A1F633B007C1368
-A527B60456401C76CC026031B800DD4801E83AA92D4F0DE7193C5A07F70B4F06
-FA782610995A126CA3045E10C15020F961086D1250BC0E9B006C0A488E1F7811
-831FFC225039E101540E7F1A77126200964912F62DA4023384269F27F624B063
-006CBC01417900F66C0062DE20003A6C3D00C51F7F266C27A81C6B335A39F61A
-AE01EF6727C926F129A12760A60D41B53C04750C3FC13D00820DD31A4B10E100
-B404FC5627BB02376D0E7D19EE6B044D39E40C436815863059196001C35C27AC
-01CB412E98227A1746C96C0139B93F1FD7279B0033860438A4228D04693140D3
-20A43600B327E300540865BA145A32C94000FE093FE5500DD93F0078214FB600
-E207500B850128F91F5435E4123C5012B3440A79A923D91886109900DE0E790C
-8F00E9079E008926543E1A861149026A0D7A0450307C1A63CD27AE50046CB324
-972E7F0492385A146C401A8C125CF31FCC27970132BF11A700861A9E5003AE07
-CF0C97360091126C26890051DA01AC27043BE01D72008E0D801A41E112B75800
-D82EC41FF502604205FB572384143DAA762F0093077C1260AD235AA005278422
-5AB40FD4095A3C1A75BF3549C4400D8F04790864A42486052F88260C7A066427
-F4385131A03AD52E50137C276D1240D100B4045ADB751BC230E920BC01E10840
-006C13E627095301F822B3480D9E2ED408AD01D73E0086064D0DB150267F1F5A
-26D10D38F8278621702749D8254FF10449B71C41860E60B3137F470BFA2E5A01
-CB6605774618830D77005A0D9516862F681ACD044CC6260ED74B22F1279D0138
-92042F78C801A8043766277915A2622B009505269B5031DA20B32E0CD51B6AF0
-03CB941F56BB015A08BE0461015A05C56523DC04BD610C7023922F003CA70684
-006C1285492780FB319D004878D73C18780031F001661B812677491FB0275AE1
-386600DA053EF44201AB620577004AEE01A11B860C349E290D820530E61F3F69
-00A534781AB936501F952F01E7279E2647B44A26DE00BA04A00D3A9601864005
-9F3F007820EB4812DE4E19553D1F6BE706AD00FE4004DD4812F05500CF064A86
-007C4A01A83F12553441EA003D961F85237612FA1F86350DB016593F1E9E32F8
-1247C62254401FCF279F3600B110541A6826A6371269AB0CCC6C1250A64000E8
-2F06850D7900239212841A609E128531501F9A23C7126B420E6204BD60186BED
-36C559007B04F05311C7036A0C9E00EF09B3791D5101FE1B6C01832A78123E71
-47E9275212F85A1A69AE11610A83286C00B408FA791130821C8A4C0D851A7A39
-5F1F781280183DC715EE335B0075B5011E4D8A1249E50D40CE2C46AD00499500
-3DA101E7098401A464089001FA770F5004EE6D1F7801BC0AD84C049200405A3E
-1F862704C156126BC339EB31BA5004FA27B32F007409C500E60D50329D05BE2F
-E2395000D30950007615A326913C22842649E347277C235B3C0F6AC541129F0B
-D113A22250F334007907C76B002DC40436D527B300C60D8B22763100A04901C3
-3D20CE27B201CA0CAB279F2CFB016040059D26D01A2980A30927D22F00A05A01
-84096827EC264FFC1F792768286C203FE412603A0567B82F590B50DB33418E3B
-15F21FBE26E501B605DE5E0D3490045001630A459A3F1E791350E335A4207A27
-6AD7015B3E17730079229427A527BC1F500DCE4A07D901AF0A6001D0064ABC00
-DF3F047E385833653F08C801600CB819603E21B17712488501941E65335638EA
-0FBD5025D8275A0A7C006A0F5A239200DD047526901FBA6C0F85074EFC0433C2
-5303A76B1B3DB122E21A9E3A0A8D045C0DBF00D806B800572FAE189F3E017916
-AC280398066000862E66057E10772B943D1A76F61FAA259E1CC82701D76900C9
-0B5701644008BB0441A71FF7850CB51AFB10780182083EFD6803309D12502D79
-16A31C92146C325A17AD0DE200AF05EE5A27841F954D2FDC007E0D5034E81B6C
-0B4FF504A3016142068E01407412EC29A433E6277F1377365012AE0D53002DE0
-213C94125E01690F7C3705F611783F00790660BA412ECE453496127926861A78
-02D74924E321C400884622EC1FC55004A15523AD49086200A54000680DDD2779
-00865A123596277925B712FD5A26872F0B7900265A308A015A3AE21248860127
-C26E2160BB00F350266D2FFC0D9E0179268622811D7A27029D12E541018A12A0
-27F6068E00AC27D8390E8222CD159A274CF11FAF520369086D01A505F7481ABF
-62013BE77B470167C10044D97722F01FB8492A6004C05027D91E500086027D08
-564837EB0CCF269A3300860894345310CC600D7C2712DA3E12EB0033FA26C750
-09CF2D84045115FE3406B84A08EA0192056D3300A51161C836B33FDF056335AE
-065734D01AB2553900F41A406B3B08D50485005721D02AF3016030D90F50C335
-7A0029CD206C04501AA5235C0D7F005BB61A502F6A04D73409850036D227C01F
-8A22743009850041D070260EAB7813532FA017BC50006F0C8700D633640D8601
-7111E617AC22F61FB4145F45007C1061F5136A4004F8691F3EB3004895580088
-3950791A860E2F892197135FB53E0E619D1F772C5B3948DC1D9D461AE8015004
-6C0F4AA012CD22941D7B00772A04985A0D810496138627AA1F40AF3D0C6C1F50
-BB0548A600770A44B5670554ED37B562024ACD46259F2E046CE400B13F126CB9
-1549791A860E5937CD005BB725EE1B3706B5400428F2027E073E0D2F9E26E21F
-7D129E20F027C335A227783061006C0480059D354FBF042754C91AA927099E01
-7734F70D2FC1270BA206BD0149EC124702F3390078CC033CF100C51BAD0E297E
-04CA58269D1FF52298003E6B004F03F527A4145EEC1134A525E627B500530B60
-DB0465A3008C113D8F15396A1FF726521B933109840027E4137601FB124EC73E
-127B1A5DA100572EF605B4003FFC0441971745970568AD5A196CD34D1AA622E6
-6079CD0A5001AE3A5A054B00930979005B05D111AE2DDC27C41CF2083DA57712
-417E00844931E2126B044A841A53D0412761387E006BB65A26A3224627941949
-7F106B006FBF0C673A12792D810D612FC31AEC2AB55E116C04D843226AD20550
-00791E3FEB78123A861230C627E70052FB04CC3B00A304E00EB14915D3437B38
-0CA43288016606A924F70134E11F9D12602F4A7817830C4EE801337A104901FD
-2F00833F0D8F270034126597365515FE38B46B146329F7269D387724800F5A00
-712786194800E7063ADC11B7005A39A529D5089E026A00E311B21FCA234D017E
-0667E00050BB05309127F7381A50F000AF08D9004FD513498508790C338D2684
-3807A6012F6DB83D12C867012EC3014BF1600475249A1F3F83185C8B216C2D74
-0085355B123EC0511F6926E91F7930620D864E087E013CAD0BDC01B823D62812
-61C41FE0277E0D5AAF12C75C0447B158F40027D504A3087E022FD21FAC128401
-5A08EE0140953E0DAE01DA6C2751971E50711A790DCD017F1F6A27FC21721786
-045A07970FE419C33B0C85310D66D501A4095AB1043E83226C27A138057A0138
-A92650CA01E40E63C012489E0E266A920527A3501B96270041B20E4809C5014F
-BC0641D70CAD25FD1BBB019E076B04DB00790940CF00B64021C52741CB6B267F
-1F9432500079B03D046C00A226C31F3C6A0126F86C1A083FA54F1D70276B26C7
-520183044E1FDE2AA61F50BC19FE54217E340BC60147C4032EFD279F205011AC
-007A0C50A83A5630F636446D2C416C1FB214EA78223E5822851234991F49E201
-881A68B121EF5704DE006C3F1C98005333E10059F80841DD4A0EF94409B9781A
-2A7DD65F27790D2E961235870148107A276A27F123A92B9C14BA5A1250269703
-5393105800EA053E5C0DA46708520E932F860B56019A08E5439F3D01C593265E
-058800DF109F1940EC3642C6650C6D008535047A012FCD0443862276300D9C43
-01860765F04032DD1F962E04CE009D0AA700D505A2008F045A4000BF04ED4600
-D95201D0063F600DF90231841228861F9F13BC4D2EFB19861F79391A99280085
-3C018C345107E266054B019222E64804F0501F6CBE5500DA0C99004F0E77258D
-340176F10549DE3300FB229F1C50C000F61A40C81FF326CF183EEB412285290F
-7013862200B50DEC24AA346000790B5B0E930030A026BE12D15A27B569135BF2
-00AF0FF0611ABD5A24C8360085055F4701E74F2277126C27821F5C12F94733D8
-26961F6C128E30631F77289312BE4F255AC7005FD30D405A3B019205487803A9
-06BF4902CC681FC16017D320A03512B422F311A50086336101CF073917A22F6E
-1E3DC15F01F50452D63719802C0C8649286C09468612992687016C3B007804B1
-5F126CD10050BC00D530614C1B782D6C138622F82FB527D82453F4035E0A7946
-1A950D389907297826823400913D0A79044EB412CF18B8346109B02AE021BE0D
-3F8734540B84016D0952A83E07B903F40DB5267F0034A10740A63E046CB806F2
-6423C50D37D12661128035500C9A04317A006C035695007A3159396812C7259E
-2759F567088804E779122F861A7F220A60AF00CB5E1FBD0DB339D30440663A0A
-E327AE5A208C34009F062D7F1F67385206E138CA048401D1094A0490069B0482
-0B3A9927E13405ED0042E61FC3490CDB014AD35012ED27A1225B30446C019326
-791D8503490060ED01B717C822B01AFD2A01D35026782D8600511AEF6C12DD23
-6A1E9E2C1B7F123074159D5A007B27E700AD15F42759DF0DAE2BFD233ECF4402
-BA08DB50006F0B7D004926C51F5640005ADB07B239C178270F9339069D013F75
-00612EF100C5501B7F1247E10C54F52261B80CFB04A41B81126B1F47B9492768
-BA6C1C5A336B1FC360117E00A56422886605790092395E2DAB05277A006C0CE3
-01AD08FA3D0DC400F40F55D2793113952769007A2F5C0E9E3968149D1DC7163F
-D465052B9600770AFE0050E10149A700DD4322F012941B67256E067F01388626
-770B9114601F8627751936B21FE113A51A86013FAA26CA1F3F6A26005A04E150
-1C6AF32764E8139D268F117919853E00BB0532A71D3F93013E57338927E901AD
-00FA0D5A1AF1004412CC26E800A83801D8223E5213B92C12A632601AB208850E
-40A31BCB36981C7C27661F854B145A38A53F2606AC43047E24EE4802D7470078
-0AE80060054A85013AB355193DB8304A87156137CD2286340490085033B304D5
-2EA81FBE4D12E81A6300EB05B10CE601A55A05813A5A2FCF0E5CEF05790A8401
-A148EC40257B00BA3101861A3B5107DD015A26AC03D85F228666017F084BDA11
-9F005A0A693550782F7C0197103B8A3F017E0D7014578F1A6AF908780448DD4B
-03F95000E21F58FB04894A01603E05CC00A50BDA2F9D046B00BA651A5ADA0F9F
-08378B1FA625C2344E3BAC38FA0C9E1F790DE950017F0F41AE098302690A5AB5
-2761CD016C3E0D8E00405F0979003CBB462F6C375A20843212F84908940042AD
-3C22691B9C31FD3B13700EA52F6012974711C502B56B1E49C24412793A07FD48
-12D426C0142F6E26DF1FB212C62208A224CF2752BD06E35020B32EFC0943B500
-5029CB369B00278812387727A438156D3012B325F5571F71297E006A26EB1878
-0D2EFD0036721E5AAD117706407D11CD087A016C2746E000406B1FC522DB042F
-EF26AC1FF83F00790C409C11FE501A6BED22C826AC5112811DCF009E4104C46C
-0027B722EB0C76038600DF4A0C5A009605CD4B0BFA4005D75A277A2241A30A6C
-05ED4A1F952D009B35530077AA0186063F733B0395DA13760582016C3913953E
-00842678043397248201720E5AAD0B6AC31A931163BD00D86204770D40AE0FE9
-2250C0065934D741801078B203D04000E1275AF7016B275A15C11BB4125B2FAB
-0189085B34A352006E0C7B4A12C329E620542F7404C1350183053E6C01DE049A
-0E5018FB27501B9861017F33651FD227A43614B727C422643E1BAD0085355000
-AC08FE0034E424863501CE0D67B84104ED691A40F3124D9D00F05A27005C34B0
-12E91DA44805C6611FA012CF500DE315B01BF03C1FD72C075401D00A2F841F3D
-E11A8600683F01AA123D8112A32401C4511F502F6326861A96042750AE04EA43
-2D650085089117D3263C930062129827CE320086266C04A500C91F86264EB312
-4AF81F9E263A5A27AA7301790DE13812DA4812B250076B108C6100790850E701
-8B266817E21F82306E155C99125000B161277B24551E92310EBD235B2CD41663
-410C863EF71A46602A5000F430530EE2023D6C1D8A015B2F416C0186044979EC
-3E227E4906B700459F2DD619BE4B347301CE4900649827049E0AF101B5056133
-BB761237801F8702DD4D22F336580450F612BC27E31A460577EC199E12813964
-0D5A00E118683192005C1179BD00F2063057BC4002A3772909870135BE27F404
-38D928AD1F3A6C12D2279B03A00ECE22B42A0168C72D510BA104EA01C6084986
-047900A50939B626C620AD049A00D70BB2641A880079274EB900EC30479D0ACF
-12BC5031A400265FAE01F6275090155A026C3B089904F12F5F1AF733076CE338
-6B137D1B4BE60B5000EE6000C40F406F05974900C1781E6940066F017ABC6020
-3D5A01DA4805F535B54010A001D90D3DC5500740651349D70F248A2E520460C3
-21FD5A006D19B054026C0D9400B75001730A5A2F7901500479D93E069D15F22F
-8C123F7827DB1A3CCE411E6B89017A055015582E6C219233047927D9229D1763
-365912C41F7300613F0DFD17418F053B69129A340DED23AF0CFE54268421A700
-7D2648BA114F00C05127D4391483269A2F12935033A51FBA301286280CA001CB
-39AF480E4C00D406B74C2F1DAD166D07945A27772160A4042AE51FA334850096
-4700C61FEE41007E3E1B850D924122851FF73060401AF134BD25F51A62EA390C
-531A81226D01772150B40B6B00A55A0764FC043EDC1A478E3AE112B6400152CE
-12A40A6701F80CA6077E003BF6279E1C840162CA20E017B95300D44901644128
-7900D10E6C143FC50C751A8B26943204850069B001C6074DCC2709FB016B0B60
-D20447E24B2F6C0D5A26FA1B974F2A6D129569008524DC3303F00BB9451A6C8F
-00750CCA1A6927F16014790827B44E0CA727D93401E409A54506C9048B277A0D
-85009140116CB226FA00CC36AE0DD100602EF94F112F91203B95135E2FE902A1
-0079076AFE0E39712749BB472A6D27D622B168115004DD26AE47096C00844126
-791F8931CB12BA1A4F389C02E1500558E83D01DB0C5DF422AA1236791F408801
-4983269D27E91F5035A90026B319EB009E046C3B0BA400FC0A38D62760007946
-1B833100F20A36D02386013CB504410AA836CE7B112FE1005E06A06526795012
-92236A0FB4004815C02A04A54701840D5A4616613F26991F86023479E500B20D
-4CC3007F0D6626861FC73C2261B404ED00560883008D045A400379B73E147935
-129E27BE3202E5079F0B6C04780065A1065A31791FB22B04A56028AC1F3F5008
-56FA0459E7133CDA00660C7D009507771A86600985277F1F50B526E81C6422AF
-47059612A51FC65A019E6622AD5611502CF666126E9E2E6C005103469D1A4089
-2B5012C5002BD4003BE83E1F6CDA602255D73B19CD41319904BA00E84C05DA0D
-5CC906276E247901329F1FB845D209405500930132861F9F12DB1BC7143DA41E
-E42C006AC7015AE8007C0C50A4125739FA20AE27EF3513DF26BB016A1288394E
-0B79008605CC782C1A9E2F0D64A11AAD21C6384F23C227FE0D38D9014412E033
-0985013E9A500479304EEA0B8D0427D23A0F862F0479B8004605D93F00E423B1
-1CFA6C0563B510EC017A374886185F9F025AA4054E01A0097800935012E11F78
-27741B833D23A5381950B812D127F55A10723401126CF026A81AE55A086C2E7B
-2496334CF10D7E085A9F0E31931F406722F41E6035AE004983065A0C7B450080
-103EF35000CE18FC23C5126C2600B461006DBA032C79053F6C04D75A00910442
-971F5ABE67006BC52057D00D29E21FBE01266336497D0851E00061FE3F1C6CAC
-27592086145A07663E22CB3200762152AE04F90AB1441C810C32C212EE336920
-F82E078600A309F10EA501C150006C9800693E01860540CB04ED60AC3304770C
-7B461FD726BF013F610487006426D01F3FEE5008B803CF4D049B00CE23861238
-D627AA1FC45B1FA46108229F276C017E3048E53C93153BD140225AF51267E61B
-A12D11821658D30079114922AB3602792F0460A80086107041B200FA13B41F38
-AE165001CC09347E0DC0043CCA31A001840B50F113BC340E77246C2F01CB27FC
-4926954000BC530C6CB7233C6B48275A43336B1FF71335EB1F9E501AAF15782B
-50220058B31BD130059800830D50F70DBC1A45AE3B058F016021782A81153379
-2784176504C660006D04860534E7002FD3783A07A8530F9400600D46EF06790A
-9201358D2700520E64F332B83E1FA426F804950B5AF112B37418427F2254EE06
-2D77226901925B057F2695214DE80199275B93017917DC29AE1E793D015BDC1A
-A704E4790E50008606601A862712A1340152D604B100C30BDF049508AD590449
-0EDC2F476500A10C82FB12376E0050BD395A34A5186C2C5634DE12774E2FCA12
-AD00F80B5AB20EDA063FF22F4E1BB516F72C4883125698260150E9401DD627AF
-20C2015A2E47E11EA54F07B541CD7B0150086C017D0F6C2E8327CF1F3F82003A
-F4053BD3003A79CA0DAB27DA3412ED2ABE073D8612601EFB1241E9274C0D9200
-6B06AF802700922C5A3D1561BA6C12D030E4054DDF0449EF12602F406E1E862A
-62277B301279B45D008108F43B1FC8270746DB1F9F25610FFA0149CD04A20084
-089E01FB0C4885276C269539006C215A9D0CA5017930415D11CB01B1400D6CBC
-126300860A50047928891FBD00693D0ED9246C04263DAA1F9D22EC31C700B208
-5B0090064FD51D50960D509F1248015919810A54A700791255DA0041A63B0082
-0B6E00B95A223FCE26450AC8683909C400AD40033A9A43016C38961C3E801F79
-069F10FD3B01B40DE60146D227053DBE229912AB57016E9E5E01850DEC049022
-791240631FE7276C237E1A983802E20DC20449F027BB0134732652E1089E0192
-4C27691AF904379B27CA213EF06612DD056C118613B549009D38FA77124ADB00
-3F5A0446601543E73B26BC1247930131B4271A6ABA26E83F00C11C406B24A303
-6527D10468C325AE1F3E7F04F9500262EA225116F77B48277F1FED22581FA513
-C5005BC901B027CD206C047C5022821A5AA00060EF1B6C39046F40218B271A3E
-B92E52366A15AD29DD059C3D0AAA01C4345200BC5A1F405D2F781A861243E400
-C4053E6927DB3E0AEB00792E4980006D0557B300309E26A534FE25600279315C
-0B5000C30A2F69BE17A521DC34790D9D6401792C12E45A0076F7013384129B5D
-26830CD4501AF82F760C8A1847790459D4123A761F8E1A3D79049D01350DDD04
-650C9E01F6086125790B2F920D5A008528A41ACF4100BC3F0E84330A9E01E049
-C301E80AD085007606D500BC41006C26821BC64A125F4304E86A270679A800D9
-08B30150831A67237B1AAC00761F852650AB05C612E31F8E3411844B087A005A
-0CA027CB1FF01BB7278A27609A0627850E6C059401BF1A41FB19AF6B0827C035
-0B46A4076C0432F7019E3B008F4812B95223EE0133E52C0550B500D80CAF00C0
-4A246BB56D2250BC47276F347C298D19F5571A3AE83F12D900490895326C25FB
-16B344782C5B173C6A2F501127F5225A12831D5AF20EB20050039732F31FA027
-0A77D33412851F9A3240DA04A327970DEB335A0FB401BE0B3471236128AD0CFB
-601EE2401FD1277601800996057F006C0DED0436E24900F639B3275E24880C35
-80003FD964046CD05A1BDC23C47915405A22AE2F068600319E115EB01B6A9E1A
-6C2753346C275C12D5083A00A0077900D70DB000DB0EAB4700C66C07639E235C
-F06A1FDE03A1073E692600CC0C8D00A605BB6295093CAD4026A10B337E1F3DEE
-68217900851061B53E0051FE01475B0C7D247512F8005B4414D1482F632079DE
-009E088B015A3D039201B25A04AD19E93343623B25D532A21F4B75128634560A
-7300F24703CF5E1FC9245014AE420E278600543D0063B504E31151D0364AE101
-783908860035F20DA3019908EF049E2750E24829F312661F83276B1F75042C9F
-4013AE3101860C3801860F4C215FC004F14F1FA427FE2686360215497901E564
-01CC5001C3602707D40D5B38D9015012921B642CC126EC00B507574636C30298
-08A004FC501540572FF21545CB22AA27771337850D40561BB901E15A1984013F
-AB00C21AAF24CB1F5012A22F5200860977048F2F0079BE1240A01FF1290E701B
-8501660A971F8526D94912C944045A3ADF12562F7540008611931A5A35C15301
-EB06A737D36404268A00F95027C850B6275AC579002F94128641016112791A4E
-E02FC91F9B1231851A38982D0476A5422DBE19488721F027AF056F108A1B774B
-34CE18861F6C297A1C6C3B00C806B10E69387E1A6C10DB0749F72366D700A00E
-6C4004940B50D01479297F016A057CB53C047B12EE32A927EA2160FD3D0260EC
-056C098841C84927EA26B2135905A9008B28509A26C5185F38C31BB612FD3263
-01AB0A8B042F94223F5A01501279E24E266911A7043A0A99003913E34A266A05
-DE30BF5307D100699F007F0655B00D5FE81459DD1150008A019A062FAD047E0D
-3CE74404BD3E0F86056A01A50DF30040D7109527741F8900D505A400864F2F92
-009805347D2250C815AD29F722633B05FC0D4AD8462C0067DF20AC26750E8001
-990D501F9333168826A834046B009A0C7B003CF53E126F1EFE01306D00840992
-0369005D4606CA374AD01844E5104CB40CFE1BB5430C34AA05791D71E3601FF6
-486E0BA501CE511F7D0D369722820F385727FA3C00D23F07780040791AF52254
-35E369165328C8600085305A01F522AE27E6306322B15A227E26BC01F04B3161
-2747EA3D01BF0F681BBC5E03F92F0083236A127C00A35727A61F5A0FEF770C34
-92004705C61A5037B300D807B84900D10D4EE225B71F5A34C06C1A60C9259412
-62D20DAC2DF61F4CE730A41F772285002B61A4003B851F772781310072C41F49
-D841004D127A2F05B929416C3A10B50046E8015028ED08B60D731A8D4D208C27
-AD1FBF3D0A6CCC0E500079DF013F1AB322D5149E3278007B099304863E05A701
-500D663F04A012C21758267C1F3FF12D50129D1A90480DE601B230DD40107700
-8C0484193EBB501C66D7582269DC12456B26771E7C385A2C9400600845FC0450
-0A8F01503F00B34321792662017B37067A0DDD01AF12F476052750BC05DC009B
-0D60EA3E0882005A23B228D001AD591A8009ED0387269962126CB7045D862266
-01C04105A501FD0C6C0362A82F04821FA538126C964C086800486B0B41DA1250
-1FCD4A11ED1960E435AD24DB1F79009509B204D35B007908CF375A06B83E7038
-550A5D01C41AE034B525C8015A04FD0D49018730009E08C33F04E50CAC01F812
-3ECB3181129420DE29AE0DDD7132049F01E3159823AD5A1A9527822F6B1F3EC7
-7F146B27406318C904511A9D27EF0E7C068B16843500D9269E206618F93204C6
-24419C1F013FE22F5A12EA257B339D23D5270042B326F90C59C4270DFB2EA838
-E104BC1D5A35BC61002DA3268D3304821A860B5539FD2F84216C330CA5278649
-00ED27792604CC1F9D277622854912653F0D9A2184289F27B615F25A27791B5A
-90226627851F4FA21A6D00AA2F6400771B812E0960EC1358346B0AD80040C500
-4F0ABF049A005508FB01A50AB849288E25D101601B9F30F4224708EC69117600
-3CB3400079471B8F0031D752A51D94047E2960126C00850D4FEC771251028831
-009E420074107D1A99269200810D3DFE77086A00B54B11CF0045BC0E600148ED
-009C451AE5043196126B00DC50117D00EC07B138049E00E95827D3126C00710A
-7A4111C505F90131B401CE073A7901880FD94104C65027EF0349BA1F5038C20E
-B550287F1F6935EC5F154926D61F7832436E2F5A06F4006B1241B83C0070035A
-C2631F3FA82EC854055CAB0DDE5A0BF360120778003AD021AE00C92BE4433591
-240568B63E19D86C1260B920CF015E2F5012EE279F04511444DB481E802B5A38
-75019627B71236701FC3591262CD1F4CBE451C863442A91A84125AF82A6C2408
-8600A538E31FC33001943463219A4F157E2859B80DEC492D5A228536069D1040
-8600790586007C3F01A205F00CA7042978E6600D3EAD11C500E11F862649C036
-7A056CD31A860F4A01920C56017B0FE43B2585153485263EBC2D47F650097516
-83490B5A04C00148CE2901975C0627EA3505852750F500D065056E1ACC27AE01
-5A0CC601F908AC25EB1A7E0564C80D7B013CAF40017905600AAF06F601603249
-C800500DB140C546325F164A8D0450D74A0086470DDF3F09F30040693C04B301
-F51760D61F5AB512F827BC22DA4A1BF9125A26841F569D0F3B01B552007B2766
-0E7802A30B7601FC510E33AE27E026B327CE24FC48266C04C40066D604AD006C
-CD0E2685314AF20539BA26951F5FA60940F21F3CBD5001864913A40E39920C3F
-B835860070257A1F8E3260207A148504552FDE4001A128F6086C0DA32DFB2692
-297220790DE2012C7D268E35057802F20CB2013F26A50627E71FB13900659726
-7613D41A94236D0DA601398F00347822840C7730049E243C8A4600D63F01C66E
-238027E3129E1A9939D02F5515AC3E21A545047B006B087700810634BB12781F
-A22C0E501C7B140163B000C20427A063016F0EF82F136B8B0C7A00781EB022DE
-4003C9611F79235A0147E411BF04F04C05983E00C94935A5125D267F226A1691
-24D82087005A0EDA0350BD3D1F6CAE09D4015EE513691F84276AFA6D12659E0A
-420379D03C12C3049F275B08CD338A2778480DE46704C9015019AE6C1261CB01
-B7336417853105FA4B02614104F148006307E9345D0C8E00E761129C32F8379E
-1F53A20041F150074072B838FD49953719791F68931133E027860144D70032A5
-25D21164097A0077345006B401FA0EA51C5D3442953C1ABF22E0620D27D80077
-0AB206E300B5375400791447BA4A259F3000649E053E6222991E502FBA5200D0
-083900BF34165DBB6C1A52047822823900A550126A00E908BF264F1C92263FF0
-5D003DE60627790E9504F422AD44112FA81FCD355A21BC27871A7901D827791F
-3CD5431A6C124BD50E612F8A012779EB0055026B2504E75A0DDA3D00D05613A5
-1B507D1F59E4046C2849FB472AA217F022952769308327C906A100570977006B
-0F41B4701B4CF2471F8534445C04F0314ED0086C01820B6AF11245D116FD510C
-BF0092053F9E1A488B4F1B79F0004D11FC26AE2CE20D50F83E02DE26831F962F
-7401AD095AA20E33CC0B4D93411AE0264B0D790067BB6D0D6C0882018F0B5700
-AD2495125A05BA01590AC104B4003DAC05DC1A60C93C1A9E14D50DB58629009B
-4F228747077F003EC705AF0B38851BBA015705D7266B0D7F00D41AAE00501488
-26F61FD227A52F9E0439019D0C6204C55010D20C862698023BA51DED27C61836
-87042982003773277C22F112752FAC12E03D042997228600610B7A01A9187120
-7E2FAD045C4100FD5722E12E00659B1F852D00C3500077B35D27D4193E00EC22
-AF28DB1D3DF94012CC2A47EF491280269422652F86196B274994095104772280
-30541F0746C64008FC0235B826EB61177126469D006B0D812397128601AB385B
-127B0C3DE86C016A2B7B0E9204E6266CFC5827C221773E008D27A91A6812E722
-6342095A0049AE1F60B80E4AC801DF075A346400E90A6C0160C8500ECD2748BE
-4A1F91355A01BD0E901E50CA12A71A367C146CD03E056E11FC5E13A43A124701
-94064A8827508C01720FA26A049360047F006A25A031F70050E1074DEF029E01
-36B026E512C14000A666D9781227861CA9640B760436B500FE6221C927EF32B2
-006130C54205E25026C562042FD810B20050355A12851A491186003C9E1AFA24
-790150C63D059500C033A039790DE1005034861A991246AE04A3401F7927932F
-078540019D087504EE4312E32D613F00F10A3D6C0749C7009C045122E427A602
-3482056AED1FC65033E304BF3612C826490039C43B26DE1EB30DC701631F7C39
-1298253E7013F9670D7400844F0CF3431330016ABB005A4021DC2799490E863E
-04AF075A12781F50E70D5A208F34008608489F411B822363EB18AE4000B605D0
-1E5AE7016A065714E22F00AC5A2677197F02D90592269D12F1043C592F7E22D5
-1B5AC001DA10B63F14EC6023DE1C3A6600B0087705D069278622D8309F125038
-B70F8A00801C4EAE21D427047B3C0F9C0C62167941077EE879245A0D86085377
-3D19850EAA05CC5A00C50DB431501EC727B2341B992D04915AED1A5034E20D7D
-005F08F22C5A1A921242933B02D3083E7700F61166BA1EF8270EBF5A03CE3307
-6D01CB5A277931A5084E2DA736BC40099D6D0E40CE0DFE27702260186C317826
-6BB900F60A9F00770C37812564006CA30434861250C4217F27539E255012B301
-61047E0069ED1E603046C00C41DC006B0B49B85000FA268428A400FE5D1F4F05
-B101F21FA63704FA502CDA27781B34862064048400880A630547DE0160BE220C
-3E9A0575049414C8329E15A900D3502FE100BE6027A515B750279D04513E0199
-6F003AA50C499D21863B0AF30167257F1FD30E7700875F381BF420613E01A412
-B82DF803CC00A70940621B782A8626FC4F05B01AF4431E57D5003E79019405D8
-0F40FE02921A51E43E1FBF2D01A508F601673479123D9F318B122A861A5300D8
-23912D03A5106C1A406C4600C32667008B09950051F50645E22A40D72157EE26
-78127D390685CB004AD226AD2D782384016B227934017F1A78470C8800693A04
-851ADD25B06C1240F015662C7900F54C1C91229E12EB00AD046526F32701D556
-008507B649325A00940D4E295C1FE021A33E01DC0F49019832497C0B35C00D27
-68B50DF62F5A1AA5002F7927C3330C97530E8B421479279416EB04B75908F100
-40DB0568BB4013770B50C0412FD935CC129C2C508313AF225C34BD136A289301
-AD10509B013E9000A525FB541927863812861DF401500CE42ECD054BEF26A010
-2FFA1F40EC1ACD325F077F002FD21F4F8804E012AD3D0DC200502F6C3A56348B
-1A9A114CB11233A6276C158E05E03E2067AA06864001790CCD56276AB85A14E3
-00299A5B00739E193B854513AE374C70CD0A63007A4701F53D05D15223C80649
-24912F18812260991FA534016CB004E01C630085067D004C0BE0033FD20645EC
-02407901B90D4D1A850434C6124DD4196C0036A3730EF85D006C1059B93C1B7F
-12408F0A6400BA6C045A99017A4900AD4512C2600D7E013EB3274561047D2762
-E103AE0CC90643DF0141830541920BC801EA28691078C6013DE712BD50269334
-0690004609832666CF0627FA4704E40959009504E8260645A218F110B6264B9A
-276C00841A60AF6F005CD201BD4601710956EE1B3D5A31790DF3169F225CB968
-1F98125A33A5176D0DDF3A1F77E86126FE48278C043B990ABB610222A90130C4
-27AD3404649F025AC41A3CD7355022CE340AB42B128C26EB3654049E22DD265B
-00951AE5249E0F4186226A277B136030C41F64E7196B227A4F00BF561B46851A
-5A34690EEB005BC01CEF27C71AB3043DA36C12318F27A71FCB26791960B71234
-8427861D793400DC12B230E7013912F61A39790F2DF827C7122E9F0DCB00AE50
-277927EA044900812FE6008504509D2749A15A123A00A509860054AE1E5B4027
-11E6651A92410B7C066CD43F22F829009F5E04830C96008647195DDF05790B9C
-1BFD3452089C0DFA386B075001D72C08C300FC04B924740B9D00348504A03D1D
-96340AF00431D5008C05992785203F7C0D780161388B115101D05A006D057E34
-5E0EA2380177DE045900E009AF671F4907950D4DC55005A3541F9E650C7F0099
-65017D276B3E05C0015611861DF626601B6F26FC3800CC083500C57947126B1F
-DF320CF104D8804934C75105DD4B20EA1250008608AC6B3012B327E61E6126F8
-780D38A41F4F016C4300B6691F834901A633BB5B1A845037791E834A00F15326
-D65C0EFC4800DA08498823A45012AB26FD1A5204DB094AB72250F8084AE620AA
-411ABC12F74A01DB4100F2691F502BBA39602E500577C15B277F206C26853201
-E40737AB1F5A3C19D84112FA228D1F3AAE4531AB07A301BE0A980EB0602172EF
-6C2705DB2FB950059E492A6A2200B20D00268513983D009D27C71350400DF34A
-007A0740B7113F00BD50016AD434C615812E03CD3612D6226F123FAF00EE1249
-B30D278D380293082EAE1B27B05626CF003B6C01802777033BB9611AA4310286
-35129E29007C300B9423603E14AE0C86315208CF00940B7C01C823EC124600FA
-04AA00E209BC6C2657D00240E704AD4D07B200580AE56900DB0C763F20863464
-2779290C9F01410BB2511B94013679128301BF3D77286C44F6325A03BB532579
-1F66DF019A1D883E1FC15A016CA027621FF12F0D79229406E85017A25A098000
-F6056C31489E01346BD90849C71F4E800150860D307B1F52BC14F622C512509D
-002F790063E81FAE41046CBF1366EE0046D80184277721CB1B9E265F12F820A0
-1486017A2892173D6944145F3F128700279B6C0D80371E865030A46D1B3F9427
-6203D05012E305C7004ADE5026D03360007E0D5AF024D21FA74A09EA05A51679
-00D02C6608FC01B5092E79276D0ADA660429EF3103CF099612AA4100A7113F60
-267C0130C5278D289420D40A2765E7005631A60F3BE6123ED5044AF401A20E6C
-4107630047CE0C49F324C53A0D6D005DDE1B42960553378C1DA62AE800620480
-0E4BB03B7342045A38B21AD42550B910CF30A500FE2FB450173BBA4600F53E04
-D92701C40D5A19B3355A0082277A1F3D92042F8D12851FF326C23E0474006C32
-12991F5F3CD60D501E8612911B5F3848A510CE01AF263BAD501A7E4936702B50
-0460F62666D800AF0EF078044B0DC001521379BE052B97197C01608E00699E19
-399717632EE601B22DA136861B3E7110830554B426D01233860D2FD224B90479
-0F6C1F53BC4027FB03791B00BD30E412603F05A401793A04841B79490D6605EE
-00631192530C9513824933A001FD0F9725EC22B5015DF11340C5006808AC0343
-6C209B27B20CF9610052B401256CBE3A04E54934A104EE006A33571B870D7901
-D60BB105E500D078270B860130931A503C225DDF771F3CA56B0040865012B527
-FB2140BE37056DB4003F8606593D1A790FED055ADD01A91F752F0187069A4C00
-F3580181124F34C7019D063A96006A3347D950276C079D00F8741F650CF15026
-DE0539CA278523901FDF2D1AC4265F00EF096C384979007F08500D9F42086AA5
-1A52FD395A2F9E14E30D5A19802640CC391E79AD3E01699E4000CE0F851A3F9D
-15E53F00FE166B258D2051125B3E19B04838BD50096CC400B40B480061E3063A
-F9240FCC3E006C0883045A12F2401F5EDF12C42584D6025C239713318627D215
-FA49396022C4276D0CB42067FE005B4026F01350D71AB72601820DAC52228433
-0D52C6275A009E0EAF5D007609A634510569AD0148D04E26881FCC122DD81C3D
-CA6C2D1ABA32007C27049D0DD200660441CE3B018E066E0BE5046012F40D5218
-7C266C2759C1055D04A452274AC4470070C834A4089100DB045A1FF52540651F
-8727A817448F1A53984F0477ED1BAD2ED01FA34D03CA0A3B79006A0D4E34C744
-00BB690A5B009208A40EEB0047A518503599072D9F1FD5650D7B2F099105723B
-F049012ECF1650D90032891E7F277834139D20D74701C778153486227012B805
-6100AC6004A86A2701F6730454E20FBB5023752749B7378F006AEA20B71A9D4C
-30008727A627DB03AE08DF004E36922D7711BB02600EEB40046C1BFB27782185
-1279018906DD3A01FE0E863000B42801DB2647275B1078267E00348D2796224B
-B61AEF008D077A38501FE526793460256C2779380379E90040DA530E79043DA1
-00AD411F58C7115A1FC0670087047940AD04E60ACE0150EC04415A1A822800FA
-4208E7039D2F43DF34500D8641009D5E12459A1E6B375B01CA06E911781A4BBC
-123F5A006A2707D8B01A50008423633476209F12F90AC800692185279C331395
-2784015A12AC29E234A12777125A9C234E04D35A0C82410D7BB701CA3C00E50D
-5BDC0C5401FD06357F276E21AA12FA04A5019E0DC700E004B00CD95A2A12881A
-7701C526961950CD2266F6002798037B0836E926A529126A472D6015921F692F
-B800F50BAA50106CA01D3C5A01790E7D22F2321EE71437D40130CA009119842F
-7C1F6501FB08268605A633F14278220D6CCC3F06B90BF701862F6927791F3AF1
-4007DA0159B500DE0D3CBD4E0574006A0DCD00AE41156CBB621C36E813BE611E
-3E640BAF501A992F136CBC4115A953019E11DA2862278522406C3D187A2F881F
-843307B26004A749276B4000EE33088C042C864F31DF14AA430E771A5AF309C1
-00B44A27A80B771294253D6120BF2C0060B40CFC27C005A20055B0074A792284
-4E12A427F90EA00050AE384795512FDB147A2601A254FD3B107D4A16942D5012
-CE00B5044A860D5A951D7B24478621A062002EEE22B71A9027683204E9003912
-9F6A01742F05F8009C2A46863A01C2780027852F6C12E43150049601CF084EC1
-00F04F24C2125000BD6C1F3ED23A01F416AE5A127E471CB4430CAF014A86235E
-B505CD003785203D6C05FC0139DC55036CCF05790148DC24406C18921C503586
-12652BC300AE06EC3C0979044922DA2B0A820427C70149930050C03A044E019A
-1DE8365A00AA5B26781B3DE119A6003CB905F809306D1440CA791160305001F7
-08BE71217949F2042BCD22AC49346C12DF2504FA65203EEA5F05CE00A1450CBD
-5F1D73327B1A5A2E650586015AF6274102FB0D681DAF0C84052FBA01DF5E006B
-E722773504FD003C6C2749B2045ADC1A8B124F86401FBE2F1349E93793098404
-D53A0068E30145D90394127D2F531A64D6205AB46C0560C015E0601A790C34D0
-1F63128F1FD42B69007911DA3F04EB09A45D017F26D21260411F65C101EA0A51
-043CA90DD15B1F833D0B53A50D2786500984007908A450006BA73F098704501F
-93233D651B7D0038F40DB000E70EAC14D520B3350DA478264E950087305223E1
-621B75253ED13A129E07CA6C12791DE20D93137E2F0CA0243EB0260095075086
-006C0D4FA61F771256BC2A15A6266D3E21FB490DD07601468F0044129C3E1F77
-3600AC24F45B089F04EB458509A90DC3279E4C1F81326C2340C10B54347503AD
-7900387F27941FD680006C3E05B44C1BDB2F01C84100B13D15EB21C519338C0C
-5116D926AE12D10D50F004B426D65A216B2788227704832951089C670032C714
-3BDB4512CE6C00399C04860A5901782682172F57A347016330F800B8440068D1
-0460EE4435E11FB227CD1B3DF800AF4005855A0A9101C7500435960028AB1135
-C326ED4E00F60DB542128539127B277733002771224084063C01C60DB000D810
-772F9E15EB273A0EE0571AB80065274426FD1C9C46007A0693601A6BE212914B
-277E015AF11FCD279A0061366C31A100793F128D34059D01CA0A5535BB4102F2
-6C1F3EE5500881015B097C043FA5124BFB12AD1FBE28F10041DB2601C437B019
-5A3F1E78EA3B1A7A11501A9D009009630586015A346226EA1235F21F3B6A0E77
-B51A40861FF868088104337A256C0464E30358BA00DC0C55C49401F1611A5AF4
-6D27642A861F5200F6074A007EC95A2804911046F505B15901780A31E526C236
-109E263B5F05D80040B53E0D6D01790E40B402F4065A3B16C45A0048AB1A7949
-39FC005F11984700CB0E791F9F27B628EA279C2252C80027612D6E07930D5098
-048C401279069101C8680850028726A601C40F6B2346F54929B912CF088801AC
-700057B51BDE270160E9054B012BA21F5AAE1387279C1B347E192F8F22A53907
-13503D04D500490AA204FC083ABC63206CB66812490177C54D339A19820D35AC
-22CD61126C0457ED007804A92D50961260059F2FB822EB561D7C26881FE26C04
-27F96909E22F017F1F8727DE361590265501D304470C92005612F70B3D9E46BC
-00EA521F3BB41A4C0EF35127DE257C2E12AF23BD12F82F68277B34D412580178
-227F279E1F5B40219A33077B005ABF300D5BBA784F0ED13801E506C80049A200
-CE46056C1160E36CAD1F862E9C13C92092234F83013E9E044626A122FC400825
-E300502CD368147D3900852CA51F3FB022FD1A850D46F624D01B6805773400CA
-0B4901A80D46B6740C2D852450C412A306730151BC0540A564226CF3601F6CB1
-3E01911A700D39683E04D06C0065C627600C9A00500AE749006C335900970CE1
-06A3018525AD0DE4006B043CC30DDB046BE72DA93D126C9F224616E141009E64
-213D612EEE0C502678F927B800302600CD126A2676336B0040B412E31A4ED00E
-DD00860B27AD650E6CC0015209E00354BC23F701860D4D8B086527D103396C00
-8327E013AD6C2766D75A2792003919A04000B304613443D0219F1C782EFB0A31
-B8114901C92F06844D2AD502E313A1228F4610F634068700CE216ABC3E1A9D37
-F104AD401F79276F22682FC91A5030A415F2790054288712500A6204F64705D8
-00A4088530500D76B80F8F1668AD0E3D01861B569CFE4936A505EB01AE0EEF60
-056E27790030871F5B33BC750036892241951F86279832068E0E5A26D1013057
-B900508619A83C0E98005A3C1086044712FE1A67DB4C04EB511A930EF500583C
-0CEC005C12854C008F277E2150E714BB1C6635498609CB0130801F57AE2D6F1A
-853404A55C047F0D861863CB04B200FC0D8D005D9B046C365022669F1143B427
-C81F9D2F147E266D276922C919F300405401BD3F046CC2490BD74004107C0258
-402079277F1A2FCF1B990CAF61043DF104521643ED02A50634F2004F12EA601F
-48B349136CDE17419A123EC7045FF31F50BF02F91FA5268001792E0E86306122
-D22777269412BD6B2749C44604E13C19D80D9F006A41007907B50027781B5ADF
-05A8013C10D84F01FA541229D91F602EDE0B3C5212603A5829ED123DD70EAF01
-D4063EFD0078013A820066AE02970BEF01950479278622DE345A1FD72F128332
-621577AE27DC1BBA5B0BD9004787015A34F44013C3711A840DD77C1D5A12CF6A
-163EC26C0140D800730794370085062FEE014991224785093F6A2D5000C832B2
-20C74106C101A3096C00A80867400087066C25951F60A8045132C212AD30F150
-216CFD04B63F266C2276EE610427A42F07C76D0150BE004A9F01F031A608C402
-49921F644127721AAA176A304AEF520DD81A3FE334531AB2365711A5066C0185
-087E004FEC05B301C72200630D8500388F1F50C5123CAB005608A32E0048B24C
-27013EB52E5000789F0427A21D7B3B1AE922AD4C27C0541F7D340AB00031DF22
-A00694600D790864009B531B79128B36E64731DD1EB22BD710AE0079084171FE
-1A5E3D03940C278A0E50336500870CC5471341B578156298431F953814822540
-6C1A7F217626853506BA00F70CC7462C7B0AC1052395274A87015A108D3A5C13
-FE4632D21FAE26FB24B21E5F276C384984>
- >>
-
->>
-dup /HalftoneName 3 index put
-/Halftone defineresource
-pop
diff --git a/Master/tlpkg/tlgs/lib/image-qa.ps b/Master/tlpkg/tlgs/lib/image-qa.ps deleted file mode 100644 index e5e7fa7bcb1..00000000000 --- a/Master/tlpkg/tlgs/lib/image-qa.ps +++ /dev/null @@ -1,1826 +0,0 @@ -%!PS
-% Copyright (C) 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-%
-% $Id: image-qa.ps 6300 2005-12-28 19:56:24Z giles $
-% Tests for the image operators
-
-% Specifications for Image operator testing.
-%
-% 1. All 8 standard orientations (0, 90, 180, 270 degree rotations with
-% and without reflection); ditto those orientations perturbed by +/-
-% 10 degrees, and by 45 degrees.
-%
-% Enough space is provided around images on a test page to allow
-% these permutations to use the same page layout. This will make
-% test page construction easier and simplify page checking.
-%
-% 2. All 9 image types (ImageType 1 mask, ImageType 1 opaque,
-% ImageType 3 with all 3 InterleaveTypes and with unequal scaling
-% for InterleaveType 2 and 3, ImageType 4 with both range and
-% single-point matching).
-%
-% 3. DeviceGray, DeviceRGB, and DeviceN color, both direct and Indexed.
-% Indexed color will use the common pallete size of 256 colors.
-%
-% 4. For simple masks, both colored and uncolored Patterns.
-%
-% 5. CombineWithColor true and false; several different colors for the
-% true case (including black, white, other solid colors, halftones,
-% and patterns).
-%
-% 6. Source transparency true and false.
-%
-% 7. Texture transparency true and false.
-%
-% 8. Different RasterOp values.
-%
-% 9. For ImageType 4, different color keys (out-of-range, specific
-% color other than white, range without white).
-%
-% 10. String, file, and procedure data sources; for multi-component
-% color spaces, MultipleDataSources = true. This is tested by
-% constructing string data sources that are used as input to
-% SubFileDecode filter to create a filetype data source. These
-% filters are read into scratch strings for the procedure data
-% source case. The procedure data source scratch string length
-% does not match the raster width, and the width x height is
-% not an integer multiple of the string length.
-%
-% Also for the File case, the number of bytes consumed is
-% checked after the image operator to verify that the exact
-% amount of data is used. This is particularly important when
-% the currentfile is used as a source (possibly through a
-% filter.
-%
-% Image bytes per line are < 500 bytes to exercise direct and
-% buffer copy gs_image_next_planes mode with the default stream
-% buffer size of 512 bytes. Procedure string size is greater
-% than the image bytes per line for the same reason (sM and sD).
-%
-% Total string size is kept below 65535.
-
-/WidthRGB 83 def
-/HeightRGB 89 def
-
-%
-% 11. Banded and non-banded rendering. This can be tested by running
-% test files throuch with different page device parameters to
-% force banding vs. page mode.
-%
-% -------------------------------------------------------------------------
-%
-% Testing the RasterOp-related functions (5/6/7/8) is not necessary at this
-% time. They are well isolated logically.
-%
-% Testing orientation (1) and color masking (9) would be a good idea at some
-% point, because this code has broken many times in the past and has had a
-% long bug tail.
-%
-% The really important things to test are 2 (image type), 3/4 (color space --
-% but only with regard to number of components, plus DeviceN and simple masks
-% with a Pattern, which exercise special control paths), 10 (data source),
-% and 11 (banding modes).
-%
-% ==========================================================================
-
-%
-% Procedure to generate test mask data
-%
-% WM and HM must be defined prior to invocation
-% MaskGen -
-%
-% The mask data is stored into a string named /MaskData
-%
-% The mask consists of a "target". Bits past width WM are
-% filled with 1's to make sure that pad bits are ignored.
-%
-/MaskGen {
- /H8 HM 8 div def
- /X0 WM 2 div def
- /Y0 HM 2 div def
- /WB WM 7 add 8 div cvi def
- /MaskData WB HM mul string def
- /MB [ 128 64 32 16 8 4 2 1 ] def
- 0 1 HM 1 sub {
- /Y exch def
- 0 1 WB 1 sub {
- /B exch def % byte within the row
- /C B Y WB mul add def
- /P 0 def
- 0 1 7 {
- /b exch def % bit within the character
- /X b B 8 mul add def
- X WM lt
- { X Y eq
- X HM 1 sub Y sub eq or
- Y Y0 gt X X0 sub abs 2 le and or
- X X0 sub WM div dup mul Y Y0 sub HM div dup mul add sqrt 9 mul cvi 2 mod 1 eq or
- }
- { true } % pad bits are always set
- ifelse
- % stack: true if pixel is set
- {
- MB b get P or /P exch def
- } if
- } for % Bits within a byte
- MaskData C P put
- } for % Bytes within the row
- } for % Rows in the mask
-} bind def % MaskGen
-
-%
-% WM and HM must be defined prior to invocation
-% BPC MaskGenBPC -
-%
-% The mask data is stored into a string named /MaskData
-%
-% The mask consists of a "target". BPC is the size of the elements
-% in the MaskData string (must be 4, 8 or 12)
-%
-/MaskGenBPC {
- /BPC exch def
- /X0 WM 2 div def
- /Y0 HM 2 div def
- /WB WM BPC mul 7 add 8 div cvi def % Width in Bytes
- /MaskData WB HM mul string def
- 0 1 HM 1 sub {
- /Y exch def
- 0 1 WM 1 sub {
- /X exch def
- MaskData % Target string
- X Y eq
- X HM 1 sub Y sub eq or
- Y Y0 gt X X0 sub abs 2 le and or
- X X0 sub WM div dup mul Y Y0 sub HM div dup mul add sqrt 9 mul cvi 2 mod 1 eq or
- X BPC mul 8 div Y WB mul add exch
- [
- { } % BPC = 0
- { { 1 } { 0 } ifelse put4bit } % BPC = 4
- { { 255 } { 0 } ifelse exch cvi exch put } % BPC = 8
- { { 1 } { 0 } ifelse put12bit } % BPC = 12
- ] BPC 4 div cvi get exec
- } for
- } for % Rows in the mask
-} bind def
-
-% -----------------------------------------------------------------------
-
-% Procedure to generate image data
-%
-% WD and HD must be defined prior to invocation
-% { proc } ImageGen -
-%
-% The procedure is called once for each pixel
-% Local definitions are R, G, B, X and Y
-
-% Example: Generate RGB Chunky pixel data (single data source) BPC = 8
-% /WD WidthRGB def
-% /HD HeightRGB def
-% /RGBData WD HD mul 3 mul string def
-% { X Y WD mul add 3 mul RGBData
-% dup 2 index R 255 mul cvi put
-% dup 2 index 1 add G 255 mul cvi put
-% exch 2 add B 255 mul cvi put
-% } ImageGen
-
-/ImageGen {
- gsave
- 0 1 HD 1 sub {
- /Y exch def
- 0 1 WD 1 sub {
- /X exch def
- /D X WD 2 div sub WD div dup mul Y HD 2 div sub HD div dup mul add sqrt def
- /D D .6 div def
- /A X WD 2 div sub Y HD 2 div sub atan 360 div def
- A % Hue
- .7 D .3 sub .60 div sub % Saturation
- dup 0.05 lt
- { .95 D .8 sub 3 mul sub 3 mul cvi 3 div sqrt } % Level once Saturation < 0
- { .7 D .25 sub .75 div add } % Level inside
- ifelse
- X WD 2 div gt Y HD 2 div sub abs 2 le and { pop 0 } if % asymmetric marker
- sethsbcolor
- currentrgbcolor /B exch def /G exch def /R exch def
- dup exec
- } for
- } for
- pop % discard the procedure
- grestore
-} bind def
-
-
-% -----------------------------------------------------------------------
-%
-% Procedures for ImageMatrix creation
-/IMLRTB { [ WD 0 0 HD neg 0 HD ] } def
-/IMLRBT { [ WD 0 0 HD 0 0 ] } def
-/IMRLTB { [ WD neg 0 0 HD neg WD HD ] } def
-/IMRLBT { [ WD neg 0 0 HD WD 0 ] } def
-% -----------------------------------------------------------------------
-%
-% Procedure to make invocation of image operators more concise
-%
-% YY, SX, SY, WD and HD should be defined prior to invocation
-% X matrix source decode DoImageMask -
-%
-/DoImageMask {
- gsave
- /D exch def
- /S exch def
- /M exch def
- /XX 1 index def
- YY translate SX SY scale
- 0 setlinewidth 0 0 moveto 1 0 lineto 1 1 lineto 0 1 lineto 0 0 lineto stroke
- .5 .5 translate
- IR rotate
- -.5 -.5 translate
- <<
- /ImageType 1
- /Width WM
- /Height HM
- /ImageMatrix M
- /MultipleDataSources false
- /DataSource S
- /Decode D
- /BitsPerComponent 1
- >>
- imagemask
- grestore
-} bind def
-
-% YY, SX, SY, WD and HD should be defined prior to invocation
-% X Y BPC matrix source multi decode DoImage1 -
-%
-/DoImage1 {
- gsave
- CSpace setcolorspace
- /D exch def
- /MS exch def
- /S exch def % May be an array of sources
- /M exch def
- /BPC exch def
- /XX 1 index def
- YY translate SX SY scale
- 0 setlinewidth 0 0 moveto 1 0 lineto 1 1 lineto 0 1 lineto 0 0 lineto stroke
- .5 .5 translate
- IR rotate
- -.5 -.5 translate
- <<
- /ImageType 1
- /Width WD
- /Height HD
- /ImageMatrix M
- /MultipleDataSources MS
- /DataSource S
- /BitsPerComponent BPC
- /Decode D
- >>
- image
- grestore
-} bind def
-
-
-% YY, SX, SY, WD and HD should be defined prior to invocation
-% X Y BPC matrix source multi decode MaskColor DoImage4 -
-%
-/DoImage4 {
- gsave
- CSpace setcolorspace
- /MC exch def
- /D exch def
- /MS exch def
- /S exch def % May be an array of sources
- /M exch def
- /BPC exch def
- /XX 1 index def
- YY translate SX SY scale
- 0 setlinewidth 0 0 moveto 1 0 lineto 1 1 lineto 0 1 lineto 0 0 lineto stroke
- .5 .5 translate
- IR rotate
- -.5 -.5 translate
- <<
- /ImageType 4
- /Width WD
- /Height HD
- /ImageMatrix M
- /MultipleDataSources MS
- /DataSource S
- /BitsPerComponent BPC
- /Decode D
- /MaskColor MC
- >>
- image
- grestore
-} bind def
-
-% YY, SX, SY, W, HD (Data) WM, HM (Mask) should be defined prior to invocation
-% (IT is InterleaveType)
-% X Y BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
-%
-/DoImage3 {
- gsave
- CSpace setcolorspace
- /IT exch def
- /DD exch def
- /DM exch def
- /MS exch def
- /S exch def % May be an array of sources - For InterleaveType 3
- % S[0] is the Mask DataSource
- /M exch def
- /BPC exch def
- /XX 1 index def
- YY translate SX SY scale
- 0 setlinewidth 0 0 moveto 1 0 lineto 1 1 lineto 0 1 lineto 0 0 lineto stroke
- .5 .5 translate
- IR rotate
- -.5 -.5 translate
- /DataImage
- <<
- /ImageType 1
- /Width WD
- /Height HD
- /ImageMatrix M
- /MultipleDataSources MS
- /DataSource IT 3 ne { S } { S 1 get exec } ifelse
- /BitsPerComponent BPC
- /Decode DD
- >>
- def
- /MaskImage
- <<
- /ImageType 1
- /Width WM
- /Height HM
- /ImageMatrix % construct the mask matrix using signs from the DataImage matrix
- /M0 M 0 get WD abs div cvi def
- /M3 M 3 get HD abs div cvi def
- /M4 M 4 get WD abs div cvi def
- /M5 M 5 get HD abs div cvi def
- [ WM M0 mul 0 0 HM M3 mul WM M4 mul HM M5 mul ]
- IT 3 eq {
- /DataSource S 0 get exec % DataSource only allowed for InterleaveType 3
- } if
- /BitsPerComponent IT 1 eq { BPC } { 1 } ifelse
- /Decode DM
- >>
- def
- <<
- /ImageType 3
- /DataDict DataImage
- /MaskDict MaskImage
- /InterleaveType IT
- >>
- image
- grestore
-} bind def
-
-
-% -----------------------------------------------------------------------
-%
-/Helvetica-Bold findfont 20 scalefont /TitleFont exch def
-
-/FontSize 10 def
-/Helvetica-Narrow findfont FontSize scalefont /LegendFont exch def
-
-/blockshow { % like "show" but '\n' causes new-line
- dup = flush %DEBUG
- currentpoint /showY exch def /showX exch def
- {
- dup 10 ne
- { 1 string dup 0 4 -1 roll put show }
- { pop showX showY FontSize sub dup /showY exch def moveto }
- ifelse
- } forall
-} bind def
-
-/TX 013 def % Title left X
-/SX 036 def
-/XA 060 def
-/XB XA SX 1.5 mul add def
-/XC XA SX 3.0 mul add def
-/XD XA SX 4.5 mul add def
-/XE XA SX 6.0 mul add def
-/XF XA SX 7.5 mul add def
-/XG XA SX 9.0 mul add def
-/XH XA SX 10.5 mul add def
-/XI XA SX 12.0 mul add def
-/XJ XA SX 13.5 mul add def
-
-/BY 036 def % Bottom Title Top line
-/SY 037 def
-/YA 050 def
-/YB YA SY 1.8 mul add def
-/YC YA SY 3.6 mul add def
-/YD YA SY 5.4 mul add def
-/YE YA SY 7.2 mul add def
-/YF YA SY 9.0 mul add def
-/YG YA SY 10.8 mul add def
-/YH YA SY 12.6 mul add def
-/YI YA SY 14.4 mul add def
-/YJ YA SY 16.2 mul add def
-/YK YA SY 18.0 mul add def
-
-% -----------------------------------------------------------------------
-%
-% Utility procedures to support storing 4 and 12 bit elements in
-% strings.
-%
-% <string> <index> <value> put##bit -
-%
-% <index> will have a fractional part ( .5 ) if the element
-% starts on a 4-bit boundary.
-%
-% <value> is between 0 and 1 and is scaled 0 to 15 (4bit) or
-% 0 to 4095 (12 bit)
-
-/put4bit {
- 15 mul cvi
- exch dup cvi dup 3 1 roll eq 3 -1 roll exch
- { % integer index means high nibble.
- 16 mul put
- }
- { % low nibble -- combine with high nibble
- 2 index 2 index get or put
- }
- ifelse
-} bind def
-
-/put12bit {
- 1 index cvi /I exch def
- 2 index /S exch def
- 4095 mul cvi
- exch dup dup cvi eq
- { % integer index means high byte is aligned
- cvi exch 3 copy 16 div cvi put
- exch 1 add exch 15 and 16 mul put
- }
- { % low nibble -- combine with high nibble
- cvi exch 3 copy 2 index 2 index get exch 256 div cvi or put
- 255 and exch 1 add exch put
- }
- ifelse
-} bind def
-
-% -----------------------------------------------------------------------
-%
-% Procedures to use generated string data as procedure or files
-
-/WD WidthRGB def
-/HD HeightRGB def
-
-/sM WidthRGB 2 mul 1 sub string def % long enough to hold more than one mask line
-/sD WidthRGB 7 mul 1 sub string def % long enough to hold more than one 12 bit RGB line
- % worst case is 12bit ImageType3 InterleaveType 1 == 48 bits
-
-/MaskDProc {
- /FM MaskData dup length () /SubFileDecode filter def
- { { FM sM readstring pop } }
-} bind def
-
-/FileTailString (12345) def % Marker string to check file data usage
-
-/AppendFileTail { % <string> AppendFileTail <string_with_tail> <original_length>
- dup length FileTailString length add string
- dup 0 3 index putinterval
- dup 2 index length FileTailString putinterval
- exch length
-} bind def
-
-/MaskDFile {
- MaskData dup length () /SubFileDecode filter
- /MDF 1 index def
-} bind def
-
-/RGBDProc {
- /FD RGBData dup length () /SubFileDecode filter def
- { { FD sD readstring pop } }
-} bind def
-
-/RGBDFile {
- RGBData dup length () /SubFileDecode filter
- /RGBDF 1 index def
-} bind def
-
-/sR WidthRGB 2 mul 1 sub string def % long enough to hold more than one line of 12 bit data
-/sG WidthRGB 2 mul 1 sub string def
-/sB WidthRGB 2 mul 1 sub string def
-
-/RDProc {
- /FR RData dup length () /SubFileDecode filter def
- { FR sR readstring pop }
-} bind def
-
-/GDProc {
- /FG GData dup length () /SubFileDecode filter def
- { FG sG readstring pop }
-} bind def
-
-/BDProc {
- /FB BData dup length () /SubFileDecode filter def
- { FB sB readstring pop }
-} bind def
-
-/RDFile {
- RData dup length () /SubFileDecode filter
- /RDF 1 index def
-} bind def
-
-/GDFile {
- GData dup length () /SubFileDecode filter
- /GDF 1 index def
-} bind def
-
-/BDFile {
- BData dup length () /SubFileDecode filter
- /BDF 1 index def
-} bind def
-
-% -----------------------------------------------------------------------
-%
-% Procedure to handle fileposition. Ghostscript has a private
-% operator .fileposition that works when fileposition does not
-%
-% <file> tryfilepos
-% Returns: fileposition true if successful
-% 0 false if not
-/tryfilepos {
- /.fileposition where
- { pop /.fileposition load } % most likely to succeed
- { /fileposition load }
- ifelse
- stopped
- { pop 0 false }
- { true }
- ifelse
-} bind def
-
-% -----------------------------------------------------------------------
-%
-% Procedure to provide =only operator if not present. Suggested
-% by Alex Cherepanov to use =print operator present on some Adobe
-% implementations.
-/=only where
- { pop }
- { /=print where { pop /=print load } { /print load } ifelse
- /=only exch def
- }
-ifelse
-
-% -----------------------------------------------------------------------
-%
-% Procedure to make sure that the file is at the EOF.
-% added above (string == FileTailString.
-%
-% If not, it will mark the image area with a red "F"
-%
-% <string> <title> <file> CheckFileTail - XX is the horizontal position
-% YY is the vertical position
-% SX,SY determine size of "F" if fail
-/CheckFileTail {
- dup
- status not dup % status false says no longer valid
- { (Unexpected EOF: XX,YY=) print XX =only (,) print YY = false }
- { 1 index tryfilepos not exch 5 index length ne or dup
- { 3 index print ( fileposition = ) print
- 2 index tryfilepos pop =only
- ( doesn't match expected = ) print 4 index length = flush
- }
- if
- }
- ifelse
- or
- {
- gsave .8 0 0 setrgbcolor
- SX 4 div setlinewidth
- XX YY moveto 0 SY rlineto SX 0 rlineto stroke
- XX YY SY .5 mul add moveto SX .5 mul 0 rlineto stroke
- grestore
- }
- if
- pop pop pop
-} bind def
-
-/CSpaceName { % - CSpaceName <string>
- CSpace dup type /arraytype eq { 0 get } if
- 15 string cvs
-} bind def
-% -----------------------------------------------------------------------
-%
-% tests
-
-/CheckImage {
-
- /IR 0 def
- /CSpace /DeviceRGB def
-
- % Use an unusual (unpleasant?) underlying color
- .6 .95 .4 setrgbcolor clippath fill
-
- 0 0 0 setrgbcolor
- TitleFont setfont
- 200 760 moveto (Image Type 3 Tests) show
- 200 740 moveto (Rotation Angle = ) show IR 3 string cvs show
- 170 720 moveto (Colorspace = ) show CSpaceName show
- LegendFont setfont
-
- .4 .1 .7 setrgbcolor % contrasting color for stencil masking
- /SX SX 2 mul def /SY SY 2 mul def
- /YY 780 SY sub def
- MaskGen
- TX IMLRTB MaskData [1 0] DoImageMask
-
- /RGBData WD HD mul 3 mul string def
- { X Y WD mul add 3 mul RGBData
- dup 2 index R 255 mul cvi put
- dup 2 index 1 add G 255 mul cvi put
- exch 2 add B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi decode
- XI 8 IMLRTB RGBData false [0 1 0 1 0 1] DoImage1
- /SX SX 2 div def /SY SY 2 div def
-
- showpage
-} def
-
-% -----------------------------------------------------------------------
-%
-% Type 1 and Type 4 Tests
-
-% /CSpace and /IR are defined in order to generate various pages
-/T1T4Tests { %
-
- % Use an unusual (unpleasant?) underlying color
- .6 .95 .4 setrgbcolor clippath fill
- 0 0 0 setrgbcolor
-
- TitleFont setfont
- 120 760 moveto (Image Type 1 and ImageType 4 Tests) show
- 200 740 moveto (Rotation Angle = ) show IR 3 string cvs show
- 170 720 moveto (Colorspace = ) show CSpaceName show
- LegendFont setfont
-
- XA BY moveto (Decode\nInverted) blockshow
- XB BY moveto ( IMLRTB\nDS=string) blockshow
- XC BY moveto ( IMLRBT\nDS=string) blockshow
- XD BY moveto ( IMRLTB\nDS=string) blockshow
- XE BY moveto ( IMRLBT\nDS=string) blockshow
- XF BY moveto (IMLRTB\nDS=proc) blockshow
- XG BY moveto (IMLRTB\nDS=file) blockshow
- XH BY moveto ( Multi\nDS=string) blockshow
- XI BY moveto ( Multi\nDS=proc) blockshow
- XJ BY moveto ( Multi\nDS=file) blockshow
-
- .4 .1 .7 setrgbcolor % contrasting color for stencil masking
-
- /WM WD def
- /HM HD def
- /SX SX 2 mul def /SY SY 2 mul def
- /YY 780 SY sub def
- MaskGen
- TX IMLRTB MaskData [1 0] DoImageMask
-
- /RGBData WD HD mul 3 mul string def
- { X Y WD mul add 3 mul RGBData
- dup 2 index R 255 mul cvi put
- dup 2 index 1 add G 255 mul cvi put
- exch 2 add B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi decode
- XI 8 IMLRTB RGBData false [0 1 0 1 0 1] DoImage1
- /SX SX 2 div def /SY SY 2 div def
-
- % ----------------------------------------------------------------------
- % Type 1 Stencil Mask Images
-
- /YY YA def
- TX YA SY add moveto (\nType 1\nStencil\nMask) blockshow
-
- MaskGen
-
- % X matrix source decode
- XA IMLRTB MaskData [0 1] DoImageMask
- XB IMLRTB MaskData [1 0] DoImageMask
- XC IMLRBT MaskData [1 0] DoImageMask
- XD IMRLTB MaskData [1 0] DoImageMask
- XE IMRLBT MaskData [1 0] DoImageMask
- XF IMLRTB MaskDProc [1 0] DoImageMask
- XG IMLRTB MaskDFile [1 0] DoImageMask
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 1 RGB Single Data Sources, BPC==8
-
- /YY YB def
- TX YY SY add moveto (\nType 1\nRGB\nBPC=8) blockshow
-
- /RGBData WD HD mul 3 mul string def
- { X Y WD mul add 3 mul RGBData
- dup 2 index R 255 mul cvi put
- dup 2 index 1 add G 255 mul cvi put
- exch 2 add B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi decode
- XA 8 IMLRTB RGBData false [1 0 1 0 1 0] DoImage1
- XB 8 IMLRTB RGBData false [0 1 0 1 0 1] DoImage1
- XC 8 IMLRBT RGBData false [0 1 0 1 0 1] DoImage1
- XD 8 IMRLTB RGBData false [0 1 0 1 0 1] DoImage1
- XE 8 IMRLBT RGBData false [0 1 0 1 0 1] DoImage1
- XF 8 IMLRTB RGBDProc false [0 1 0 1 0 1] DoImage1
- XG 8 IMLRTB RGBDFile false [0 1 0 1 0 1] DoImage1
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 1 RGB Multiple Data Sources, BPC==8
-
- WD HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- { X Y WD mul add
- RData 1 index R 255 mul cvi put
- GData 1 index G 255 mul cvi put
- BData exch B 255 mul cvi put
- } ImageGen
-
-
- % X BPC matrix source multi decode
- XH 8 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] DoImage1
- XI 8 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] DoImage1
- XJ 8 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] DoImage1
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Single Data Sources, BPC==8, mask black
-
- /YY YE def
- TX YY SY add moveto (\nType 4\nBPC=8\nmask=black) blockshow
-
- % X BPC matrix source multi decode MaskColor
- XA 8 IMLRTB RGBData false [1 0 1 0 1 0] [ 000 000 000 ] DoImage4
- XB 8 IMLRTB RGBData false [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- XC 8 IMLRBT RGBData false [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- XD 8 IMRLTB RGBData false [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- XE 8 IMRLBT RGBData false [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- XF 8 IMLRTB RGBDProc false [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- XG 8 IMLRTB RGBDFile false [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Multiple Data Sources, BPC==8, mask black
-
- % X BPC matrix source multi decode MaskColor
- XH 8 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- XI 8 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- XJ 8 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] [ 000 000 000 ] DoImage4
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Single Data Sources, BPC==8, mask white
-
- /YY YF def
- TX YY SY add moveto (\nType 4\nBPC=8\nmask=white) blockshow
-
- % X BPC matrix source multi decode MaskColor
- XA 8 IMLRTB RGBData false [1 0 1 0 1 0] [ 255 255 255 ] DoImage4
- gsave .5 .2 .2 setrgbcolor XB YY SX 13 mul SY rectfill grestore
- XB 8 IMLRTB RGBData false [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- XC 8 IMLRBT RGBData false [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- XD 8 IMRLTB RGBData false [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- XE 8 IMRLBT RGBData false [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- XF 8 IMLRTB RGBDProc false [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- XG 8 IMLRTB RGBDFile false [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Multiple Data Sources, BPC==8, mask white
-
- % X BPC matrix source multi decode MaskColor
- XH 8 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- XI 8 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- XJ 8 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] [ 255 255 255 ] DoImage4
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Single Data Sources, BPC==8, mask gray
-
- /YY YG def
- TX YY SY add moveto (\nType 4\nBPC=8\nmask=gray) blockshow
-
- % X BPC matrix source multi decode MaskColor
- XA 8 IMLRTB RGBData false [1 0 1 0 1 0] [ 147 147 147 ] DoImage4
- XB 8 IMLRTB RGBData false [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- XC 8 IMLRBT RGBData false [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- XD 8 IMRLTB RGBData false [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- XE 8 IMRLBT RGBData false [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- XF 8 IMLRTB RGBDProc false [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- XG 8 IMLRTB RGBDFile false [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Multiple Data Sources, BPC==8, mask gray
-
- % X BPC matrix source multi decode MaskColor
- XH 8 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- XI 8 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- XJ 8 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] [ 147 147 147 ] DoImage4
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Single Data Sources, BPC==8, mask range
-
- /YY YH def
- TX YY SY add moveto (\nType 4\nBPC=8\nmask range) blockshow
-
- % X BPC matrix source multi decode MaskColor
- XA 8 IMLRTB RGBData false [1 0 1 0 1 0] [ 020 200 020 200 020 200 ] DoImage4
- XB 8 IMLRTB RGBData false [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- XC 8 IMLRBT RGBData false [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- XD 8 IMRLTB RGBData false [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- XE 8 IMRLBT RGBData false [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- XF 8 IMLRTB RGBDProc false [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- XG 8 IMLRTB RGBDFile false [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Multiple Data Sources, BPC==8, mask range
-
- % X Y SX SY BPC matrix source multi decode MaskColor
- XH 8 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- XI 8 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- XJ 8 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] [ 020 200 020 200 020 200 ] DoImage4
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 1 RGB Single Data Sources, BPC==12
-
- /YY YC def
- TX YY SY add moveto (\nType 1\nRGB\nBPC=12) blockshow
-
- /RGBData WD 36 mul 7 add 8 div cvi HD mul string def
- {
- X 36 mul 8 div Y WD 36 mul 7 add 8 div cvi mul add
- RGBData 1 index R put12bit
- RGBData 1 index 1.5 add G put12bit
- RGBData exch 3 add B put12bit
- } ImageGen
-
- % X BPC matrix source multi decode
- XA 12 IMLRTB RGBData false [1 0 1 0 1 0] DoImage1
- XB 12 IMLRTB RGBData false [0 1 0 1 0 1] DoImage1
- XC 12 IMLRBT RGBData false [0 1 0 1 0 1] DoImage1
- XD 12 IMRLTB RGBData false [0 1 0 1 0 1] DoImage1
- XE 12 IMRLBT RGBData false [0 1 0 1 0 1] DoImage1
- XF 12 IMLRTB RGBDProc false [0 1 0 1 0 1] DoImage1
- XG 12 IMLRTB RGBDFile false [0 1 0 1 0 1] DoImage1
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 1 RGB Multiple Data Sources, BPC==12
-
- WD 3 mul 1 add 2 div cvi HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- {
- X 3 mul 2 div Y WD 3 mul 1 add 2 div cvi mul add
- RData 1 index R put12bit
- GData 1 index G put12bit
- BData exch B put12bit
- } ImageGen
-
- % X BPC matrix source multi decode
- XH 12 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] DoImage1
- XI 12 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] DoImage1
- XJ 12 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] DoImage1
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Single Data Sources, BPC==12, mask range
-
- /YY YI def
- TX YY SY add moveto (\nType 4\nBPC=12\nmask range) blockshow
-
- % X BPC matrix source multi decode MaskColor
- XA 12 IMLRTB RGBData false [1 0 1 0 1 0] [ 300 3000 300 3000 300 3000 ] DoImage4
- XB 12 IMLRTB RGBData false [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- XC 12 IMLRBT RGBData false [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- XD 12 IMRLTB RGBData false [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- XE 12 IMRLBT RGBData false [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- XF 12 IMLRTB RGBDProc false [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- XG 12 IMLRTB RGBDFile false [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Multiple Data Sources, BPC==12, mask range
-
- % X BPC matrix source multi decode MaskColor
- XH 12 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- XI 12 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- XJ 12 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] [ 300 3000 300 3000 300 3000 ] DoImage4
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 1 RGB Single Data Sources, BPC==4
-
- /YY YD def
- TX YY SY add moveto (\nType 1\nRGB\nBPC=4) blockshow
-
- /RGBData WD 12 mul 7 add 8 div cvi HD mul string def
- {
- X 12 mul 8 div Y WD 12 mul 7 add 8 div cvi mul add
- RGBData 1 index R put4bit
- RGBData 1 index 0.5 add G put4bit
- RGBData exch 1.0 add B put4bit
- } ImageGen
-
- % X BPC matrix source multi decode
- XA 4 IMLRTB RGBData false [1 0 1 0 1 0] DoImage1
- XB 4 IMLRTB RGBData false [0 1 0 1 0 1] DoImage1
- XC 4 IMLRBT RGBData false [0 1 0 1 0 1] DoImage1
- XD 4 IMRLTB RGBData false [0 1 0 1 0 1] DoImage1
- XE 4 IMRLBT RGBData false [0 1 0 1 0 1] DoImage1
- XF 4 IMLRTB RGBDProc false [0 1 0 1 0 1] DoImage1
- XG 4 IMLRTB RGBDFile false [0 1 0 1 0 1] DoImage1
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 1 RGB Multiple Data Sources, BPC==4
-
- WD 1 add 2 div cvi HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- {
- X 2 div Y WD 1 add 2 div cvi mul add
- RData 1 index R put4bit
- GData 1 index G put4bit
- BData exch B put4bit
- } ImageGen
-
- % X BPC matrix source multi decode
- XH 4 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] DoImage1
- XI 4 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] DoImage1
- XJ 4 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] DoImage1
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Single Data Sources, BPC==4, mask range
-
- /YY YJ def
- TX YY SY add moveto (\nType 4\nBPC=4\nmask range) blockshow
-
- % X BPC matrix source multi decode MaskColor
- XA 4 IMLRTB RGBData false [1 0 1 0 1 0] [ 1 10 1 10 1 10 ] DoImage4
- XB 4 IMLRTB RGBData false [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- XC 4 IMLRBT RGBData false [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- XD 4 IMRLTB RGBData false [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- XE 4 IMRLBT RGBData false [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- XF 4 IMLRTB RGBDProc false [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- XG 4 IMLRTB RGBDFile false [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- % ----------------------------------------------------------------------
- % Type 4 RGB Multiple Data Sources, BPC==4, mask range
-
- % X BPC matrix source multi decode MaskColor
- XH 4 IMLRTB [ RData GData BData ] true [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- XI 4 IMLRTB [ RDProc GDProc BDProc ] true [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- XJ 4 IMLRTB [ RDFile GDFile BDFile ] true [0 1 0 1 0 1] [ 1 10 1 10 1 10 ] DoImage4
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- showpage
-
-} bind def % T1T4Tests
-
-% -----------------------------------------------------------------------
-%
-% Type 3 Tests
-
-/T3Tests {
- % Use an unusual (unpleasant?) underlying color
- .6 .95 .4 setrgbcolor clippath fill
-
- 0 0 0 setrgbcolor
- TitleFont setfont
- 200 760 moveto (Image Type 3 Tests) show
- 200 740 moveto (Rotation Angle = ) show IR 3 string cvs show
- 170 720 moveto (Colorspace = ) show CSpaceName show
- LegendFont setfont
-
- .4 .1 .7 setrgbcolor % contrasting color for stencil masking
-
- /WM WD def
- /HM HD def
- /SX SX 2 mul def /SY SY 2 mul def
- /YY 780 SY sub def
- MaskGen
- XA IMLRTB MaskData [1 0] DoImageMask
-
- /RGBData WD HD mul 3 mul string def
- { X Y WD mul add 3 mul RGBData
- dup 2 index R 255 mul cvi put
- dup 2 index 1 add G 255 mul cvi put
- exch 2 add B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi decode
- XH 8 IMLRTB RGBData false [0 1 0 1 0 1] DoImage1
- /SX SX 2 div def /SY SY 2 div def
-
-% ----------------------------------------------------------------------
-% InterleaveType 1, BPC==8, WM=WD, HM=HD
-% IT 1 is what GS calls "chunky pixel"
- /YY YA def
- TX YY SY add moveto (\nIntType 1\nBPC=8) blockshow
-
- % Generate the MaskData first
- 8 MaskGenBPC
-
- % Generate the Data Image (uses the MaskData)
- /RGBData WD HD mul 4 mul string def
- { X Y WD mul add 4 mul % 4 bytes Mask,Red,Green,Blue
- RGBData
- dup 2 index MaskData X Y WB mul add get put
- dup 2 index 1 add R 255 mul cvi put
- dup 2 index 2 add G 255 mul cvi put
- exch 3 add B 255 mul cvi put
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 1 DoImage3
- XB 8 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 1 DoImage3
- XC 8 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 1 DoImage3
- XD 8 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XE 8 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XF 8 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XG 8 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XH 8 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XI 8 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 1 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 1, BPC==12, WM=WD, HM=HD
-% IT 1 is what GS calls "chunky pixel"
- /YY YB def
- TX YY SY add moveto (\nIntType 1\nBPC=12) blockshow
-
- % Generate the MaskData first
- 12 MaskGenBPC
-
- % Generate the Data Image (uses the MaskData)
- /RGBData WD HD mul 6 mul string def
- { X Y WD mul add 6 mul % 6 bytes Mask,Red,Green,Blue
- RGBData
- dup 2 index
- MaskData X 1.5 mul .5 add cvi
- Y WB mul add get % get the aligned mask byte (hi or lo)
- 0 eq { 0 } { 1 } ifelse
- put12bit
- dup 2 index 1.5 add R put12bit
- dup 2 index 3.0 add G put12bit
- exch 4.5 add B put12bit
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 12 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 1 DoImage3
- XB 12 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 1 DoImage3
- XC 12 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 1 DoImage3
- XD 12 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XE 12 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XF 12 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XG 12 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XH 12 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XI 12 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 1 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 1, BPC==4, WM=WD, HM=HD
-% IT 1 is what GS calls "chunky pixel"
- /YY YC def
- TX YY SY add moveto (\nIntType 1\nBPC=4) blockshow
-
- % Generate the MaskData first
- 4 MaskGenBPC
-
- % Generate the Data Image (uses the MaskData)
- /RGBData WD HD mul 2 mul string def
- { X Y WD mul add 2 mul % 2 bytes Mask,Red,Green,Blue
- RGBData
- dup 2 index MaskData X 2 div cvi Y WB mul add get
- X 1 and 0 eq { 128 div cvi } { 1 and } ifelse
- put4bit
- dup 2 index 0.5 add R put4bit
- dup 2 index 1.0 add G put4bit
- exch 1.5 add B put4bit
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 4 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 1 DoImage3
- XB 4 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 1 DoImage3
- XC 4 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 1 DoImage3
- XD 4 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XE 4 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XF 4 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XG 4 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XH 4 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 1 DoImage3
- XI 4 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 1 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 2, BPC==8, WM=WD, HM=HD
-% IT 2 is line interleave -- Mask line follwoed by Data line
-% RGB Image Data must be chunky (MultipleDatasources==false).
- /YY YD def
- TX YY SY add moveto (\nIntType 2\nBPC=8) blockshow
-
- % Generate the MaskData first
- MaskGen
-
- % Generate the Data Image (uses the MaskData)
- /BPL WD 3 mul WB add cvi def % BytesPerLine
- /RGBData BPL HD mul string def
- { X 3 mul Y BPL mul add WB add % 3 bytes Red,Green,Blue + Mask Bytes
- X 0 eq {
- RGBData 1 index WB sub
- MaskData Y WB mul WB getinterval
- putinterval
- } if
- RGBData
- dup 2 index R 255 mul cvi put
- dup 2 index 1 add G 255 mul cvi put
- exch 2 add B 255 mul cvi put
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 2 DoImage3
- XB 8 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 2 DoImage3
- XC 8 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 2 DoImage3
- XD 8 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XE 8 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XF 8 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XG 8 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XH 8 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XI 8 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 2 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 2, BPC==12, WM=WD, HM=HD
- /YY YE def
- TX YY SY add moveto (\nIntType 2\nBPC=12) blockshow
-
- % Generate the Data Image (uses the MaskData)
- /BPL WD 36 mul 7 add 8 div cvi WB add def % BytesPerLine
- /RGBData BPL HD mul string def
- { X 36 mul 8 div Y BPL mul add WB add
- X 0 eq {
- RGBData 1 index WB sub cvi
- MaskData Y WB mul WB getinterval
- putinterval
- } if
- RGBData
- dup 2 index R put12bit
- dup 2 index 1.5 add G put12bit
- exch 3.0 add B put12bit
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 12 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 2 DoImage3
- XB 12 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 2 DoImage3
- XC 12 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 2 DoImage3
- XD 12 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XE 12 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XF 12 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XG 12 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XH 12 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XI 12 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 2 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 2, BPC==4, WM=WD, HM=HD
- /YY YF def
- TX YY SY add moveto (\nIntType 2\nBPC=4) blockshow
-
- % Generate the Data Image (uses the MaskData)
- /BPL WD 12 mul 7 add 8 div cvi WB add def % BytesPerLine
- /RGBData BPL HD mul string def
- { X 12 mul 8 div Y BPL mul add WB add
- X 0 eq {
- RGBData 1 index WB sub cvi
- MaskData Y WB mul WB getinterval
- putinterval
- } if
- RGBData
- dup 2 index R put4bit
- dup 2 index 0.5 add G put4bit
- exch 1.0 add B put4bit
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 4 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 2 DoImage3
- XB 4 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 2 DoImage3
- XC 4 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 2 DoImage3
- XD 4 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XE 4 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XF 4 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XG 4 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XH 4 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XI 4 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 2 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 2, BPC==8, WM=.6*WD, HM=HD/2
-% IT 2 is line interleave -- Mask line follwoed by Data line
-% RGB Image Data must be chunky (MultipleDatasources==false).
- /YY YG def
- TX YY SY add moveto (\nIntType 2\nBPC=8\nWM=.6*WD\nHM=HD/2) blockshow
-
- % Generate the MaskData first
- /WM WD .6 mul cvi def
- /HM HD 2 div cvi def
- /saveHD HD def
- /HD HM 2 mul def % make HD even for this exercise
- MaskGen
-
- % Generate the Data Image (uses the MaskData)
- /BPL WD 3 mul def % BytesPerLine RGB Data
- /RGBData BPL HD mul WB HM mul add string def
- { X 3 mul Y BPL mul add Y 2 div cvi 1 add WB mul add % 3 bytes Red,Green,Blue + Mask
- X 0 eq Y 1 and 0 eq and { % Do one row of Mask every other image row
- RGBData 1 index WB sub
- MaskData Y 2 div cvi WB mul WB getinterval
- putinterval
- } if
- RGBData
- dup 2 index R 255 mul cvi put
- dup 2 index 1 add G 255 mul cvi put
- exch 2 add B 255 mul cvi put
- }
- ImageGen
-
-%DEBUG /xx (xx) (w) file def
-%DEBUG 0 1 HM 1 sub { MaskData exch WB mul WB getinterval xx exch writehexstring xx (\n) writestring } for
-%DEBUG xx (----------------------------------------------------------------\n) writestring
-%DEBUG 0 2 HD 1 sub {
-%DEBUG RGBData 1 index BPL mul 2 index 2 div cvi WB mul add
-%DEBUG WB getinterval xx exch writehexstring xx (\n) writestring
-%DEBUG RGBData 1 index BPL mul 2 index 2 div cvi 1 add WB mul add
-%DEBUG BPL getinterval xx exch writehexstring xx (\n) writestring
-%DEBUG RGBData 1 index 1 add BPL mul 2 index 2 div cvi 1 add WB mul add
-%DEBUG BPL getinterval xx exch writehexstring xx (\n) writestring
-%DEBUG pop
-%DEBUG } for
-%DEBUG xx closefile
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 2 DoImage3
- XB 8 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 2 DoImage3
- XC 8 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 2 DoImage3
- XD 8 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XE 8 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XF 8 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XG 8 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XH 8 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XI 8 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 2 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- /HD saveHD def % put odd HD back
-
-% ----------------------------------------------------------------------
-% InterleaveType 2, BPC==8, WM=1.3*WD, HM=2*HD
-% IT 2 is line interleave -- Mask line follwoed by Data line
-% RGB Image Data must be chunky (MultipleDatasources==false).
- /YY YH def
- TX YY SY add moveto (\nIntType 2\nBPC=8\nWM=1.3*WD\nHM=2*HD) blockshow
-
- % Generate the MaskData first
- /WM WD 1.3 mul cvi def
- /HM HD 2 mul def
- MaskGen
-
- % Generate the Data Image (uses the MaskData)
- /HR HM HD div cvi def
- /BPL WD 3 mul WB HR mul add cvi def % BytesPerLine
- /RGBData BPL HD mul string def
- { X 3 mul Y BPL mul add WB HR mul add % 3 bytes Red,Green,Blue + Mask Bytes
- X 0 eq { % Do HM/HD rows of Mask
- RGBData 1 index WB HR mul sub
- MaskData Y WB HR mul mul WB HR mul getinterval
- putinterval
- } if
- RGBData
- dup 2 index R 255 mul cvi put
- dup 2 index 1 add G 255 mul cvi put
- exch 2 add B 255 mul cvi put
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 2 DoImage3
- XB 8 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 2 DoImage3
- XC 8 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 2 DoImage3
- XD 8 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XE 8 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XF 8 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XG 8 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XH 8 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XI 8 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 2 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-% ----------------------------------------------------------------------
-% InterleaveType 2, BPC==12, WM=1.3*WD, HM=2*HD
- /YY YI def
- TX YY SY add moveto (\nIntType 2\nBPC=12\nWM=1.3*WD\nHM=2*HD) blockshow
-
- % Generate the Data Image (uses the MaskData)
- /HR HM HD div cvi def
- /BPL WD 36 mul 7 add 8 div cvi WB HR mul add def % BytesPerLine
- /RGBData BPL HD mul string def
- { X 36 mul 8 div Y BPL mul add WB HR mul add
- X 0 eq {
- RGBData 1 index WB HR mul sub cvi
- MaskData Y WB HR mul mul WB HR mul getinterval
- putinterval
- } if
- RGBData
- dup 2 index R put12bit
- dup 2 index 1.5 add G put12bit
- exch 3.0 add B put12bit
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 12 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 2 DoImage3
- XB 12 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 2 DoImage3
- XC 12 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 2 DoImage3
- XD 12 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XE 12 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XF 12 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XG 12 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XH 12 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XI 12 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 2 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 2, BPC==4, WM=1.3*WD, HM=2*HD
- /YY YJ def
- TX YY SY add moveto (\nIntType 2\nBPC=4\nWM=1.3*WD\nHM=2*HD) blockshow
-
- % Generate the Data Image (uses the MaskData)
- /HR HM HD div cvi def
- /BPL WD 12 mul 7 add 8 div cvi WB HR mul add def % BytesPerLine
- /RGBData BPL HD mul string def
- { X 12 mul 8 div Y BPL mul add WB HR mul add
- X 0 eq {
- RGBData 1 index WB HR mul sub cvi
- MaskData Y WB HR mul mul WB HR mul getinterval
- putinterval
- } if
- RGBData
- dup 2 index R put4bit
- dup 2 index 0.5 add G put4bit
- exch 1.0 add B put4bit
- }
- ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 4 IMLRTB RGBData false [0 1] [1 0 1 0 1 0] 2 DoImage3
- XB 4 IMLRTB RGBData false [1 0] [1 0 1 0 1 0] 2 DoImage3
- XC 4 IMLRTB RGBData false [0 1] [0 1 0 1 0 1] 2 DoImage3
- XD 4 IMLRTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XE 4 IMLRBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XF 4 IMRLTB RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XG 4 IMRLBT RGBData false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XH 4 IMLRTB RGBDProc false [1 0] [0 1 0 1 0 1] 2 DoImage3
- XI 4 IMLRTB RGBDFile false [1 0] [0 1 0 1 0 1] 2 DoImage3
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
- showpage
-% ----------------------------------------------------------------------
-
- % Use an unusual (unpleasant?) underlying color
- .6 .95 .4 setrgbcolor clippath fill
-
- 0 0 0 setrgbcolor
- TitleFont setfont
- 200 760 moveto (Image Type 3 Tests) show
- 200 740 moveto (Rotation Angle = ) show IR 3 string cvs show
- 200 720 moveto (InterleaveType 3) show
- 170 700 moveto (Colorspace = ) show CSpaceName show
- LegendFont setfont
-
- .4 .1 .7 setrgbcolor % contrasting color for stencil masking
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==8, WM=WD, HM=HD
-% IT 3 is line interleave -- Mask and Data in separate sources
-% RGB Image Data chunky (MultipleDatasources==false).
- /YY YA def
- TX YY SY add moveto (BPC=8\nMulti\nfalse) blockshow
-
- % Generate the MaskData first
- /WM WD def
- /HM HD def
- MaskGen
-
- % Generate the Data Image
- /RGBData WD HD mul 3 mul string def
- { X Y WD mul add 3 mul RGBData
- dup 2 index R 255 mul cvi put
- dup 2 index 1 add G 255 mul cvi put
- exch 2 add B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB [ MaskData RGBData ] false [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 8 IMLRTB [ MaskData RGBData ] false [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 8 IMLRTB [ MaskData RGBData ] false [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 8 IMLRTB [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 8 IMLRBT [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 8 IMRLTB [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 8 IMRLBT [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 8 IMLRTB [ MaskDProc RGBDProc ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 8 IMLRTB [ MaskDFile RGBDFile ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==12, WM=WD, HM=HD
- /YY YB def
- TX YY SY add moveto (BPC=12\nMulti\nfalse) blockshow
-
- /RGBData WD 36 mul 7 add 8 div cvi HD mul string def
- {
- X 36 mul 8 div Y WD 36 mul 7 add 8 div cvi mul add
- RGBData 1 index R put12bit
- RGBData 1 index 1.5 add G put12bit
- RGBData exch 3 add B put12bit
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 12 IMLRTB [ MaskData RGBData ] false [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 12 IMLRTB [ MaskData RGBData ] false [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 12 IMLRTB [ MaskData RGBData ] false [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 12 IMLRTB [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 12 IMLRBT [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 12 IMRLTB [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 12 IMRLBT [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 12 IMLRTB [ MaskDProc RGBDProc ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 12 IMLRTB [ MaskDFile RGBDFile ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==4, WM=WD, HM=HD
- /YY YC def
- TX YY SY add moveto (BPC=4\nMulti\nfalse) blockshow
-
- /RGBData WD 12 mul 7 add 8 div cvi HD mul string def
- {
- X 12 mul 8 div Y WD 12 mul 7 add 8 div cvi mul add
- RGBData 1 index R put4bit
- RGBData 1 index 0.5 add G put4bit
- RGBData exch 1.0 add B put4bit
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 4 IMLRTB [ MaskData RGBData ] false [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 4 IMLRTB [ MaskData RGBData ] false [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 4 IMLRTB [ MaskData RGBData ] false [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 4 IMLRTB [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 4 IMLRBT [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 4 IMRLTB [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 4 IMRLBT [ MaskData RGBData ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 4 IMLRTB [ MaskDProc RGBDProc ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 4 IMLRTB [ MaskDFile RGBDFile ] false [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RGBData (RGB) RGBDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==8, WM=WD, HM=HD
-% IT 3 is line interleave -- Mask and Data in separate sources
-% RGB Image Data seprate (MultipleDatasources==true).
- /YY YA def
- TX YY SY add moveto (BPC=8\nMulti\ntrue) blockshow
-
- % Generate the MaskData first
- MaskGen
-
- % Generate the Data Image
- WD HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- { X Y WD mul add
- RData 1 index R 255 mul cvi put
- GData 1 index G 255 mul cvi put
- BData exch B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 8 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 8 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 8 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 8 IMLRBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 8 IMRLTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 8 IMRLBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 8 IMLRTB [ MaskDProc [RDProc GDProc BDProc]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 8 IMLRTB [ MaskDFile [RDFile GDFile BDFile]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==8, WM=WD, HM=HD
-% IT 3 is line interleave -- Mask and Data in separate sources
-% RGB Image Data seprate (MultipleDatasources==true).
- /YY YD def
- TX YY SY add moveto (BPC=8\nMulti\ntrue) blockshow
-
- % Generate the MaskData first
- MaskGen
-
- % Generate the Data Image
- WD HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- { X Y WD mul add
- RData 1 index R 255 mul cvi put
- GData 1 index G 255 mul cvi put
- BData exch B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 8 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 8 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 8 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 8 IMLRBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 8 IMRLTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 8 IMRLBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 8 IMLRTB [ MaskDProc [RDProc GDProc BDProc]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 8 IMLRTB [ MaskDFile [RDFile GDFile BDFile]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==12, WM=WD, HM=HD
- /YY YE def
- TX YY SY add moveto (BPC=12\nMulti\ntrue) blockshow
-
- WD 3 mul 1 add 2 div cvi HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- {
- X 3 mul 2 div Y WD 3 mul 1 add 2 div cvi mul add
- RData 1 index R put12bit
- GData 1 index G put12bit
- BData exch B put12bit
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 12 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 12 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 12 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 12 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 12 IMLRBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 12 IMRLTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 12 IMRLBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 12 IMLRTB [ MaskDProc [RDProc GDProc BDProc]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 12 IMLRTB [ MaskDFile [RDFile GDFile BDFile]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==4, WM=WD, HM=HD
- /YY YF def
- TX YY SY add moveto (BPC=4\nMulti\ntrue) blockshow
-
- WD 1 add 2 div cvi HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- {
- X 2 div Y WD 1 add 2 div cvi mul add
- RData 1 index R put4bit
- GData 1 index G put4bit
- BData exch B put4bit
- } ImageGen
-
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 4 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 4 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 4 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 4 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 4 IMLRBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 4 IMRLTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 4 IMRLBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 4 IMLRTB [ MaskDProc [RDProc GDProc BDProc]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 4 IMLRTB [ MaskDFile [RDFile GDFile BDFile]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==8, WM=.9*WD, HM=1.1*HD
-% IT 3 is line interleave -- Mask and Data in separate sources
-% RGB Image Data seprate (MultipleDatasources==true).
- /YY YG def
- TX YY SY add moveto (BPC=8\nMulti\ntrue\nWM=.9*WD\nHM=1.1*HD) blockshow
-
- /WM 0.9 WD mul cvi def
- /HM 1.1 HD mul cvi def
- % Generate the MaskData first
- MaskGen
-
- % Generate the Data Image
- WD HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- { X Y WD mul add
- RData 1 index R 255 mul cvi put
- GData 1 index G 255 mul cvi put
- BData exch B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 8 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 8 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 8 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 8 IMLRBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 8 IMRLTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 8 IMRLBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 8 IMLRTB [ MaskDProc [RDProc GDProc BDProc]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 8 IMLRTB [ MaskDFile [RDFile GDFile BDFile]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==12, WM=WD, HM=HD
- /YY YI def
- TX YY SY add moveto (BPC=12\nMulti\ntrue\nWM=.9*WD\nHM=1.1*HD) blockshow
-
- WD 3 mul 1 add 2 div cvi HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- {
- X 3 mul 2 div Y WD 3 mul 1 add 2 div cvi mul add
- RData 1 index R put12bit
- GData 1 index G put12bit
- BData exch B put12bit
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 12 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 12 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 12 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 12 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 12 IMLRBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 12 IMRLTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 12 IMRLBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 12 IMLRTB [ MaskDProc [RDProc GDProc BDProc]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 12 IMLRTB [ MaskDFile [RDFile GDFile BDFile]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==4, WM=WD, HM=HD
- /YY YJ def
- TX YY SY add moveto (BPC=4\nMulti\ntrue\nWM=.9*WD\nHM=1.1*HD) blockshow
-
- WD 1 add 2 div cvi HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- {
- X 2 div Y WD 1 add 2 div cvi mul add
- RData 1 index R put4bit
- GData 1 index G put4bit
- BData exch B put4bit
- } ImageGen
-
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 4 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 4 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 4 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 4 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 4 IMLRBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 4 IMRLTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 4 IMRLBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 4 IMLRTB [ MaskDProc [RDProc GDProc BDProc]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 4 IMLRTB [ MaskDFile [RDFile GDFile BDFile]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
-% ----------------------------------------------------------------------
-% InterleaveType 3, BPC==8, WM=1.1*WD, HM=.9*HD
-% IT 3 is line interleave -- Mask and Data in separate sources
-% RGB Image Data seprate (MultipleDatasources==true).
- /YY YH def
- TX YY SY add moveto (BPC=8\nMulti\ntrue\nWM=1.1*WD\nHM=.9*HD) blockshow
-
- /WM 1.1 WD mul cvi def
- /HM 0.9 HD mul cvi def
- % Generate the MaskData first
- MaskGen
-
- % Generate the Data Image
- WD HD mul /RData 1 index string def
- /GData 1 index string def
- /BData exch string def
- { X Y WD mul add
- RData 1 index R 255 mul cvi put
- GData 1 index G 255 mul cvi put
- BData exch B 255 mul cvi put
- } ImageGen
-
- % X BPC matrix source multi MaskDecode DataDecode IT DoImage3 -
- XA 8 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [1 0 1 0 1 0] 3 DoImage3
- XB 8 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [1 0 1 0 1 0] 3 DoImage3
- XC 8 IMLRTB [ MaskData [RData GData BData] ] true [0 1] [0 1 0 1 0 1] 3 DoImage3
- XD 8 IMLRTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XE 8 IMLRBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XF 8 IMRLTB [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XG 8 IMRLBT [ MaskData [RData GData BData] ] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XH 8 IMLRTB [ MaskDProc [RDProc GDProc BDProc]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- XI 8 IMLRTB [ MaskDFile [RDFile GDFile BDFile]] true [1 0] [0 1 0 1 0 1] 3 DoImage3
- MaskData (Mask) MDF CheckFileTail % Check that the correct amount of data was consumed
- RData (Red) RDF CheckFileTail % Check that the correct amount of data was consumed
- GData (Grn) GDF CheckFileTail % Check that the correct amount of data was consumed
- BData (Blu) BDF CheckFileTail % Check that the correct amount of data was consumed
-
- showpage
-} bind def % T3Tests
-
-
-% ----------------------------------------------------------------------
-% Do the various rotations
-%
-/CSpace /DeviceRGB def
-
-[ 0 10 -10 45 90 180 270 ]
-pop [ 0 ] % delete this line to enable tests
-{ /IR exch def T1T4Tests } forall
-
-[ 0 10 -10 45 90 180 270 ]
-pop [ 0 ] % delete this line to enable tests
-{ /IR exch def T3Tests } forall
-
-/CSpace [ /DeviceN [/Blue /Red /Green] /DeviceRGB { } ] def
-
-[ 0 10 -10 45 90 180 270 ]
-pop [ 0 ] % delete this line to enable tests
-{ /IR exch def T1T4Tests } forall
-
-[ 0 10 -10 45 90 180 270 ]
-pop [ 0 ] % delete this line to enable tests
-{ /IR exch def T3Tests } forall
diff --git a/Master/tlpkg/tlgs/lib/impath.ps b/Master/tlpkg/tlgs/lib/impath.ps deleted file mode 100644 index 07aa3128054..00000000000 --- a/Master/tlpkg/tlgs/lib/impath.ps +++ /dev/null @@ -1,179 +0,0 @@ -% Copyright (C) 1992, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: impath.ps 6300 2005-12-28 19:56:24Z giles $
-% impath.ps
-% Reverse-rasterize a bitmap to produce a Type 1 outline.
-% (This was formerly a Ghostscript operator implemented in C.)
-
-% <image> <width> <height> <wx> <wy> <ox> <oy> <string>
-% type1imagepath <substring>
-% Converts an image (bitmap) description of a character into
-% a scalable description in Adobe Type 1 format. The
-% current transformation matrix should be the same as the
-% FontMatrix of the font in which this character will be
-% used: this establishes the scaling relationship between
-% image pixels (the image is assumed to be 1 unit high in
-% user space) and the character coordinate system used in
-% the scalable description. wx and wy are the character
-% width, and ox and oy are the character origin relative
-% to the lower left corner of the bitmap, in *pixels*.
-% The image is assumed to be stored in left-to-right,
-% top-to-bottom order. Note that this is not consistent
-% with the `image' operator's interpretation of the CTM.
-% All coordinates in the scalable description are rounded to
-% integers, so the coefficients in the FontMatrix should
-% be on the order of 1/N for some value of N that is
-% either a multiple of the height/width or is large
-% compared to the width and height. (There is a
-% convention, which some PostScript programs rely on, that
-% N=1000.)
-% Note that the encoded description has *not* been subjected
-% to CharString encryption, which is necessary before the
-% description can be given to type1addpath: to do this,
-% follow the type1imagepath with
-% 4330 exch dup .type1encrypt exch pop
-% If the description is too complex to fit into the supplied
-% string, a limitcheck error results. A good rule of
-% thumb is that the size of the string should be about 6
-% times the number of 1-bits in the image that are not
-% completely surrounded by other 1-bits.
-
-% Import the Type 1 opcodes.
-(type1ops.ps) runlibfile
-
-100 dict
-dup /type1imagepath_dict exch def
-begin
-
-/rc { round cvi } bind def
-/moving [/rmoveto /hmoveto /vmoveto] def
-/drawing [/rlineto /hlineto /vlineto] def
-
-% Convert the current path to a Type 1 token array.
-/putxy % x y ops -> cs_elements
- { 3 -1 roll dup x sub rc exch /x exch def
- 3 -1 roll dup y sub rc exch /y exch def
- % stack: ops dx dy
- dup 0 eq
- { % dy = 0, use hmoveto/lineto
- pop exch 1 get
- }
- { 1 index 0 eq
- { % dx = 0, use vmoveto/lineto
- exch pop exch 2 get
- }
- { % use rmoveto/rlineto
- 3 -1 roll 0 get
- }
- ifelse
- }
- ifelse
- } bind def
-/pathtotype1 % -> charstack
- { 3 dict begin /x 0 def /y 0 def
- mark
- { moving putxy
- }
- { drawing putxy
- }
- { % Convert curve to relative form
- x y 3
- { exch neg 7 index add rc
- exch neg 6 index add rc
- 8 -2 roll
- }
- repeat /y exch def /x exch def
- 1 index 0 eq 5 index 0 eq and % dy1=dx3=0, hv
- { 5 -1 roll pop exch pop /hvcurveto
- }
- { dup 0 eq 6 index 0 eq and % dx1=dy3=0, vh
- { 6 -1 roll pop pop /vhcurveto
- }
- { /rrcurveto % none of the above
- }
- ifelse
- }
- ifelse
- }
- { /closepath
- }
- pathforall end
- } bind def
-
-end % type1imagepath_dict
-
-% The main program
-/type1imagepath % image width height wx wy ox oy string ->
- % substring
- { type1imagepath_dict begin
- /tsave save def
- /ostring exch def
- /oy exch def /ox exch def
- /wy exch def /wx exch def
- /height exch def /width exch def
- /data exch def
-
- /ofilter ostring /NullEncode filter def
- /raster width 7 add 8 idiv def
-
-% Construct the coordinate transformation.
- height dup scale
- matrix currentmatrix matrix invertmatrix setmatrix
-
-% Determine the left side bearing.
- /lsbx width
- 0 1 width 1 sub
- { dup dup 8 idiv 0 exch
- raster raster height mul 1 sub
- { data exch get or }
- for exch 8 mod bitshift 128 and 0 ne
- { exch pop exit }
- if pop
- }
- for def
-
-% Compute and encode the origin, width, and side bearing.
- mark
- ox oy dtransform
- rc /opty exch def rc /optx exch def
- wx wy dtransform
- rc /iwy exch def rc /iwx exch def
- lsbx ox sub 0 dtransform
- rc /ilsby exch def rc /ilsbx exch def
- ilsbx
- iwy 0 ne ilsby 0 ne or
- { ilsby iwx iwy /sbw }
- { iwx /hsbw }
- ifelse
- ofilter charstack_write
-
-% Flip over the Y axis, because the image is stored top-to-bottom.
- [1 0 0 -1 0 height] concat
-% Account for the character origin.
- lsbx oy translate
-% Trace the outline.
- newpath
- width height data .imagepath
- gsave matrix setmatrix pathtotype1 grestore
- ofilter charstack_write
-% Terminate the output
- mark /endchar ofilter charstack_write
-
- ofilter .fileposition ofilter closefile % flush buffers
- ostring 0 3 -1 roll getinterval
- tsave restore
- end
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/jispaper.ps b/Master/tlpkg/tlgs/lib/jispaper.ps deleted file mode 100644 index 252cfb8f1da..00000000000 --- a/Master/tlpkg/tlgs/lib/jispaper.ps +++ /dev/null @@ -1,27 +0,0 @@ -% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: jispaper.ps 6300 2005-12-28 19:56:24Z giles $
-% Select JIS B paper sizes for b0...b6.
-
-userdict begin
- /b0 /jisb0 load def
- /b1 /jisb1 load def
- /b2 /jisb2 load def
- /b3 /jisb3 load def
- /b4 /jisb4 load def
- /b5 /jisb5 load def
- /b6 /jisb6 load def
-end
diff --git a/Master/tlpkg/tlgs/lib/jobseparator.ps b/Master/tlpkg/tlgs/lib/jobseparator.ps deleted file mode 100644 index 1d1d008937f..00000000000 --- a/Master/tlpkg/tlgs/lib/jobseparator.ps +++ /dev/null @@ -1,4 +0,0 @@ -% Execute the "real" system version of the ^D to separate jobs
-% when -dJOBDSERVER is being used.
-% $Id: jobseparator.ps 8022 2007-06-05 22:23:38Z giles $
-<04> cvn .systemvar exec
diff --git a/Master/tlpkg/tlgs/lib/landscap.ps b/Master/tlpkg/tlgs/lib/landscap.ps deleted file mode 100644 index 3dc9d9a0777..00000000000 --- a/Master/tlpkg/tlgs/lib/landscap.ps +++ /dev/null @@ -1,31 +0,0 @@ -%!
-% landscap.ps
-%
-% This file can be prepended to most PostScript pages to force
-% rotation to "landscape" mode.
-%
-% There are (at least) four possible ways to reasonably position a
-% page after rotation. Any of the four old corners (llx,lly e.g.)
-% can be moved to match the corresonding new corner.
-% By uncommmenting the appropriate line below (i.e., remove the
-% leading '%'), any such positioning can be chosen for positive or
-% negative rotation. The comments at the end of each "rotate" line
-% indicate the ORIGINAL corner to be aligned. For example, as given
-% below, the lower left hand corner is aligned. When viewed, this
-% corner will have moved to the urx,lly corner.
-%
-% originally by James E. Burns, 3/8/93, burns@nova.bellcore.com
-% $Id: landscap.ps 6300 2005-12-28 19:56:24Z giles $
-%
-gsave clippath pathbbox grestore
-4 dict begin
-/ury exch def /urx exch def /lly exch def /llx exch def
-%90 rotate llx neg ury neg translate % llx,ury
-90 rotate llx neg llx urx sub lly sub translate % llx,lly
-%90 rotate ury lly sub urx sub ury neg translate % urx,ury
-%90 rotate ury lly sub urx sub llx urx sub lly sub translate % urx,lly
-%-90 rotate urx neg lly neg translate % urx,lly
-%-90 rotate urx neg urx llx sub ury sub translate % urx,ury
-%-90 rotate llx lly add ury sub urx llx sub ury sub translate % llx,ury
-%-90 rotate llx lly add ury sub lly neg translate % llx,lly
-end
diff --git a/Master/tlpkg/tlgs/lib/level1.ps b/Master/tlpkg/tlgs/lib/level1.ps deleted file mode 100644 index 75689d3680d..00000000000 --- a/Master/tlpkg/tlgs/lib/level1.ps +++ /dev/null @@ -1,3 +0,0 @@ -%!
-% $Id: level1.ps 6300 2005-12-28 19:56:24Z giles $
-/.setlanguagelevel where { pop 1 .setlanguagelevel } if
diff --git a/Master/tlpkg/tlgs/lib/lines.ps b/Master/tlpkg/tlgs/lib/lines.ps deleted file mode 100644 index ebaa3e44450..00000000000 --- a/Master/tlpkg/tlgs/lib/lines.ps +++ /dev/null @@ -1,165 +0,0 @@ -%!
-% Copyright (C) 1989, 1990, 1992, 1994, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: lines.ps 6300 2005-12-28 19:56:24Z giles $
-% Test line rendering (stroke).
-
-% Exercise the miter limit. The left column of lines should bevel at
-% 90 degrees, the right column at 60 degrees.
-
-gsave
-1.8 setlinewidth
-0 setgray
-15 15 scale
--5 5 translate
-[1.415 2.0]
- { setmiterlimit 12 0 translate 0 0 moveto
- 10 30 360
- { gsave 5 0 rlineto rotate 2.5 0 rlineto
- gsave 0 setlinewidth 1 0 0 setrgbcolor stroke grestore
- strokepath 0 setlinewidth stroke
- grestore
- 0 4 rmoveto
- } for
- } forall
-
-showpage
-grestore
-
-% Exercise all the combinations of cap and join styles
-% for one-line, two-line, and closed paths.
-
-gsave
-
-/drawlines {
-gsave
-2.0 setmiterlimit
-2.0 setlinewidth
-6 6 scale
-5 20 translate
-{0 1 2} % line cap
- { setlinecap gsave
- {0 1 2} % line join
- { setlinejoin gsave
- { {currentpoint lineto}
- {3 7 lineto}
- {3 7 lineto 5 1 lineto}
- {3 7 lineto 6 3 lineto closepath}
- }
- { gsave 0 0 moveto exec
- gsave stroke grestore
- 0.5 setlinewidth 1 0 0 setrgbcolor stroke
- grestore 8 0 translate
- } forall
- grestore 35 0 translate
- } forall
- grestore 0 20 translate
- } forall
-grestore
-} def
-/xflip
- { 8.5 72 mul 0 translate -1 1 scale
- } def
-/rot90
- { 90 rotate 0 -9.75 72 mul translate
- } def
-/rot180
- { rot90 rot90
- } def
-/rot270
- { rot180 rot90
- } def
-
-drawlines showpage
-gsave xflip drawlines grestore showpage
-gsave rot90 drawlines grestore showpage
-gsave rot90 xflip drawlines grestore showpage
-gsave drawlines rot180 showpage
-gsave rot180 xflip drawlines grestore showpage
-gsave rot270 drawlines grestore showpage
-gsave rot270 xflip drawlines grestore showpage
-grestore
-
-% Here are some boundary conditions, contributed by Mark Rawling.
-
-gsave
-1 setlinecap
-2.6 setmiterlimit
-3.0 setlinewidth
-
-5 5 scale
-10 20 translate
-
-% [ 0.5 sqrt dup dup dup neg exch 0 0 ] concat % 45 rotate
-
-{0 1 2} % line join
-{
- setlinejoin gsave
- 0 0 moveto 0 10 lineto 10 0 lineto gsave stroke grestore
- 15 0 translate
- 0 0 moveto 0 10 lineto 10 20 lineto gsave stroke grestore
- 15 0 translate
- 10 0 moveto 10 10 lineto 0 20 lineto gsave stroke grestore
- 15 0 translate
- 10 0 moveto 10 10 lineto 0 0 lineto gsave stroke grestore
- grestore
- gsave
- 0 20 translate
- 0 20 moveto 0 10 lineto 10 20 lineto gsave stroke grestore
- 15 0 translate
- 0 20 moveto 0 10 lineto 10 0 lineto gsave stroke grestore
- 15 0 translate
- 10 20 moveto 10 10 lineto 0 0 lineto gsave stroke grestore
- 15 0 translate
- 10 20 moveto 10 10 lineto 0 20 lineto gsave stroke grestore
- grestore 60 0 translate
-} forall
-
-showpage
-grestore
-
-% Test narrow lines at a variety of angles.
-
-gsave
-
-/rad 120 def
-/ray { gsave rotate 0 0 moveto rad 0 rlineto stroke grestore } def
-/star
- { newpath gsave
- gsave 0.5 setgray 0 0 rad 0 360 arc stroke grestore
- 0 90 359
- { rotate
- 0 3 14 { ray } for
- 15 15 89 { ray } for
- } for
- grestore
- } def
-
-0 setgray
-150 150 translate
-[ [ 0 0.5 1 ] [ 1.5 2 2.5 ] [ 3 3.5 4 ] ]
- { gsave
- { setlinewidth star
- 250 0 translate
- } forall
- grestore 0 250 translate
- } forall
-
-grestore showpage
-
-% End
-
-quit
diff --git a/Master/tlpkg/tlgs/lib/markhint.ps b/Master/tlpkg/tlgs/lib/markhint.ps deleted file mode 100644 index 5143b8643fc..00000000000 --- a/Master/tlpkg/tlgs/lib/markhint.ps +++ /dev/null @@ -1,130 +0,0 @@ -% Copyright (C) 1994, 1995, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: markhint.ps 6300 2005-12-28 19:56:24Z giles $
-% markhint.ps
-% Draw the hints for a Type 1 font.
-
-(type1ops.ps) runlibfile
-
-/mhsetup % <matrix> <print> mhsetup -
- { /mhprint exch def
- /mhmx exch def
- /mhdash 0 9 gsave initmatrix dtransform grestore idtransform add abs def
- gsave
- clippath pathbbox
- 2 index sub /bbh exch def
- 2 index sub /bbw exch def
- /bby exch def
- /bbx exch def
- grestore
- } def
-
-/markfonthints % <matrix> <print> markfonthints -
- { mhsetup
- } def
-
-/hmark % <y> hmark -
- { bbx exch moveto bbw 0 rlineto stroke
- } def
-/hsmark % <y0> <dy> hsmark -
- { 1 index add exch gsave
- [mhdash] 0 setdash 0 exch mhmx transform exch pop hmark
- [mhdash 2 div dup 2 mul] 0 setdash 0 exch mhmx transform exch pop hmark
- grestore
- } def
-/vmark % <x> vmark -
- { bby moveto 0 bbh rlineto stroke
- } def
-/vsmark % <x0> <dx> vsmark -
- { 1 index add exch gsave
- [mhdash] mhdash setdash 0 mhmx transform pop vmark
- [mhdash 2 div dup 2 mul] 0 setdash 0 mhmx transform pop vmark
- grestore
- } def
-/pmark % <x> <y> pmark -
- { newpath 0 4.5 gsave initmatrix dtransform grestore idtransform add abs
- 0 360 arc stroke
- } def
-/mchdict mark
- /hsbw { pop 0 mhmx transform translate 0 0 pmark }
- /sbw { pop pop mhmx transform translate 0 0 pmark }
- /hstem
- { mhprint { (hstem ) print 2 copy 2 packedarray == } if
- hsmark
- }
- /vstem
- { mhprint { (vstem ) print 2 copy 2 packedarray == } if
- vsmark
- }
- /hstem3
- { mhprint { (hstem3 ) print 6 copy 6 packedarray == } if
- 3 { hsmark } repeat
- }
- /vstem3
- { mhprint { (vstem3 ) print 6 copy 6 packedarray == } if
- 3 { vsmark } repeat
- }
- /div
- { div
- }
- /callothersubr
- { 3 eq
- { pop
- mhprint { (replace) = } if
- % We're replacing hints; lighten the color.
- currentrgbcolor 3 { 2 mul 3 div 3 1 roll } repeat setrgbcolor
- }
- { { pop } repeat
- } ifelse
- }
- /callsubr
- { Private /Subrs get exch get mchinterp
- }
- /pop
- {
- }
- /return
- {
- }
-.dicttomark def
-
-/mchinterp % <charstring> mchinterp -
- { 4330 exch dup length string .type1decrypt exch pop
- dup length lenIV sub lenIV exch getinterval
- 0 () /SubFileDecode filter
- mark exch charstack_read ]
- { dup type /nametype eq
- { mchdict exch .knownget { exec } { cleartomark mark } ifelse
- }
- if
- }
- forall
- } def
-
-/markcharhints % <charname> <matrix> <print> markcharhints -
- { mhsetup
- gsave mark
- /Private currentfont /Private get def
- Private rcheck % make sure we won't get an access error
- { /lenIV Private /lenIV .knownget not { 4 } if def
- currentfont /CharStrings get 3 -1 roll get mchinterp
- }
- { (Sorry, this font is protected; I can't show the hints.\n) print flush
- exch
- }
- ifelse
- cleartomark grestore
- } def
diff --git a/Master/tlpkg/tlgs/lib/markpath.ps b/Master/tlpkg/tlgs/lib/markpath.ps deleted file mode 100644 index f1495ee52c6..00000000000 --- a/Master/tlpkg/tlgs/lib/markpath.ps +++ /dev/null @@ -1,59 +0,0 @@ -% Copyright (C) 1993 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: markpath.ps 6300 2005-12-28 19:56:24Z giles $
-% markpath.ps
-% Mark the corners of a path, drawing it slowly if desired.
-
-/Delay where { pop } { /Delay 0 def } ifelse
-/setxy0
- { currentpoint /y0 exch def /x0 exch def
- } def
-/bip
- { epsx epsy idtransform /ey exch def /ex exch def
- currentpoint ex 2 div ey 2 div rlineto currentpoint 0 ey neg rlineto
- ex neg 0 rlineto 0 ey rlineto lineto lineto
- stroke
- } def
-/dally
- { Delay { } repeat
- Delay 0 ne { flushpage } if
- } def
-/movebip
- { /xs 2 index def /ys 1 index def
- gsave newpath mpmx transform moveto setxy0 bip grestore
- } def
-/linebip
- { gsave newpath x0 y0 moveto mpmx transform lineto setxy0 bip dally grestore
- } def
-/curvebip
- { gsave newpath x0 y0 moveto 5 index 5 index mpmx transform lineto bip
- 2 copy mpmx transform moveto 3 index 3 index mpmx transform lineto bip
- x0 y0 moveto
- 3 { mpmx transform 6 2 roll } repeat
- curveto setxy0 bip dally grestore
- } def
-/closebip
- { xs ys linebip
- } def
-
-/markpath % <matrix> markpath -
- { /mpmx exch def
- gsave initgraphics 9 dup dtransform grestore
- /epsy exch def /epsx exch def
- gsave 0 setlinewidth
- { movebip } { linebip } { curvebip } { closebip } pathforall
- grestore
- } def
diff --git a/Master/tlpkg/tlgs/lib/mkcidfm.ps b/Master/tlpkg/tlgs/lib/mkcidfm.ps deleted file mode 100644 index 6bf34d8e537..00000000000 --- a/Master/tlpkg/tlgs/lib/mkcidfm.ps +++ /dev/null @@ -1,359 +0,0 @@ -% Copyright (C) 2004 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: mkcidfm.ps 8022 2007-06-05 22:23:38Z giles $
-
-% Generate a cidfmap file for substituting CID fonts with TrueType
-% fonts, based on fonts found in the directory FONTDIR.
-%
-% The directory FONTDIR is searched for fonts whose filename
-% matches a Path in the cidsubs dictionary.
-% Any matches are written out as a CID font substitution.
-%
-% For each fontname and alias in the fontaliases dictionary,
-% write out each alias that matches a substituted font.
-% Where multiple aliases are possible, use the first match.
-%
-% Note that the substitutions and aliases in this file were created
-% by someone who doesn't understand Chinese, Japanese or Korean.
-% The initial list contains only font files found in Windows XP.
-% Please submit corrections and additions.
-%
-% Font filenames must match case.
-% All font filenames are currently lower case.
-%
-% Usage: gswin32c -q -dBATCH -sFONTDIR=c:/windows/fonts
-% -sCIDFMAP=c:/gs/cidfmap mkcidfm.ps
-
-
-systemdict /FONTDIR known not { /FONTDIR (c:/windows/fonts) def } if
-
-systemdict /CIDFMAP known { CIDFMAP } { (%stdout) } ifelse
-/cidfmap exch (w) file def
-
-% Directory separator as used by filenameforall
-/dirsep (/) def
-
-% This dictionary contains a list of font substitutions.
-% The first matching substitution in the array will be used.
-/fontaliases
-<<
- % Traditional Chinese
- /MSung-Light [ /MingLiU ]
- /MSung-Medium [ /MingLiU ]
- /MHei-Medium [ /MingLiU ]
- /MKai-Medium [ /Arial-Unicode-MS /MingLiU ]
-
- % Simplified Chinese
- /STSong-Light [ /SimSun ]
- /STFangsong-Light [ /SimSun ]
- /STHeiti-Regular [ /SimHei ]
- /STKaiti-Regular [ /SimHei ]
-
- % Japanese
- /Ryumin-Light [ /MS-Mincho ]
- /Ryumin-Medium [ /MS-Mincho ]
- /GothicBBB-Medium [ /MS-Gothic ]
- /HeiseiMin-W3 [ /MS-Mincho ]
- /HeiseiKakuGo-W5 [ /MS-Gothic ]
-
- % Korean
- /HYSMyeongJo-Medium [ /Batang ]
- /HYRGoThic-Medium [ /Gulim ]
- /HYGoThic-Medium [ /Dotum ]
->>
-def
-
-
-% This dictionary contains a list of CID substitutions
-/cidsubs
-<<
- % Simplified Chinese
- /SimHei
- <<
- /FileType /TrueType
- /Path (simhei.ttf)
- /SubfontID 0
- /CSI [(GB1) 2]
- >>
-
- /SimSun
- <<
- /FileType /TrueType
- /Path (simsun.ttc)
- /SubfontID 0
- /CSI [(GB1) 2]
- >>
-
- /NSimSun
- <<
- /FileType /TrueType
- /Path (simsun.ttc)
- /SubfontID 1
- /CSI [(GB1) 2]
- >>
-
- % Traditional Chinese
- /MingLiU
- <<
- /FileType /TrueType
- /Path (mingliu.ttc)
- /SubfontID 0
- /CSI [(CNS1) 2]
- >>
-
- /PMingLiU
- <<
- /FileType /TrueType
- /Path (mingliu.ttc)
- /SubfontID 1
- /CSI [(CNS1) 2]
- >>
-
- /Arial-Unicode-MS
- <<
- /FileType /TrueType
- /Path (arialuni.ttc)
- /SubfontID 0
- /CSI [(CNS1) 2]
- >>
-
- % Japanese
- /MS-Gothic
- <<
- /FileType /TrueType
- /Path (msgothic.ttc)
- /SubfontID 0
- /CSI [(Japan1) 3]
- >>
-
- /MS-PGothic
- <<
- /FileType /TrueType
- /Path (msgothic.ttc)
- /SubfontID 1
- /CSI [(Japan1) 3]
- >>
-
- /MS-UI-Gothic
- <<
- /FileType /TrueType
- /Path (msgothic.ttc)
- /SubfontID 2
- /CSI [(Japan1) 3]
- >>
-
- /MS-Mincho
- <<
- /FileType /TrueType
- /Path (msmincho.ttc)
- /SubfontID 0
- /CSI [(Japan1) 3]
- >>
-
- /MS-PMincho
- <<
- /FileType /TrueType
- /Path (msmincho.ttc)
- /SubfontID 1
- /CSI [(Japan1) 3]
- >>
-
- % Korean
- /Batang
- <<
- /FileType /TrueType
- /Path (batang.ttc)
- /SubfontID 0
- /CSI [(Korea1) 3]
- >>
-
- /BatangChe
- <<
- /FileType /TrueType
- /Path (batang.ttc)
- /SubfontID 1
- /CSI [(Korea1) 3]
- >>
-
- /Gungsuh
- <<
- /FileType /TrueType
- /Path (batang.ttc)
- /SubfontID 2
- /CSI [(Korea1) 3]
- >>
-
- /GungsuhChe
- <<
- /FileType /TrueType
- /Path (batang.ttc)
- /SubfontID 3
- /CSI [(Korea1) 3]
- >>
-
- /Gulim
- <<
- /FileType /TrueType
- /Path (gulim.ttc)
- /SubfontID 0
- /CSI [(Korea1) 3]
- >>
-
- /GulimChe
- <<
- /FileType /TrueType
- /Path (gulim.ttc)
- /SubfontID 1
- /CSI [(Korea1) 3]
- >>
-
- /Dotum
- <<
- /FileType /TrueType
- /Path (gulim.ttc)
- /SubfontID 2
- /CSI [(Korea1) 3]
- >>
-
- /DotumChe
- <<
- /FileType /TrueType
- /Path (gulim.ttc)
- /SubfontID 3
- /CSI [(Korea1) 3]
- >>
-
->>
-def
-
-
-% A dictionary for storing the names and paths of found fonts
-/foundfonts 50 dict def
-
-% Get the basename of a path
-% For example, (c:/windows/fonts/msmincho.ps) --> (msmincho.ps)
-/basename { % path -- subpath
- { dirsep search
- {pop pop}
- {exit}
- ifelse
- } loop
-} def
-
-
-% Check if a font basename matches one of the possible cid substitutions.
-% If it does, add the font and full path to the foundfonts dictionary
-/checkfont {
- dup basename
- cidsubs
- {
- /Path get
- 2 index eq % Match case only
- {
- foundfonts exch
- 3 index dup length string copy put
- }
- {
- pop
- }
- ifelse
- }
- forall
- pop pop
-} def
-
-% Add all matching fonts to foundfonts dictionary
-/findfonts { % path --
- dup length 2 add string dup 3 1 roll copy pop
- dup dup length 2 sub dirsep 0 get put
- dup dup length 1 sub (*) 0 get put
- /checkfont load 256 string filenameforall
-} def
-
-
-% Write out a cid substition, using the full font path
-% name is the font name, e.g. /MS-Mincho
-% path is the full path to the font file, e.g. (c:\windows\fonts\msmincho.ps)
-% subs is the dictionary for CID font substition, from cidsubs
-/emitsubs { % name path subs --
- 3 -1 roll cidfmap exch write==only % name
- cidfmap ( << ) writestring
- % path subs
- {
- 1 index /Path eq {pop 1 index} if % use full path, not basename
- exch cidfmap exch write==only cidfmap ( ) writestring
- cidfmap exch write==only cidfmap ( ) writestring
- } forall
- cidfmap (>> ;\n) writestring
- pop
-} def
-
-% Write out all known cid substitutions.
-/writesubs { % ---
- cidfmap (% Substitutions\n) writestring
- foundfonts
- {
- 1 index cidsubs exch known
- {
- 1 index cidsubs exch get % name path subs
- emitsubs
- }
- {
- pop pop
- }
- ifelse
- }
- forall
-} def
-
-% Write out aliases for which the cid substituted font exists.
-/writealiases { % --
- cidfmap (\n% Aliases\n) writestring
- fontaliases
- {
- % name aliasarray
- {
- % name alias
- foundfonts 1 index known
- {
- 1 index cidfmap exch write==only cidfmap ( ) writestring
- cidfmap exch write==only cidfmap ( ;\n) writestring
- exit % after first match
- }
- {
- pop % didn't find this name
- }
- ifelse
- } forall
- % name
- pop
- }
- forall
-} def
-
-
-% Write out a new cidfmap file to stdout
-/writecidfmap { % path --
- cidfmap (%!\n% cidfmap generated automatically by mkcidfm.ps from fonts found in\n) writestring
- cidfmap (% ) writestring
- dup cidfmap exch writestring cidfmap (\n\n) writestring
- findfonts
- writesubs
- writealiases
-} def
-
-
-FONTDIR writecidfmap
diff --git a/Master/tlpkg/tlgs/lib/opdfread.ps b/Master/tlpkg/tlgs/lib/opdfread.ps deleted file mode 100644 index 5e42816f093..00000000000 --- a/Master/tlpkg/tlgs/lib/opdfread.ps +++ /dev/null @@ -1,3749 +0,0 @@ -%!PS-Adobe-2.0
-%
-% Copyright (C) 2002 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: opdfread.ps 8296 2007-10-16 07:54:08Z ken $
-% pdfread.ps - A procset for interpreting an ordered PDF 1.3 file.
-
-% This module defines routines for interpreting a PDF file with
-% a Postscript interpreter. To convert a PDF file into Postscript
-% just pre-contcatenate this file. The PDF file must satisfy
-% few constraints :
-%
-% 1. It must contain only Postscript level 2 objects encoded with
-% the PDF 1.3 language. Higher PDF levels must be re-distilled
-% with CompatibilityLevel=1.3 .
-%
-% 2. Objects must be ordered so that any resource be defined before
-% its usage.
-%
-% 3. The PDF file must not include other PDF files.
-% Consequently we have a single instance of the PDF reader.
-% We use this fact to simplify binding of the routines.
-%
-% 4. The PDF root object must always have the object id 1.
-%
-% 5. Generations besides 0 are not allowed.
-%
-% 6. xref must appear after all objects.
-%
-% Assuming the currentfile isn't positionable.
-% As a consequence, the reader fully ignores xref.
-
-
-true setglobal
-
-% ====================== Error handler =======================
-% A general error handler prints an error to page.
-
-10 dict begin % A dictionary for local binding
-
-/this currentdict def
-/y 720 def
-/ebuf 200 string def
-
-/prnt {
- 36 //this /y get moveto //ebuf cvs show
- //this /y 2 copy get 12 sub put
-} bind def
-
-/newline {
- 36 //this /y get moveto
- //this /y 2 copy get 12 sub put
-} bind def
-
-errordict /handleerror
-{ systemdict begin
- $error begin
- newerror
- { (%%[ Error handled by opdfread.ps : ) print errorname //ebuf cvs print (; OffendingCommand: )
- print /command load //ebuf cvs print ( ]%%) = flush
- /newerror false store vmstatus pop pop 0 ne
- { grestoreall
- } if
- errorname (VMerror) ne
- { showpage
- } if
- initgraphics
- 0 720 moveto
- errorname (VMerror) eq
- { //this /ehsave known
- { clear //this /ehsave get restore 2 vmreclaim
- } if
- vmstatus exch pop exch pop
- }
- /Courier 12 selectfont
- {
- (ERROR: ) //prnt exec errorname //prnt exec
- (OFFENDING COMMAND: ) //prnt exec
- /command load //prnt exec
- $error /ostack known {
- (%%[STACK:) =
- (STACK:) //prnt exec
- $error /ostack get aload length {
- //newline exec
- dup mark eq {
- (-mark-) dup = show
- } {
- dup type /nametype eq {
- dup xcheck not {
- (/) show
- (/) print
- } if
- } if
- dup = //ebuf cvs show
- } ifelse
- } repeat
- } if
- } ifelse
- (%%]%) =
- //systemdict /showpage get exec
- quit
- } if
- end
- end
-} bind readonly put
-
-end % A dictionary for local binding
-
-
-50 dict begin
-
-% ===================== Debugging =========================================
-
-/DefaultSwitch % <name> DefaultSwitch -
-{
- dup where {
- pop pop
- } {
- false def
- } ifelse
-} bind def
-
-/=string 256 string def
-
-/=only {
- //=string cvs print
-} bind def
-
-/HexDigits (0123456789ABCDEF) readonly def
-
-/PrintHex % <int> PrintHex -
-{ 8 {
- dup -28 bitshift //HexDigits exch 1 getinterval //=only exec
- 4 bitshift
- } repeat
- pop
-} bind def
-
-/PDFR_DEBUG DefaultSwitch
-/PDFR_DUMP DefaultSwitch
-/PDFR_STREAM DefaultSwitch
-/TTFDEBUG DefaultSwitch
-/RotatePages DefaultSwitch
-/FitPages DefaultSwitch
-/SetPageSize DefaultSwitch
-
-/error % mark <object> .... error -
-{ % A stub for a while.
- counttomark 1 sub -1 0 {
- index dup type /arraytype eq { == } { =only } ifelse
- } for
- () =
- cleartomark
- % Assuming ....Undefined is never defined.
- % Use it to emit an error.
- ....Undefined
-} bind def
-
-//SetPageSize {
- //RotatePages //FitPages or {
- mark (/RotatePages, /FitPages are not allowed with /SetPageSize) //error exec
- } if
-} if
-
-% ===================== Utilities =========================================
-
-/knownget % <dict> <key> knownget <value> true
- % <dict> <key> knownget false
-{
- 2 copy known {
- get true
- } {
- pop pop false
- } ifelse
-} bind def
-
-/IsUpper % <int> IsUpper <bool>
-{ dup (A) 0 get ge exch (Z) 0 get le and
-} bind def
-
-% Copy (recursive) packedarray|array to to global VM
-% NOTE: a packedarray will be converted to non-packed (too bad)
-/cpa2g { % <packedarray|array> cpa2g <packedarray|array>
- dup length array % <src> <dest>
- 0 1 2 index length 1 sub {
- % <src> <dest> index
- dup 3 index exch get cp2g
- % <src> <dest> index <globalelement>
- 3 copy put pop pop
- } for
- exch pop
-} bind def
-
-% Copy (recursive) dict to to global VM
-/cpd2g {
- dup length dict exch {
- cp2g 2 index 3 1 roll put
- } forall
-} bind def
-
-% Copy string to to global VM
-/cps2g { % <string> cps2g <string>
- dup length string copy
-} bind def
-
-/cp2gprocs
-<< /arraytype //cpa2g /dicttype //cpd2g /packedarraytype //cpa2g /stringtype //cps2g >>
-def
-
-/cp2g { % <any> cp2g <any>
- % where <any> is array | dict | string | packedarray
- % NOTE: The object must be readable (not executeonly or noaccess)
- dup gcheck not {
- dup //cp2gprocs 1 index type
- 2 copy known {
- get currentglobal 3 1 roll true setglobal exec exch setglobal
- % set the attributes appropriately (we must have 'read' access to get this far)
- 1 index wcheck not { readonly } if
- 1 index xcheck { cvx } if
- exch pop % discard original (local) object
- } {
- pop pop % discard type
- } ifelse
- } if
-} bind def
-
-% ===================== Work Data =========================================
-
-/BlockBuffer 65535 string def % Make it big to load entire TrueType font
-/PDFReader currentdict def
-/ObjectRegistry 50 array def % may grow later
-/CurrentObject null def
-/DoneDocumentStructure false def
-/GraphicState 20 dict begin
- /InitialTextMatrix matrix def
- /InitialMatrix matrix currentmatrix def
-currentdict end def
-/TempMatrix matrix def
-/GraphicStateStack 20 array def
-/GraphicStateStackPointer 0 def
-/PDFColorSpaces 50 dict def
-/InstalledFonts 50 dict def
-/MacRomanEncodingInverse null def
-
-% We need some structures in local VM, put then into the userdict :
-currentglobal false setglobal
-userdict /PDFR_InitialGS gstate put
-userdict /PDFR_Patterns 50 dict put
-userdict /FuncDataReader 10 dict put
-setglobal
-
-% ===================== Constants =========================================
-
-% The ExtGState elements are composite, thus need to be copied to
-% global VM (in case they aren't already global).
-/InitialExtGState 20 dict begin
- /BG2 currentblackgeneration cp2g def
- /UCR2 currentundercolorremoval cp2g def
- /TR2 [ currentcolortransfer ] cp2g def
- /HT currenthalftone cp2g def
-currentdict end readonly def
-
-/InitialGraphicState 20 dict begin
- /FontSize 0 def
- /CharacterSpacing 0 def
- /TextLeading 0 def
- /TextRenderingMode 0 def
- /WordSpacing 0 def
-currentdict end readonly def
-
-/SimpleColorSpaceNames 15 dict begin
- /DeviceGray true def
- /DeviceRGB true def
- /DeviceCMYK true def
-currentdict end readonly def
-
-/1_24_bitshift_1_sub 1 24 bitshift 1 sub def
-
-/ReadFontProcs 10 dict def % Will be filled below.
-
-% ===================== Reading PDF objects ===============================
-
-/Register % <DefaultDaemon> <id> <obj> Register -
-{
- exch dup % d obj id id
- //PDFReader /ObjectRegistry get length ge {
- dup dup 2 idiv add array dup % d obj id [n] [n]
- //PDFReader /ObjectRegistry get dup length % d obj id [n] [n] [o] l
- 3 2 roll exch % d obj id [n] [o] [n] l
- 0 exch getinterval copy pop % d obj id [n]
- //PDFReader exch /ObjectRegistry exch put % d obj id
- } if
- exch //PDFReader /ObjectRegistry get % d id obj r
- 3 1 roll % d r id obj
- 3 copy pop get % d r id obj e
- dup xcheck { % d r id obj e
- 5 4 roll pop % r id obj e
- //PDFR_DEBUG {
- (Have a daemon for ) print 2 index =
- } if
- % We've got a definition daemon, execute it :
- exec
- } { % d r id obj e
- dup null ne { % d r id obj e
- mark (The object ) 4 index ( already defined : ) 4 index //error exec
- } {
- pop
- } ifelse
- 4 3 roll % r id obj d
- % Execute the default daemon :
- exec
- } ifelse % r id obj
- put %
-} bind def
-
-/IsRegistered % <id> GetRegistered <bool>
-{
- //PDFReader /ObjectRegistry get % id r
- dup length % id r l
- 2 index le { % id r
- pop pop false
- } {
- exch get % id e
- null ne
- } ifelse
-} bind def
-
-/GetRegistered % <id> GetRegistered <obj>
-{
- //PDFReader /ObjectRegistry get % id r
- dup length % id r l
- 2 index le { % id r
- exch mark exch (Object ) exch ( isn't defined before needed (1).) //error exec
- } if
- 1 index get % id e
- dup xcheck {
- exch mark exch (Object ) exch ( isn't defined before needed (2).) //error exec
- } {
- dup null eq {
- exch mark exch (Object ) exch ( isn't defined before needed (3).) //error exec
- } if
- exch pop % e
- } ifelse
-} bind def
-
-/StandardFontNames <<
- /Times-Roman true
- /Helvetica true
- /Courier true
- /Symbol true
- /Times-Bold true
- /Helvetica-Bold true
- /Courier-Bold true
- /ZapfDingbats true
- /Times-Italic true
- /Helvetica-Oblique true
- /Courier-Oblique true
- /Times-BoldItalic true
- /Helvetica-BoldOblique true
- /Courier-BoldOblique true
->> def
-
-/CleanAllResources % - CleanAllResources -
-{ //PDFR_DEBUG {
- (CleanAllResources beg) =
- } if
- //PDFReader /ObjectRegistry get
- dup length 0 exch 1 exch 1 sub { % R i
- 2 copy get dup xcheck {
- % Don't clean a daemon.
- pop pop
- } {
- dup null eq {
- pop pop
- } {
- dup type /dicttype eq { /.Global known } { pop false } ifelse {
- pop
- } {
- //PDFR_DEBUG {
- (Dropping ) print dup =
- } if
- 1 index exch /DroppedObject put
- } ifelse
- } ifelse
- } ifelse
- } for
- pop
- FontDirectory length dict begin
- FontDirectory {
- pop
- dup //StandardFontNames exch known not {
- dup null def
- } if
- pop
- } forall
- currentdict
- end {
- pop
- //PDFR_DEBUG {
- (Undefining font ) print dup =
- } if
- undefinefont
- } forall
- //PDFR_DEBUG {
- (CleanAllResources end) =
- } if
-} bind def
-
-/PrintReference % <array> PrintReference <array>
-{
- //PDFR_DEBUG {
- ({ ) print
- dup {
- =only ( ) print
- } forall
- ( }) =
- } if
-} bind def
-
-/R % <id> <gen> R <daemon>
-{ % Make a reference daemon.
- 0 ne {
- exch mark exch (A referred object generation ) exch ( isn't 0.) //error exec
- } if % id
- [ % <id> proc <obj>
- exch //GetRegistered /exec load
- ] cvx
- //PrintReference exec
-} bind def
-
-/IsObjRef % <any> IsObjRef <bool>
-{
- dup type /arraytype eq {
- dup length 3 eq {
- dup xcheck exch
- dup 0 get type /integertype eq 3 2 roll and exch
- dup 1 get //GetRegistered eq 3 2 roll and exch
- 2 get /exec load eq and
- } {
- pop false
- } ifelse
- } {
- pop false
- } ifelse
-} bind def
-
-/DoNothing
-{
-} def
-
-/RunTypeDaemon % <id> <obj> RunTypeDaemon <id> <obj>
-{
- dup type /dicttype eq {
- dup /Type //knownget exec {
- //PDFReader /TypeDaemons get exch
- //knownget exec {
- exec
- } if
- } if
- } if
-} bind def
-
-/obj % <id> <generation> obj <id>
-{
- //PDFR_DEBUG {
- (Defining ) print 1 index =only ( ) print dup =only ( obj) =
- } if
- 0 ne {
- exch mark exch (An object generation ) exch ( isn't 0.) //error exec
- } if
-} bind def
-
-/endobj % <id> <obj> endobj -
-{
- //PDFR_DEBUG {
- (endobj ) =
- } if
- dup type /dicttype eq {
- dup /.endobj_daemon //knownget exec {
- //PDFR_DEBUG { (.endobj_daemon for ) print 2 index = } if
- exec
- } if
- } if
- dup type /dicttype eq { dup /ImmediateExec known } { false } ifelse {
- pop pop
- } {
- //PDFR_DEBUG {
- (Storing ) print 1 index =
- } if
- //RunTypeDaemon exec
- //DoNothing 3 1 roll //Register exec
- } ifelse
-} bind def
-
-/StoreBlock % <buf> StoreBlock -
-{ % Stores a (encoded) stream data block to the current object.
- //PDFR_DEBUG {
- (StoreBlock ) print //PDFReader /BlockCount get =only (, Length = ) print dup length =
- } if
- dup length string copy
- //PDFReader /BlockCount get exch % i s
- //PDFReader /CurrentObject get 3 1 roll % o i s
- put %
- //PDFReader /BlockCount get 1 add
- //PDFReader exch /BlockCount exch put
-} bind def
-
-/CheckLength % <val> CheckNumber <val>
-{ dup type /integertype ne {
- mark (Object length isn't an integer.) //error exec
- } if
-} bind def
-
-/ResolveD % <dict> <key> <check> ResolveD <value>
-{
- 3 copy pop get % <> key {} e
- dup //IsObjRef exec {
- % We've got a reference daemon, execute it :
- //PDFR_DEBUG {
- (Resolving ) print //PrintReference exec
- } if
- exec % <> key {} val
- exch exec % <> key val
- } {
- exch pop
- } ifelse
- dup 4 1 roll % val <> key val
- put % val
-} bind def
-
-/ResolveA % <array> <index> <check> ResolveA <value>
-{ 2 index 2 index get
- dup //IsObjRef exec {
- exec
- exch exec
- 3 copy put
- } {
- exch pop
- } ifelse
- exch pop exch pop
-} bind def
-
-/StoreStream % <id> <obj> StoreStream <id> <obj>
-{ % Stores a (encoded) data stream copy to the current object.
- dup //PDFReader exch /CurrentObject exch put % id obj
- //PDFReader /BlockCount 0 put
- dup /Length //CheckLength //ResolveD exec % id obj l
- //PDFR_DEBUG {
- (StoreStream Length = ) print dup =
- } if
- currentfile exch () /SubFileDecode filter % id obj file
- { dup //BlockBuffer readstring { % id obj file buf
- //StoreBlock exec
- } {
- //StoreBlock exec
- exit
- } ifelse % id obj file
- } loop
- pop % id obj
- //PDFReader /CurrentObject null put
- //PDFR_DEBUG {
- (StoreStream end.) =
- } if
-} bind def
-
-/MakeStreamDumper % <file> MakeStreamDumper <file>
-{ % Debug purpose only.
- //PDFR_DEBUG {
- (MakeStreamDumper beg.) =
- } if
- currentglobal exch dup gcheck setglobal
- [ exch % f
- 1 dict dup /c 0 put exch % d f
- 1024 string % d f s
- { readstring pop % d s
- (StreamDumper ) print 1 index /c get =string cvs print ( ) print
- dup length =string cvs print ( <) print dup print (>\n) print
- dup length % d s l
- 3 2 roll % s l d
- dup /c get % s l d c
- 3 2 roll % s d c l
- add /c exch put % s
- } /exec load
- ]
- cvx 0 () /SubFileDecode filter
- exch setglobal
- //PDFR_DEBUG {
- (MakeStreamDumper end.) =
- } if
-} bind def
-
-/ShortFilterNames 15 dict begin
- /AHx /ASCIIHexDecode def
- /A85 /ASCII85Decode def
- /LZW /LZWDecode def
- /Fl /FlateDecode def
- /RL /RunLengthDecode def
- /CCF /CCITTFaxDecode def
- /DCT /DCTDecode def
-currentdict end readonly def
-
-/AppendFilters % <file> <dict> AppendFilters <file>
-{
- //PDFR_DEBUG {
- (AppendFilters beg.) =
- } if
- dup 3 1 roll % d f d
- /Filter //knownget exec { % d f F
- dup type /nametype eq { % d f /F
- dup //ShortFilterNames exch //knownget exec {
- exch pop
- } if
- 2 index /DecodeParms //knownget exec { % d f p /F
- exch
- } if
- filter % d f'
- } { % d f []
- dup 0 exch 1 exch length 1 sub { % d f [] i
- 2 copy get % d f [] i /F
- dup //ShortFilterNames exch //knownget exec {
- exch pop
- } if
- 3 1 roll % d f /F [] i
- 4 index /DecodeParms //knownget exec { % d f /F [] i DP
- exch get % d f /F [] dp
- } { % d f /F [] i
- pop null % d f /F [] dp
- } ifelse
- dup null eq { % d f /F [] dp
- pop 3 1 roll filter exch % d f' []
- } { % d f /F [] dp
- 3 1 roll % d f dp /F []
- 4 1 roll filter exch % d f' []
- } ifelse
- } for
- pop % d f'
- } ifelse
- //PDFR_DEBUG //PDFR_DUMP and {
- //MakeStreamDumper exec
- } if
- } if
- exch pop
- //PDFR_DEBUG {
- (AppendFilters end.) =
- } if
-} bind def
-
-/ExecuteStream % <id> <obj> ExecuteStream <id> <obj>
-{ % Executes a (encoded) data stream.
- dup //PDFReader exch /CurrentObject exch put % id obj
- dup /Length //CheckLength //ResolveD exec % id obj l
- //PDFR_DEBUG {
- (ExecuteStream id = ) print 2 index =only ( Length = ) print dup =
- } if
- //PDFReader /InitialGraphicState get
- //PDFReader /GraphicState get copy pop
- //PDFReader /Operators get begin
- % currentfile exch () /SubFileDecode filter % id obj file
- % We would like to use the code above,
- % but HP LaserJet 1320 continues parsing after the byte count exceeds.
- pop currentfile 0 (endstream) /SubFileDecode filter % id obj file
- 1 index //AppendFilters exec
- cvx mark exch % id obj mark file
- exec
- counttomark 0 ne {
- mark (Data left on ostack after an immediate stream execution.) //error exec
- } if
- cleartomark % id obj
- end % Operators
- //PDFR_DEBUG {
- (ExecuteStream end.) =
- } if
- //PDFReader /CurrentObject null put
- dup /IsPage known {
- dup /Context get /NumCopies //knownget exec {
- 1 sub {
- copypage
- } repeat
- } if
- showpage
- } if
-} bind def
-
-/stream % <id> <obj> stream <id> <obj>
-{
- //PDFR_DEBUG {
- 1 index =only ( stream) =
- } if % id obj
- % Run the object definition daemon, if exists :
- //PDFReader /ObjectRegistry get dup length 3 index % id obj r l id
- gt { % id obj r
- 2 index get
- dup xcheck {
- exec
- % Disable the daemon :
- //PDFReader /ObjectRegistry get 2 index null put
- } {
- pop
- } ifelse
- } {
- pop
- } ifelse % id obj
- dup /ImmediateExec known {
- dup /GlobalExec //knownget exec {
- currentglobal 4 1 roll
- setglobal
- //ExecuteStream exec
- 3 2 roll setglobal
- } {
- //ExecuteStream exec
- } ifelse
- } {
- //StoreStream exec
- } ifelse
- dup /.CleanResources //knownget exec {
- /All eq {
- //CleanAllResources exec
- } if
- } if
-} bind def
-
-/HookFont % <id> <obj> <font_descriptor> HookFont <id> <obj>
-{
- //PDFR_DEBUG {
- (Loaded the font ) print dup /FontName get =
- } if
- {
- dup /FontFileType get dup /Type1 eq exch /MMType1 eq or { % id obj fd
- % We assume that the Type 1 font has same name with no prefix
- % due to pdfwrite specifics.
- % We use it to find the font after it is defined.
- % We could redefine 'definefont' for hooking the font,
- % but we don't think that it could be guaranteedly portable :
- % a 3d party PS interpreter may set a special context
- % when running the font file.
- % Note that this mechanizm does not depend on the
- % font name uniquity, because the last 'definefont'
- % is only important.
- dup /FontName get % id obj fd fn
- //PDFReader /RemoveFontNamePrefix get exec
- currentglobal true setglobal exch % id obj fd g fn
- findfont % id obj fd g f
- exch setglobal % id obj fd f
- exit
- } if
- dup /FontFileType get /TrueType eq { % id obj fd
- //PDFReader /MakeType42 get exec
- //PDFR_DEBUG {
- (Font dict <<) =
- dup {
- 1 index /sfnts eq {
- exch pop
- (/sfnts [) print
- {
- (-string\() print length //=only exec (\)- ) =
- } forall
- (]) =
- } {
- exch //=only exec ( ) print ==
- } ifelse
- } forall
- (>>) =
- } if
- dup /FontName get exch definefont
- exit
- } if
- mark (FontHook has no proc for ) 2 index /FontFileType get //error exec
- } loop
- /Font exch put % id obj
-} bind def
-
-/endstream % <id> <obj> endstream <id> <obj>
-{
-} bind def
-
-/xref % - xref -
-{
- //PDFR_DEBUG {
- (xref) =
- //PDFR_DUMP {
- //PDFReader /ObjectRegistry get ==
- } if
- } if
- end % The procset
- count 0 ne {
- mark (Excessive data on estack at the end of the interpretation.) //error exec
- } if
- currentfile flushfile
-} bind def
-
-% ===================== Restoring the PDF Document Structure ===============
-
-/ResolveDict % <dict> /ResolveDict -
-{ dup { % d key val
- pop 1 index exch % d cp key
- //DoNothing //ResolveD exec % d obj
- pop % d
- } forall
- pop %
-} bind def
-
-/SetupPageView % <obj> SetupPageView -
-{
- //PDFR_DEBUG {
- (SetupPageView beg) =
- } if
- //GraphicState /InitialMatrix get setmatrix
- /MediaBox get aload pop % bx0 by0 bx1 by1
- 3 index neg 3 index neg translate % Temporary move to origin
- 3 -1 roll sub 3 1 roll exch sub exch % bw bh
- userdict /.HWMargins //knownget exec {
- aload pop
- } {
- currentpagedevice /.HWMargins //knownget exec {
- aload pop
- } {
- 0 0 0 0
- } ifelse
- } ifelse
- currentpagedevice /PageSize get aload pop
- 3 -1 roll sub 3 1 roll exch sub exch % bw bh px0 py0 px1 py1
- exch 3 index sub exch 3 index sub % bw bh px0 py0 pw ph
- //SetPageSize {
- //PDFR_DEBUG {
- (Setting page size to ) print 1 index //=only exec ( ) print dup =
- } if
- pop pop 3 index 3 index 2 copy % bw bh px0 py0 bw bh bw bh
- currentglobal false setglobal 3 1 roll % bw bh px0 py0 bw bh bool bw bh
- 2 array astore % bw bh px0 py0 bw bh bool []
- << exch /PageSize exch >> setpagedevice % bw bh px0 py0 bw bh bool
- userdict /PDFR_InitialGS gstate put
- setglobal % bw bh px0 py0 bw bh
- } if
- //RotatePages {
- 2 copy gt 6 index 6 index gt ne {
- % a rotation is useful except it fits with no rotation.
- 1 index 5 index le 1 index 5 index le and not
- } {
- false
- } ifelse
- } {
- false
- } ifelse
- { //FitPages {
- 1 index 5 index div 1 index 7 index div % bw bh px0 py0 pw ph sx sy
- 2 copy gt {
- exch
- } if
- pop dup scale % bw bh px0 py0 pw ph
- } if
- 90 rotate
- 0 5 index neg translate
- } {
- //FitPages {
- 1 index 6 index div 1 index 6 index div % bw bh px0 py0 pw ph sx sy
- 2 copy gt {
- exch
- } if
- pop dup scale % bw bh px0 py0 pw ph
- } if
- } ifelse
- pop pop % bw bh px0 py0
- translate % bw bh
- pop pop %
- //PDFR_DEBUG {
- (SetupPageView end) =
- } if
-} bind def
-
-/PageContentsDaemon % <id> <obj> <node> PageContentsDaemon <id> <obj>
-{ % Note: an excessive operand from a prebond procedure.
- //PDFR_DEBUG {
- (Executing PageContentsDaemon for ) print 2 index =
- } if % id obj node
- 1 index exch /Context exch put % id obj
- dup /ImmediateExec true put
- dup /IsPage true put
- dup /Context get //SetupPageView exec
-} bind def
-
-/FontFileDaemon % <id> <obj> <font_descriptor> FontFileDaemon <id> <obj>
-{ % Note: an excessive operand from a prebond procedure.
- //PDFR_DEBUG {
- (Executing FontFileDaemon for ) print 2 index =
- } if
- % We need any font resource that refers this descriptor
- % to know the font type. Assuming that FontDescriptorDaemon
- % provided FontFileType.
- dup /FontFileType get % id obj fd ft
- 2 index exch % id obj fd obj ft
- dup //ReadFontProcs exch //knownget exec { % id obj fd obj ft proc
- exch pop exec % id obj fd
- } {
- mark (FontFile reader for ) 2 index ( isn't implemented yet.) //error exec
- } ifelse
- //PDFR_DEBUG {
- (FontFileDaemon end) =
- } if % id obj fd
- pop
-} bind def
-
-/FontDescriptorDaemon % <id> <obj> <font_resource> FontDescriptorDaemon <id> <obj>
-{ % Note: an excessive operand from a prebond procedure.
- //PDFR_DEBUG {
- (Executing FontDescriptorDaemon for ) print 2 index =
- } if % id obj fr
- %HACK BEG assuming an own font for each font descriptor
- % to provide an access to PDFEncoding
- % from MakeType42, ComposeCharStrings.
- 2 copy /FontResource exch put
- %HACK END
- /Subtype get 1 index exch /FontFileType exch put
-} bind def
-
-/UnPDFEscape { % <namepdf> UnPDFEscape <nameps>
- dup dup length string cvs % /namepdf (name)
- dup (#) search {
- % name contains PDF-style escapes ("#hh") that need to be removed
- { % ... (po..st) (#) (pre)
- pop % ... (po..st) (#)
- (16#--) 2 index 0 2 getinterval % ... (po..st) (#) (16#--) (po)
- 1 index 3 2 getinterval copy pop % ... (po..st) (#) (16#po)
- cvi % ... (po..st) (#) 16#po
- 0 exch put % ... (po..st); 16#po patched into (#)
- 0 % ... (po..st) 0
- 1 index 2 1 index length 2 sub getinterval % ... (po..st) 0 (..st)
- 3 copy putinterval % ... (..stst) 0 (XXst)
- length % ... (..stst) 0 LEN_OF_(po..st)-2
- 3 copy exch put % ... (..st\0t) 0 LEN_OF_(po..st)-2
- getinterval % ... (..st), stored at begining of old (po..st)
- (#) search not {
- pop exit % /namepdf (nameps\0..)
- } if
- } loop
- % we have a '\0' marker (not allowed in PDF names) after all usefull characters
- (\0) search pop exch pop exch pop
- cvn
- exch pop
- } {
- pop pop
- } ifelse
-} bind def
-
-/TypeDaemons << % <id> <obj> proc <id> <obj>
- /Page
- { //PDFR_DEBUG {
- (Recognized a page.) =
- } if
- dup /Contents //knownget exec { % id obj c
- 0 get //DoNothing exch % id obj dn id1
- [ % <id> <obj> proc <id> <obj>
- 3 index //PageContentsDaemon /exec load
- ] cvx % id obj {}
- //Register exec % id obj
- } {
- (fixme: page with no Contents won't be printed.) =
- } ifelse
- } bind
- /FontDescriptor
- { //PDFR_DEBUG {
- (Recognized a font descriptor.) =
- } if
- dup /FontName //knownget exec {
- 1 index /FontName 3 -1 roll //UnPDFEscape exec put
- } if
- {
- dup dup /FontFile known {/FontFile} {/FontFile2} ifelse
- //knownget exec { % id obj ff
- 0 get //DoNothing exch % id obj dn id1
- [ % <id> <obj> proc <id> <obj>
- 3 index //FontFileDaemon /exec load
- ] cvx % id obj {}
- //Register exec % id obj
- exit
- } if
- % FontFile3 are not implemented yet.
- (Font descriptor ) print 1 index =only ( has no FontFile.) =
- } loop
- } bind
- /Font
- { //PDFR_DEBUG {
- (Recognized a font resource.) =
- } if
- dup /BaseFont //knownget exec {
- //UnPDFEscape exec 2 copy /BaseFont exch put
- % cache the installed font (if any) before replacing it.
- //PDFReader /RemoveFontNamePrefix get exec
- currentglobal exch % A hack against HP LaserJet 1320 bug :
- % It sets the local allocation mode
- % when 'resourcestatus' fails.
- dup /Font resourcestatus {
- pop pop
- //PDFReader /GetInstalledFont get exec pop
- } {
- pop
- } ifelse
- setglobal
- } if
- dup /FontDescriptor //knownget exec { % id obj fd
- 0 get % id obj id1
- dup //IsRegistered exec { % id obj id1
- //PDFR_DEBUG {
- (already registered ) print dup =
- } if
- pop
- } {
- //DoNothing exch % id obj dn id1
- [ % <id> <obj> proc <id> <obj>
- 3 index //FontDescriptorDaemon /exec load
- ] cvx % id obj {}
- //Register exec % id obj
- } ifelse
- } if
- } bind
->> def
-
-/MakeStreamReader % <obj> MakeStreamReader <file>
-{ dup
- [
- exch
- //PDFR_DEBUG {
- (Stream proc )
- /print load
- //PDFR_STREAM {
- (<)
- /print load
- } if
- } if
- 1 dict dup /i -1 put
- /dup load
- /i
- /get load
- 1
- /add load
- /dup load
- 3
- 1
- /roll load
- /i
- /exch load
- /put load
- //knownget
- /exec load
- /not load
- { () }
- /if load
- //PDFR_DEBUG {
- //PDFR_STREAM {
- /dup load
- /print load
- (>)
- /print load
- } if
- ( end of stream proc.\n)
- /print load
- } if
- ] cvx
- //PDFR_DEBUG {
- (Stream reader ) print dup ==
- } if
- 0 () /SubFileDecode filter
- exch //AppendFilters exec
-} bind def
-
-/RunDelayedStream % <stream_obj> RunDelayedStream -
-{
- //MakeStreamReader exec % file
- mark exch
- cvx exec %
- counttomark 0 ne {
- mark (Data left on ostack after a delayed stream execution.) //error exec
- } if
- cleartomark
-} bind def
-
-% ===================== Font Management ======================
-
-//ReadFontProcs begin
- /Type1 % <font_descriptor> <FontFile_object> Type1 <font_descriptor>
- { //PDFR_DEBUG {
- (ReadFontProcs.Type1) =
- } if
- dup /.endobj_daemon [ 4 index //HookFont /exec load ] cvx put
- dup /ImmediateExec true put
- /GlobalExec true put
- } bind def
- /MMType1 //Type1 def
- /TrueType % <font_descriptor> <FontFile_object> TrueType <font_descriptor>
- { //PDFR_DEBUG {
- (ReadFontProcs.TrueType) =
- } if
- dup /.endobj_daemon [ 4 index //HookFont /exec load ] cvx put
- pop
- } bind def
-end
-
-/MakeType42 % <FontFile_object> <font_descriptor> MakeType42 <FontFile_object> <font_descriptor> <font>
-{
- //PDFR_DEBUG {
- (MakeType42 beg) =
- } if
- 10 dict begin
- /FontName 1 index /FontName get def
- /FontType 42 def
- /FontMatrix [1 0 0 1 0 0] def
- /FontBBox 1 index /FontBBox get def % fo fd
- dup /FontResource get % fo fd fr
- dup /Encoding known { % fo fd fr
- //PDFReader /ObtainEncoding get exec % fo fd fr
- /Encoding get % fo fd e
- } {
- pop null
- } ifelse
- /PDFEncoding exch def % fo fd
- /CharStrings 2 index //PDFReader /MakeTTCharStrings get exec def
- /sfnts [ 3 index //MakeStreamReader exec 65535 string readstring pop ] def
- /Encoding StandardEncoding def % A stub - will be replaced by font resource.
- /PaintType 0 def
- currentdict end
- //PDFR_DEBUG {
- (MakeType42 end) =
- } if
-} bind def
-
-/GetInstalledFont % <name> GetInstalledFont <font>
-{ currentglobal exch true setglobal % g n
- dup //InstalledFonts exch knownget { % g n f
- exch pop % g f
- } { % g n
- dup findfont dup 3 1 roll % g f n f
- //InstalledFonts 3 1 roll put % g f
- } ifelse
- exch setglobal
-} bind def
-
-/RemoveFontNamePrefix % <name> RemoveFontNamePrefix <name>
-{ //=string cvs true
- 0 1 5 {
- 2 index exch get //IsUpper exec not {
- pop false exit
- } if
- } for
- { (+) search {
- pop pop
- } if
- } if
- cvn
-} bind def
-
-/CheckFont % <key> <val> CheckFont <key> <val>
-{ dup /Type get /Font ne {
- mark (Resource ) 3 index ( must have /Type/Font .) //error exec
- } if
-} bind def
-
-/CheckEncoding % <key> <val> CheckEncoding <key> <val>
-{ dup type /nametype ne {
- dup /Type get /Encoding ne {
- mark (Resource ) 3 index ( must have /Type/Encoding .) //error exec
- } if
- } if
-} bind def
-
-/ObtainEncoding % <font_resource> ObtainEncoding <font_resource>
-{ dup /Encoding known {
- dup dup /Encoding //CheckEncoding //ResolveD exec % fr fr er|e|n
- dup type dup /arraytype eq exch /packedarraytype eq or {
- % Already resolved.
- pop pop
- } {
- dup type /nametype eq {
- /Encoding findresource % fr fr e
- } {
- dup /BaseEncoding //knownget exec not {
- /StandardEncoding
- } if
- /Encoding findresource % fr fr er e
- exch % fr fr e er
- /Differences //knownget exec { % fr fr e d
- exch dup length array copy exch
- 0 exch % fr fr e 0 d
- { % fr fr e i v
- dup type /integertype eq {
- exch pop
- } {
- 3 copy put pop % fr fr e i
- 1 add
- } ifelse
- } forall
- pop % fr fr e
- } if % fr fr e
- } ifelse % fr fr e
- /Encoding exch put % fr
- } ifelse
- } {
- dup /Encoding /StandardEncoding /Encoding findresource put
- } ifelse
-} bind def
-
-/ObtainMetrics % <font_resource> ObtainMetrics <font_resource>
-{ dup /Widths //knownget exec { % fr W
- 1 index /Encoding get % fr W E
- 256 dict % fr W E M
- 3 index /Subtype get /TrueType eq {
- 1000
- } {
- 1
- } ifelse % fr W E M s
- 4 index /MissingWidth //knownget exec not {
- 0
- } if % fr W E M s mw
- 5 index /FirstChar //knownget exec not {
- 0
- } if % fr W E M s mw c0
- 6 5 roll % fr E M s mw c0 W
- dup 0 exch 1 exch length 1 sub { % fr E M s mw c0 W i
- 2 copy get % fr E M s mw c0 W i w
- exch 3 index add % fr E M s mw c0 W w c
- 7 index exch get % fr E M s mw c0 W w n
- dup null ne {
- 6 index 3 1 roll exch % fr E M s mw c0 W M n w
- 6 index div
- 3 copy pop //knownget exec {
- 0 eq
- } {
- true
- } ifelse
- { put % fr E M s mw c0 W
- } {
- pop pop pop
- } ifelse
- } {
- pop pop
- } ifelse
- } for
- pop pop pop pop exch pop % fr M
- 1 index exch /Metrics exch put % fr
- } {
- dup /MissingWidth //knownget exec { % fr mw
- 256 dict % fr mw M
- 2 index /Encoding get { % fr mw M e
- dup null ne {
- 3 copy 3 2 roll put % fr mw M e
- } if
- pop % fr mw M
- } forall
- exch pop % fr M
- 1 index exch /Metrics exch put % fr
- } if
- } ifelse
-} bind def
-
-/NotDef % - NotDef -
-{ % A Type 3 font is on dstack.
- FontMatrix aload pop pop pop exch pop exch pop % sx sy
- 1 exch div exch
- 1 exch div exch % wx wy
- 1 index 0 setcharwidth
- o setlinewidth
- 0 0 moveto
- 2 copy rlineto
- 1 index 0 rlineto
- neg exch neg exch rlineto %
- closepath stroke
-} bind def
-
-/BuildChar % <font> <char_code> BuildChar -
-{ //PDFR_DEBUG {
- (BuildChar ) print dup //=only exec ( ) print
- } if
- exch begin
- Encoding exch get % n
- //PDFR_DEBUG {
- dup =
- } if
- dup null eq {
- pop //NotDef exec %
- } { % n
- CharProcs exch //knownget exec { % cp_stream
- //RunDelayedStream exec
- } {
- //NotDef exec
- } ifelse
- } ifelse %
- end % font
-} bind def
-
-/printdict % <dict> printdict -
-{ (<<) =
- { exch = == } forall
- (>>) =
-} bind def
-
-/printfont % <dict> printfont -
-{
- dup {
- exch dup =
- dup /Encoding eq {
- pop =
- } {
- dup /FontInfo eq exch /Private eq or {
- //printdict exec
- } {
- ==
- } ifelse
- } ifelse
- } forall
-} bind def
-
-/ScaleMetrics % <Metrics> <scale> ScaleMetrics <Metrics>
-{ 1 index { % M s n v
- 2 index div % M s n v'
- 3 index % M s n v' M
- 3 1 roll put % M s
- } forall
- pop
-} bind def
-
-/ResolveAndSetFontAux % <resource_name> <size> ResolveAndSetFont -
-{ exch dup % s rn rn
- //PDFReader /CurrentObject get /Context get /Resources get
- /Font //DoNothing //ResolveD exec
- exch //CheckFont //ResolveD exec % s rn fr
- dup /Font //knownget exec { % s rn fr f
- exch pop exch pop
- } {
- {
- dup /Subtype get dup dup /Type1 eq exch /TrueType eq or exch /MMType1 eq or {
- % s rn fr
- exch pop % s fr
- dup /BaseFont get % s fr n
- //RemoveFontNamePrefix exec % s fr n
- //PDFR_DEBUG {
- (Font ) print dup =
- } if % s fr n
- 1 index /FontDescriptor known { % s fr n
- //PDFR_DEBUG {
- (Font from a font descriptor.) =
- } if
- 1 index % s fr n fr
- /FontDescriptor //DoNothing //ResolveD exec % s fr n fd
- /Font //knownget exec {
- exch pop % s fr fd
- } {
- //PDFR_DEBUG {
- (Font descriptor has no Font resolved.) =
- } if
- //GetInstalledFont exec % s fr f
- } ifelse
- } {
- //GetInstalledFont exec % s fr f
- } ifelse
- exch % s f fr
- dup /Encoding known not {
- 1 index /Encoding get 1 index exch /Encoding exch put
- } if
- //ObtainEncoding exec
- //ObtainMetrics exec
- exch
- dup length dict copy % s fr f
- dup 2 index /Encoding get % s fr f f e
- /Encoding exch put % s fr f
- 1 index /Metrics //knownget exec { % s fr f M
- 2 index /Subtype get /TrueType ne {
- 1 index /FontMatrix get 0 get
- dup 0 eq {
- % FontMatrix[0] == 0, so cannot downscale by it
- % HACK: downscale by FontMatrix[1], and will get the target value of wx as wy
- pop
- 1 index /FontMatrix get 1 get
- dup 0 eq { pop 1 } if % sorry, FontMatrix is singular so cannot enforce the PDF metrics
- } if
- 0.001 div
- //ScaleMetrics exec
- } if
- 1 index exch /Metrics exch put % s fr f
- } if
- 1 index /BaseFont get % s fr f n
- exch
- dup /FID undef
- dup /UniqueID undef
- definefont % s fr f
- dup 3 1 roll % s f fr f
- /Font exch put % s f
- exit
- } if
- dup /Subtype get /Type3 eq { % s rn fr
- //ObtainEncoding exec
- 2 copy exch /FontName exch put
- dup /CharProcs get //ResolveDict exec
- dup /FontType 3 put
- dup /BuildChar //BuildChar put
- dup dup /Font exch put
- % Ignore Metrics because pdfwrite duplicates it
- % from setcharwidth/setcachedevice.
- dup 3 1 roll % s fr rn fr
- definefont % s fr f
- 2 copy ne {
- % The interpreter copied the font dictionary while 'definefont'
- % Need to update the font pointer in the resource.
- 2 copy /Font exch put % s fr f
- } if
- exch pop % s f
- exit
- } if
- dup /Subtype get /Type0 eq { % s rn fr
- } if
- dup /Subtype get /CIDFontType0 eq { % s rn fr
- } if
- dup /Subtype get /CIDFontType2 eq { % s rn fr
- } if
- mark (Unknown font type ) 2 index /Subtype get //error exec
- } loop
- } ifelse % s f
- exch scalefont setfont %
-} bind def
-
-/ResolveAndSetFont % <resource_name> <size> ResolveAndSetFont -
-{ currentglobal true setglobal 3 1 roll
- //ResolveAndSetFontAux exec
- setglobal
-} bind def
-
-%%beg TrueType
-% ================= Auxiliary procedures for True Type cmap Decoder =============
-
-/.knownget
-{ 2 copy known {
- get true
- } {
- pop pop false
- } ifelse
-} bind def
-
-/.min
-{ 2 copy lt {
- exch
- } if
- pop
-} bind def
-
-/.max
-{ 2 copy gt {
- exch
- } if
- pop
-} bind def
-
-/.dicttomark
-{ >>
-} bind def
-
-% ===================== True Type cmap Decoder =============
-% The following procedures are copied from gs/lib/gs_ttf.ps with no change.
-
-% <string> <index> getu16 <integer>
-/getu16 {
- 2 copy get 8 bitshift 3 1 roll 1 add get add
-} bind def
-
-% <string> <index> gets16 <integer>
-/gets16 {
- getu16 16#8000 xor 16#8000 sub
-} bind def
-
-% <string> <index> getu32 <integer>
-/getu32 {
- 2 copy getu16 16 bitshift 3 1 roll 2 add getu16 add
-} bind def
-
-% <string> <index> gets32 <integer>
-/gets32 {
- 2 copy gets16 16 bitshift 3 1 roll 2 add getu16 add
-} bind def
-
-% Each procedure in this dictionary is called as follows:
-% <encodingtable> proc <glypharray>
-/cmapformats mark
- 0 { % Apple standard 1-to-1 mapping.
- 6 256 getinterval { } forall 256 packedarray
- } bind
- 2 { % Apple 16bit CJK (ShiftJIS etc)
-
- % /sHK_sz subHeaderKey_size % 1 * uint16
- % /sH_sz subHeader_size % 4 * uint16
- % /sH_len subHeader_length
- % /cmapf2_tblen total table length
- % /cmapf2_lang language code (not used)
- % /sHKs subHeaderKeys
-
- /sHK_sz 2 def
- /sH_sz 8 def
- dup 2 getu16 /cmapf2_tblen exch def
-
- dup 4 getu16 /cmapf2_lang exch def
-
- dup 6 256 sHK_sz mul getinterval /sHKs exch def
-
- 0 % initialization value for /sH_len
- 0 1 255 {
- sHKs exch
- 2 mul getu16
- 1 index % get current max
- 1 index % get current subHeaderKey
- lt {exch} if pop
- } for
- /sH_len exch def
-
- dup 6 256 sHK_sz mul add
- cmapf2_tblen 1 index sub getinterval
- /sH_gIA exch def
-
- /cmapf2_glyph_array 65535 array def
-
- /.cmapf2_putGID {
- /cmapf2_ch cmapf2_ch_hi 8 bitshift cmapf2_ch_lo add def
- firstCode cmapf2_ch_lo le
- cmapf2_ch_lo firstCode entryCount add lt
- and { % true: j is inside
- sH_offset idRangeOffset add % offset to gI
- cmapf2_ch_lo firstCode sub 2 mul % rel. pos. in range
- add 6 add % offset in sH_gIA
- sH_gIA exch getu16
- dup 0 gt { %
- idDelta add
- cmapf2_glyph_array exch cmapf2_ch exch put
- } {
- pop
- % cmapf2_glyph_array cmapf2_ch 0 put
- } ifelse
- } { % false: j is outside
- % cmapf2_glyph_array cmapf2_ch 0 put
- } ifelse
- } def
-
- 16#00 1 16#ff { % hi_byte scan
- /cmapf2_ch_hi exch def
- sHKs cmapf2_ch_hi sHK_sz mul getu16
- /sH_offset exch def
- sH_gIA sH_offset sH_sz getinterval
- dup 0 getu16 /firstCode exch def
- dup 2 getu16 /entryCount exch def
- dup 4 gets16 /idDelta exch def
- dup 6 getu16 /idRangeOffset exch def
- pop
- sH_offset 0 eq {
- /cmapf2_ch_lo cmapf2_ch_hi def
- /cmapf2_ch_hi 0 def
- .cmapf2_putGID
- } {
- 16#00 1 16#ff { % lo_byte scan
- /cmapf2_ch_lo exch def
- .cmapf2_putGID
- } for
- } ifelse
- } for
- pop
- 0 1 cmapf2_glyph_array length 1 sub { % rewrite null -> 0.
- dup cmapf2_glyph_array exch get
- null eq { cmapf2_glyph_array exch 0 put } {pop} ifelse
- } for
- cmapf2_glyph_array
- } bind
- 4 { % Microsoft/Adobe segmented mapping.
- /etab exch def
- /nseg2 etab 6 getu16 def
- 14 /endc etab 2 index nseg2 getinterval 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
- % The following hack allows us to properly handle
- % idiosyncratic fonts that start at 0xf000:
- pop
- /firstcode startc 0 getu16 16#ff00 and dup 16#f000 ne { pop 0 } if def
- /putglyph {
- glyphs code 3 -1 roll put /code code 1 add def
- } bind def
- % Do a first pass to compute the size of the glyphs array.
- /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
- numcodes scode firstcode sub
- % Hack for fonts that have only 0x0000 and 0xf000 ranges
- %dup 16#e000 ge { 255 and } if
- % the previous line is obstructive to CJK fonts, so it was removed
- exch sub 0 .max ecode scode sub 1 add add
- exch 1 index add exch
- numcodes add /numcodes exch def
- } for array def
- % prefill the array with 0's faster than a { 0 putglyph } repeat
- glyphs length 1024 ge {
- .array1024z 0 1024 glyphs length 1023 sub { glyphs exch 2 index putinterval } for
- glyphs dup length 1024 sub 3 -1 roll
- putinterval
- } {
- 0 1 glyphs length 1 sub { glyphs exch 0 put } for
- } ifelse
- % Now fill in the array.
- /numcodes 0 def /code 0 def
- 0 2 nseg2 3 sub {
- /i2 exch def
- /scode startc i2 getu16 def
- /ecode endc i2 getu16 def
- numcodes scode firstcode sub
- % Hack for fonts that have only 0x0000 and 0xf000 ranges
- %dup 16#e000 ge { 255 and } if
- % the previous line is obstructive to CJK fonts, so it was removed
- exch sub 0 .max dup /code exch code exch add def
- ecode scode sub 1 add add numcodes add /numcodes exch def
- /delta iddelta i2 gets16 def
- TTFDEBUG {
- (scode=) print scode =only
- ( ecode=) print ecode =only
- ( delta=) print delta =only
- ( droff=) print idroff i2 getu16 =
- } if
- idroff i2 getu16 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
- dup 0 ne { delta add 65535 and } if putglyph
- } for
- } ifelse
- } for glyphs /glyphs null def % for GC
- } bind
- 6 { % Single interval lookup.
- dup 6 getu16 /firstcode exch def dup 8 getu16 /ng exch def
- firstcode ng add array
- % Stack: tab array
- % Fill elements 0 .. firstcode-1 with 0
- 0 1 firstcode 1 sub { 2 copy 0 put pop } for
- dup firstcode ng getinterval
- % Stack: tab array subarray
- % Fill elements firstcode .. firstcode+nvalue-1 with glyph values
- 0 1 ng 1 sub {
- dup 2 mul 10 add 4 index exch getu16 3 copy put pop pop
- } for pop exch pop
- } bind
-.dicttomark readonly def % cmapformats
-
-% <cmaptab> cmaparray <glypharray>
-/cmaparray {
- dup 0 getu16 cmapformats exch .knownget {
- TTFDEBUG {
- (cmap: format ) print 1 index 0 getu16 = flush
- } if exec
- } {
- (Can't handle format ) print 0 getu16 = flush
- 0 1 255 { } for 256 packedarray
- } ifelse
- TTFDEBUG {
- (cmap: length=) print dup length = dup ==
- } if
-} bind def
-
-% Define remapping for misnamed glyphs in TrueType 'post' tables.
-% There are probably a lot more than this!
-/postremap mark
- /Cdot /Cdotaccent
- /Edot /Edotaccent
- /Eoverdot /Edotaccent
- /Gdot /Gdotaccent
- /Ldot /Ldotaccent
- /Zdot /Zdotaccent
- /cdot /cdotaccent
- /edot /edotaccent
- /eoverdot /edotaccent
- /gdot /gdotaccent
- /ldot /ldotaccent
- /zdot /zdotaccent
-.dicttomark readonly def
-
-% Each procedure in this dictionary is called as follows:
-% posttable <<proc>> glyphencoding
-/postformats mark
- 16#00010000 { % 258 standard Macintosh glyphs.
- pop MacGlyphEncoding
- }
- 16#00020000 { % Detailed map, required by Microsoft fonts.
- dup length 36 lt {
- TTFDEBUG { (post format 2.0 invalid.) = flush } if
- pop [ ]
- } {
- /postglyphs exch def
- postglyphs 32 getu16 /numglyphs exch def
- /glyphnames numglyphs 2 mul 34 add def
- % Build names array in the order they occur in the 'post' table
- /postpos glyphnames def
- [ numglyphs 1 sub {
- postpos postglyphs length ge { exit } if
- % No name available, /postnames will be defined as an empty
- % array and the glyph won't get a name attached.
- postglyphs postpos get
- postglyphs postpos 1 add 2 index getinterval cvn
- exch postpos add 1 add /postpos exch def
- } repeat
- ] /postnames exch def
- [ 0 1 numglyphs 1 sub {
- 2 mul 34 add postglyphs exch getu16
- dup 258 lt {
- MacGlyphEncoding exch get
- } {
- dup 32768 ge {
- % According to the published TrueType spec, such values are
- % "reserved for future use", but at least some PDF files
- % produced by the Adobe PDF library contain entries with a
- % value of 16#ffff.
- pop /.notdef
- } {
- % Get the name for this glyph
- 258 sub dup postnames length ge {
- TTFDEBUG { ( *** warning: glyph index past end of 'post' table) = flush } if
- exit
- } if
- postnames exch get
- % At least some of Microsoft's TrueType fonts use incorrect
- % (Adobe-incompatible) names for some glyphs.
- % Correct for this here.
- postremap 1 index .knownget { exch pop } if
- } ifelse
- } ifelse
- } for ]
- }
- ifelse
- } bind
- 16#00030000 { % No map.
- pop [ ]
- } bind
-.dicttomark readonly def % postformats
-
-% - .getpost -
-% Uses post, defines glyphencoding
-/.getpost {
- /glyphencoding post null eq {
- TTFDEBUG { (post missing) = flush } if [ ]
- } {
- postformats post 0 getu32 .knownget {
- TTFDEBUG {
- (post: format ) print
- post 0 getu16 =only (,) print post 2 getu16 = flush
- } if
- post exch exec
- } {
- TTFDEBUG { (post: unknown format ) print post 0 getu32 = flush } if [ ]
- } ifelse
- } ifelse def
-} bind def
-
-% ===================== True Type Interpretation =============
-
-/TTParser <<
- /Pos 0
- /post null
->> def
-
-/readu8 % <file> readu8 <int>
-{ read not {
- mark (Insufficient data in the stream.) //error exec
- } if
-} bind def
-
-/readu16 % <file> readu16 <int>
-{ dup //readu8 exec 8 bitshift exch //readu8 exec or
-} bind def
-
-/reads16 % <file> reads16 <int>
-{ //readu16 exec 16#8000 xor 16#8000 sub
-} bind def
-
-/readu32 % <file> readu32 <int>
-{ dup //readu16 exec 16 bitshift exch //readu16 exec or
-} bind def
-
-/reads32 % <file> reads32 <int>
-{ dup //reads16 exec 16 bitshift exch //readu16 exec or
-} bind def
-
-/SkipToPosition % <file> <int> SkipToPosition -
-{ dup //TTParser /Pos get % f P P p
- exch //TTParser exch /Pos exch put % f P p
- sub % f P-p
- //PDFR_DEBUG {
- (Skipping ) print dup //=only exec ( bytes.) =
- } if
- dup 0 eq {
- pop pop
- } {
- //BlockBuffer exch 0 exch getinterval readstring not {
- mark (Insufficient data in the stream for SkipToPosition.) //error exec
- } if % s
- pop %
- } ifelse
-} bind def
-
-/TagBuffer 4 string def
-
-/ParseTTTableDirectory % <file> ParseTTTableDirectory <dict>
-{ //PDFR_DEBUG {
- (ParseTTTableDirectory beg) =
- } if
- 15 dict begin
- dup //readu32 exec 16#00010000 ne {
- mark (Unknown True Type version.) //error exec
- } if
- dup //readu16 exec /NumTables exch def
- dup //readu16 exec /SearchRange exch def
- dup //readu16 exec /EntrySelector exch def
- dup //readu16 exec /RangeShift exch def
- //PDFR_DEBUG {
- (NumTables = ) print NumTables =
- } if
- NumTables {
- dup //TagBuffer readstring not {
- mark (Could not read TT tag.) //error exec
- } if
- cvn
- [ 2 index //readu32 exec pop % CheckSum
- 2 index //readu32 exec % Offset
- 3 index //readu32 exec % Length
- ]
- //PDFR_DEBUG {
- 2 copy exch //=only exec ( ) print ==
- } if
- def
- } repeat
- pop % file
- //TTParser /Pos 12 NumTables 16 mul add put
- currentdict end
- //PDFR_DEBUG {
- (ParseTTTableDirectory end) =
- } if
-} bind def
-
-/ParseTTcmap % <file> <TableDirectory> ParseTTcmap <dict>
-{ //PDFR_DEBUG {
- (ParseTTcmap beg) =
- } if
- /cmap get aload pop % f o L
- 3 1 roll % L f o
- 7 dict begin
- //PDFR_DEBUG {
- (Current position = ) print //TTParser /Pos get =
- (cmap position = ) print dup =
- } if
- 1 index exch //SkipToPosition exec % L f
- //TTParser /Pos get /TablePos exch def
- dup //readu16 exec pop % version
- dup //readu16 exec /NumEncodings exch def
- //PDFR_DEBUG {
- (NumEncodings = ) print NumEncodings =
- } if
- null % L f null
- NumEncodings {
- 1 index //readu32 exec % platformID, specificID % L f null id
- 2 index //readu32 exec % offset % L f null id o
- 3 array dup 3 2 roll 0 exch put % L f []|null id []
- 2 index null ne {
- dup 0 get 3 index 0 get sub % L f []|null id [] l
- 3 index exch 1 exch put % L f []|null id []
- } if
- dup 4 3 roll pop 3 1 roll % L f [] id []
- def
- } repeat % L f []
- dup 0 get % L f [] o
- 4 3 roll exch sub % f [] L-o
- 1 exch put % f
- //PDFR_DEBUG {
- currentdict {
- exch dup type /integertype eq {
- //PrintHex exec ( ) print ==
- } {
- pop pop
- } ifelse
- } forall
- } if
- 4 NumEncodings 8 mul add /HeaderLength exch def
- //TTParser /Pos //TTParser /Pos get HeaderLength add put
- 0 % f o
- NumEncodings {
- 16#7FFFFFF null % f o om null|[]
- % Choosing a table with minimal offset greater than 'o' :
- currentdict {
- 1 index type /integertype eq { % f o om null|[] id []
- exch pop dup 0 get % f o om null|[] [] oi
- dup 5 index gt {
- dup 4 index lt {
- 4 1 roll % f o oi om null|[] []
- exch pop exch pop % f o oi []
- } {
- pop pop
- } ifelse
- } {
- pop pop
- } ifelse % f o oi []
- } {
- pop pop
- } ifelse
- } forall % f o om' []
- //PDFR_DEBUG {
- (Obtaining subtable for ) print dup ==
- } if
- 3 2 roll pop % f o' []
- 3 copy pop % f o' [] f o'
- TablePos add //SkipToPosition exec % f o' []
- 3 copy exch pop 1 get % f o' [] l
- //TTParser /Pos //TTParser /Pos get 3 index add put
- string % f o' [] f ()
- readstring not {
- mark (Can't read a cmap subtable.) //error exec
- } if % f o' [] ()
- 2 exch put % f o'
- } repeat
- pop pop %
- currentdict end
- //PDFR_DEBUG {
- (ParseTTcmap end) =
- } if
-} bind def
-
-/GetTTEncoding % <file> <TTcmapHeader> <platformIDspecificID> GetTTEncoding <array>
-{ //PDFR_DEBUG {
- (GetTTEncoding beg) =
- } if
- get % f []
- exch pop % []
- 2 get
- 10 dict begin % For local variables.
- /TTFDEBUG //PDFR_DEBUG def
- //cmaparray exec
- end
- //PDFR_DEBUG {
- (GetTTEncoding end) =
- dup ==
- } if
-} bind def
-
-/InverseEncoding % <encoding> InverseEncoding <dict>
-{
- 256 dict begin
- dup length 1 sub -1 0 { % E i
- 2 copy get % E i n
- exch % E n i
- 1 index currentdict exch //knownget exec { % E n i e
- dup type /arraytype eq {
- aload length 1 add array astore % E n e'
- } {
- 2 array astore % E n e'
- } ifelse
- } if
- def
- } for
- pop
- currentdict end
-} bind def
-
-/GetMacRomanEncodingInverse
-{ //PDFReader /MacRomanEncodingInverse get
- dup null eq {
- pop
- MacRomanEncoding //InverseEncoding exec
- dup //PDFReader exch /MacRomanEncodingInverse exch put
- } if
-} bind def
-
-/PutCharStringSingle % <cmap_array> <glyph_name> <char_code> PutCharStringSingle <cmap_array>
-{
- dup 3 index length lt { % cmap name code
- 2 index exch get % cmap name glyphindex
- dup 0 ne {
- def % cmap
- } {
- pop pop
- } ifelse
- } {
- pop pop % cmap
- } ifelse
-} bind def
-
-/PutCharString % <cmap_array> <glyph_name> <char_code> PutCharString <cmap_array>
-{ 1 index type /nametype ne {
- mark (Bad charstring name) //error exec
- } if
- dup type /arraytype eq {
- { % cmap name code
- 3 copy //PutCharStringSingle exec % cmap name code cmap
- pop pop % cmap name
- } forall
- pop % cmap
- } {
- //PutCharStringSingle exec
- } ifelse
-} bind def
-
-/ComposeCharStrings % <cmaparray> <dict> ComposeCharStrings <dict>
-{
- //PDFR_DEBUG {
- (ComposeCharStrings beg) =
- } if
- 1 index length 1 add dict begin % cmap d
- % fixme : the dict length estimation doesn't account 'post'.
- /.notdef 0 def
- exch % d cmap
- //TTParser /post get % d cmap [post]|null
- dup null ne {
- exch % d [] cmap
- 1 index length 1 sub -1 0 { % d [] cmap code
- dup 3 index exch get exch % d [] cmap name code
- dup 0 eq {
- pop pop
- } {
- def
- } ifelse
- } for
- } if
- exch pop exch % cmap d
- { % cmap name code
- //PutCharString exec
- } forall % cmap
- pop %
- currentdict end
- //PDFR_DEBUG {
- (ComposeCharStrings end) =
- } if
-} bind def
-
-/ParseTTpost % <file> <TableDirectory> ParseTTpost -
-{ % Defines TTparser.post - an array,
- % which maps glyph indices to glyph names.
- //PDFR_DEBUG {
- (ParseTTpost beg) =
- } if
- /post get aload pop % f o L
- 3 1 roll % L f o
- //PDFR_DEBUG {
- (Current position = ) print //TTParser /Pos get =
- (post position = ) print dup =
- } if
- 1 index exch //SkipToPosition exec % L f
- //TTParser /Pos //TTParser /Pos get 4 index add put
- exch string % f s
- readstring not {
- mark (Insufficient data in the stream for ParseTTpost.) //error exec
- } if % s
- 1 dict begin % A bridge to the code from /gs/lib/gs_ttf.ps .
- /post exch def
- //.getpost exec
- //TTParser /post glyphencoding put
- //PDFR_DEBUG {
- (ParseTTpost end) =
- glyphencoding ==
- } if
- end
-} bind def
-
-/MakeTTCharStrings % <FontFile_object> MakeTTCharStrings <CharStrings>
-{ //MakeStreamReader exec % f
- dup dup //ParseTTTableDirectory exec % f f d
- % Since the file isn't positionable,
- % we must pick up either 'post' or 'cmap' first.
- % Deside which one we do first :
- //TTParser /post null put
- dup /post //knownget exec {
- 0 get
- 1 index /cmap get 0 get
- lt {
- 2 copy //ParseTTpost exec % f f d
- //ParseTTcmap exec % f ch
- } {
- 2 copy //ParseTTcmap exec % f f d ch
- 3 1 roll % f ch f d
- //ParseTTpost exec % f ch
- } ifelse
- } {
- //ParseTTcmap exec % f ch
- } ifelse
- {
- dup 16#00030001 known {
- //PDFR_DEBUG {
- (Using the TT cmap encoding for Windows Unicode.) =
- } if
- 16#00030001 //GetTTEncoding exec
- AdobeGlyphList //ComposeCharStrings exec
- exit
- } if
- dup 16#00010000 known {
- //PDFR_DEBUG {
- (Using the TT cmap encoding for Macintosh Roman.) =
- } if
- 16#00010000 //GetTTEncoding exec
- PDFEncoding dup null eq {
- pop //GetMacRomanEncodingInverse exec
- } {
- //InverseEncoding exec
- } ifelse
- //ComposeCharStrings exec
- exit
- } if
- dup 16#00030000 known {
- //PDFR_DEBUG {
- (Using the TT cmap encoding 3.0 - not sure why Ghostscript writes it since old versions.) =
- } if
- % Same algorithm as for 16#00010000.
- 16#00030000 //GetTTEncoding exec
- PDFEncoding dup null eq {
- pop //GetMacRomanEncodingInverse exec
- } {
- //InverseEncoding exec
- } ifelse
- //ComposeCharStrings exec
- exit
- } if
- mark (True Type cmap has no useful encodings.) //error exec
- } loop
- //PDFR_DEBUG {
- (CharStrings <<) =
- dup {
- exch
- dup type /nametype eq {
- //=only exec
- } {
- ==
- } ifelse
- ( ) print ==
- } forall
- (>>) =
- } if
-} bind def
-
-%%end TrueType
-
-% ===================== Functions ============================
-
-/ScaleVal % <value> <Range> ScaleVal <scaled_value>
-{
- aload pop % v r0 r1
- 1 index sub % v r0 r1-r0
- 3 2 roll mul add
-} bind def
-
-/ScaleArg % <arg> <Domain> ScaleArg <scaled_arg>
-{
- aload pop % a d0 d1
- 1 index sub % a d0 d1-d0
- 3 1 roll % d1-d0 a d0
- sub exch div % (a-d0)/(d1-d0)
-} bind def
-
-/ScaleArgN % <arg1> ... <argN> <Domain> ScaleArg <scaled_arg1> ... <scaled_argN>
-{
- dup length 2 sub -2 0 { % a1 ... an [] 2i
- 2 % a1 ... an [] 2i 2
- 2 index 3 1 roll getinterval % a1 ... an [] []
- 3 2 roll % a1 ... [] [] an
- exch //ScaleArg exec % a1 ... [] an'
- 1 index length 2 idiv 1 add 1 roll % an' a1 ... []
- } for % a1' ... an' []
- pop % a1' ... an'
-} bind def
-
-
-/ComputeFunction_10 % <scaled_arg> <sample_array> ComputeFunction_10 <result>
-{ % Assuming a 1-argument 1-result function type 0.
- //PDFR_DEBUG {
- (ComputeFunction_10 beg ) print 1 index //=only exec ( stack=) print count =
- } if
- exch % [] x
- dup 1 eq {
- pop dup length 1 sub get % y
- } {
- 1 index length 1 sub mul % [] x*(l-1)
- dup dup floor sub % [] x*(l-1) f
- dup 0 eq {
- pop cvi get % y
- } {
- 3 1 roll floor cvi % f [] i
- 2 getinterval % f []
- aload pop % f y0 y1
- 2 index mul 3 2 roll 1 exch sub 3 2 roll mul add % y1*f+(1-f)*y0
- } ifelse
- } ifelse
- //PDFR_DEBUG {
- (ComputeFunction_10 end ) print dup //=only exec ( stack=) print count =
- } if
-} bind def
-
-/ComputeFunction_n0 % <arg1> .... <argn> <sample_array> <n> ComputeFunction_n0 <result>
-{ % Assuming a n-argument 1-result function type 0.
- //PDFR_DEBUG {
- (ComputeFunction_n0 beg N=) print dup //=only exec ( stack=) print count =
- } if
- dup 0 eq { % v 0
- pop % v
- } {
- dup 2 add -1 roll % a2 .... an [] n a1
- dup 3 index length 1 sub ge {
- pop 1 sub % a2 .... an [] n-1
- exch dup length 1 sub get exch
- //PDFReader /ComputeFunction_n0 get exec
- } {
- dup floor cvi dup % a2 .... an [] n a1 i i
- 4 index exch get % a2 .... an [] n a1 i [i]
- 3 index dup % a2 .... an [] n a1 i [i] n n
- 5 add copy % a2 .... an [] n a1 i [i] n a2 .... an [] n a1 i [i] n
- 6 2 roll % a2 .... an [] n a1 i [i] n a2 .... an [i] n [] n a1 i
- pop pop pop pop % a2 .... an [] n a1 i [i] n a2 .... an [i] n
- 1 sub % a2 .... an [] n a1 i [i] n a2 .... an [i] n-1
- //PDFReader /ComputeFunction_n0 get exec % a2 .... an [] n a1 i [i] n v0
- 3 2 roll pop % a2 .... an [] n a1 i n v0
- exch % a2 .... an [] n a1 i v0 n
- 4 3 roll exch % a2 .... an [] n i v0 a1 n
- 4 add 2 roll 1 add % v0 a1 a2 .... an [] n i+1
- 3 2 roll exch get % v0 a1 a2 .... an n [i+1]
- exch 1 sub % v0 a1 a2 .... an [i+1] n-1
- //PDFReader /ComputeFunction_n0 get exec % v0 a1 v1
- 1 index mul % v0 a1 v1*a1
- 3 1 roll % v1*a1 v0 a1
- 1 exch sub mul add % v1*a1+v0*(1-a1)
- } ifelse
- } ifelse
- //PDFR_DEBUG {
- (ComputeFunction_n0 end ) print dup //=only exec ( stack=) print count =
- } if
-} bind def
-
-/FunctionToProc_x01 % <function_dict> FunctionToProc_x01 <proc>
-{ % Assuming a n-argument 1-result function type 0.
- % The stream is already converted to the array /Data.
- dup /Domain get exch
- dup /Data get 0 get exch
- /Size get length
- [ 4 1 roll
- //PDFR_DEBUG {
- { (function beg, stack =) print count //=only exec (\n) print } /exec load
- 5 2 roll
- } if
- dup 1 gt { % a1 ... an Domain Data n
- { mark exch % a1 ... an Domain Data [ n
- 3 add 2 roll % Data [ a1 ... an Domain
- //ScaleArgN exec % Data [ a1 ... an
- counttomark dup % Data [ a1 ... an n n
- 3 add -2 roll % a1 ... an n Data [
- pop exch % a1 ... an Data n
- //ComputeFunction_n0 exec
- } /exec load
- } {
- pop % a1 Domain Data
- 3 1 /roll load //ScaleArg /exec load % Data a1s
- /exch load
- //ComputeFunction_10 /exec load
- } ifelse
- //PDFR_DEBUG {
- (function end, stack =) /print load /count load //=only /exec load (\n) /print load
- } if
- ] cvx
- //PDFR_DEBUG {
- (Made a procedure for the 1-result function :) =
- dup ==
- } if
-} bind def
-
-/FunctionProcDebugBeg % - FunctionProcDebugBeg -
-{ (FunctionProcDebugBeg ) print count =
-} bind def
-
-/FunctionProcDebugEnd % - FunctionProcDebugEnd -
-{ (FunctionProcDebugEnd ) print count =
-} bind def
-
-/FunctionToProc_x0n % <function_dict> <m> FunctionToProc_x0n <proc>
-{ % Assuming a n-argument m-result function type 0.
- % The stream is already converted to the array /Data.
- %
- % Making the procedure : { Domain //ScaleArg exec ... n copy {} exec n+1 1 roll ... }
- % except "n copy" for the last chunk.
- %
- PDFR_DEBUG {
- (FunctionToProc_x0n beg m=) print dup =
- } if
- 1 index /Size get length exch % f n m
- dup 7 mul 2 add array % f n m []
- PDFR_DEBUG {
- dup 0 //FunctionProcDebugBeg put
- } {
- dup 0 //DoNothing put
- } ifelse
- dup 1 /exec load put
- dup 2 5 index /Domain get put
- 2 index 1 eq {
- dup 3 //ScaleArg put
- } {
- dup 3 //ScaleArgN put
- } ifelse
- dup 4 /exec load put
- 1 index 1 sub 0 exch 1 exch { % f n m [] i
- dup 7 mul 5 add % f n m [] i i1
- 1 index 4 index 1 sub ne {
- dup 3 index exch 6 index put 1 add
- dup 3 index exch /copy load put 1 add
- } if
- [ % f n m [] i i1 [
- 6 index /Data get 3 index get % f n m [] i i1 [ di
- 6 index 1 eq {
- //ComputeFunction_10 /exec load
- } {
- 6 index
- //ComputeFunction_n0 /exec load
- } ifelse
- ] cvx % f n m [] i i1 {}
- 3 index exch 2 index exch put 1 add % f n m [] i i1
- 2 index 1 index /exec load put 1 add
- 1 index 4 index 1 sub ne {
- 2 index 1 index 6 index 1 add put 1 add
- 2 index 1 index 1 put 1 add
- 2 index 1 index /roll load put % f n m [] i i1
- } if
- pop pop % f n m []
- } for
- PDFR_DEBUG {
- dup dup length 2 sub //FunctionProcDebugEnd put
- } {
- dup dup length 2 sub //DoNothing put
- } ifelse
- dup dup length 1 sub /exec load put
- cvx exch pop exch pop exch pop
- //PDFR_DEBUG {
- (Made a procedure for the n-argument function :) =
- dup ==
- } if
- PDFR_DEBUG {
- (FunctionToProc_x0n end) =
- } if
-} bind def
-
-/MakeTableRec % <func_obj> <n> MakeTableRec <array>
-{
- 0 % to be bound below
- exec
-} bind def
-
-/MakeTable % <func_obj> <n> MakeTable <array>
-{ //PDFR_DEBUG {
- (MakeTable beg ) print count =
- } if
- 1 index /Size get exch % f S N
- 1 sub dup % f S n n
- 3 1 roll % f n S n
- get % f n s
- array % f n []
- 1 index 0 eq {
- exch pop exch pop % []
- } {
- dup length 1 sub -1 0 { % f n [] i
- 3 index 3 index //MakeTableRec exec % f n [] i []
- 2 index 3 1 roll put % f n []
- } for
- exch pop exch pop
- } ifelse
- //PDFR_DEBUG {
- (MakeTable end ) print count =
- } if
-} bind def
-
-//MakeTableRec 0 //MakeTable put
-
-/StoreSample % <value> <table> <dimensions> StoreSample -
-{ % The reader is on the dictionary stack.
- 1 sub
- dup 0 eq {
- pop % v []
- } {
- -1 1 { % v T i
- I exch get get % v T[I[i]]
- } for % v []
- } ifelse
- I 0 get 3 2 roll put
-} bind def
-
-/ReadSample32 % - ReadSample32 <value>
-{
- 4 {
- File read not {
- mark (Insufficient data for function.) //error exec
- } if
- } repeat
- pop % Ignore the last byte because it can't fit into 'real'.
- 3 1 roll exch
- 256 mul add 256 mul add
- //1_24_bitshift_1_sub div
-} bind def
-
-/ReadSample % - ReadSample <value>
-{ % The reader in on the dictionary stack.
- Buffer BitsLeft BitsPerSample
- { 2 copy ge {
- exit
- } if
- 3 1 roll
- 8 add 3 1 roll
- 256 mul File read not {
- mark (Insufficient data for function.) //error exec
- } if
- add
- 3 1 roll
- } loop % b bl pbs
- sub dup % b bl-bps bl-bps
- 2 index exch % b bl-bps b bl-bps
- neg bitshift % b bl-bps v
- 2 copy exch bitshift % b bl-bps v v<<(bl-bps)
- 4 3 roll exch sub % bl-bps v b-(v<<(bl-bps))
- /Buffer exch def % bl-bps v
- exch /BitsLeft exch def % v
- Div div % v/(1<<pbs-1)
-} bind def
-
-/ReadSamplesRec % <dimensions> ReadSamplesRec -
-{ 0 % Will be bound below
- exec
-} bind def
-
-/ReadSamples % <dimensions> ReadSamples -
-{ % The reader in on the dictionary stack.
- //PDFR_DEBUG {
- (ReadSamples beg ) print count =
- } if
- dup 1 eq {
- pop
- 0 1 Size 0 get 1 sub {
- I exch 0 exch put
- 0 1 M 1 sub {
- dup Range exch 2 mul 2 getinterval % m r
- //PDFR_DEBUG {
- (Will read a sample ... ) print
- } if
- BitsPerSample 32 eq { //ReadSample32 } { //ReadSample } ifelse
- exec exch //ScaleVal exec % m v
- //PDFR_DEBUG {
- (value=) print dup =
- } if
- exch Table exch get % v []
- Size length //StoreSample exec %
- } for
- } for
- } {
- 1 sub
- dup Size exch get 0 exch 1 exch 1 sub { % d-1 i
- I exch 2 index exch put % d-1
- dup //ReadSamplesRec exec % d-1
- } for
- pop
- } ifelse
- //PDFR_DEBUG {
- (ReadSamples end ) print count =
- } if
-} bind def
-
-//ReadSamplesRec 0 //ReadSamples put
-
-/StreamToArray % <obj> StreamToArray -
-{ //PDFR_DEBUG {
- (StreamToArray beg ) print count =
- } if
- currentglobal true setglobal exch
- userdict /FuncDataReader get begin % g f
- dup /BitsPerSample get /BitsPerSample exch def
- dup /Size get length /N exch def
- dup /Range get length 2 idiv /M exch def
- 1 BitsPerSample bitshift 1 sub /Div exch def
- /BitsLeft 0 def
- /Buffer 0 def
- dup /Size get /Size exch def % g f
- dup /Range get /Range exch def % g f
- /File 1 index //MakeStreamReader exec def % g f
- /I [ N { 0 } repeat ] def % g f
- M array % g f []
- dup length 1 sub -1 0 { % g f [] m
- 2 index N //MakeTable exec % g f [] m T
- 2 index 3 1 roll put % g f []
- } for
- /Table exch def % g f
- N //ReadSamples exec % g f
- PDFR_DEBUG {
- (Table = ) print Table ==
- } if
- /Data Table put % g
- end
- setglobal %
- //PDFR_DEBUG {
- (StreamToArray end ) print count =
- } if
-} bind def
-
-/FunctionToProc10 % <function_dict> FunctionToProc10 <proc>
-{ % Assuming a 1-argument function type 0.
- PDFR_DEBUG {
- (FunctionToProc10 beg, Range = ) print dup /Range get ==
- } if
- dup /Order //knownget exec {
- 1 ne {
- (Underimplemented function Type 0 Order 3.) =
- } if
- } if
- dup //StreamToArray exec % f
- dup /Range get length dup 2 eq {
- pop //FunctionToProc_x01 exec % proc
- } {
- 2 idiv //FunctionToProc_x0n exec % proc
- } ifelse
- PDFR_DEBUG {
- (FunctionToProc10 end) =
- } if
-} bind def
-
-/FunctionToProc12 % <function_dict> FunctionToProc12 <proc>
-{ begin
- currentdict /C0 //knownget exec { length 1 eq } { true } ifelse {
- N
- currentdict /C0 //knownget exec {
- 0 get
- } {
- 0
- } ifelse
- currentdict /C1 //knownget exec {
- 0 get
- } {
- 1
- } ifelse
- 1 index sub
- [ 4 1 roll
- { % x n c0 c1-c0
- 4 2 roll % c0 c1-c0 x n
- excp mul add % y
- } aload pop
- ] cvx
- } {
- [
- 0 1 C0 length 1 sub {
- N % [ ... i n
- C0 2 index get % [ ... i n c0
- C1 3 index get % [ ... i n c0 c1
- 4 3 roll pop % [ ... n c0 c1
- 1 index sub % [ ... n c0 c1-c0
- [ /dup load % [ ... n c0 c1-c0 [ dup
- 5 2 roll % [ ... [ dup n c0 c1-c0
- { % x x n c0 c1-c0
- 4 2 roll % x c0 c1-c0 x n
- exp mul add % x y
- exch % y x
- } aload pop
- ] cvx
- /exec load
- } for
- /pop load
- ] cvx
- } ifelse
- end
- //PDFR_DEBUG {
- (FunctionType2Proc : ) print dup ==
- } if
-} bind def
-
-
-/FunctionToProc14 % <function_dict> FunctionToProc14 <proc>
-{ //MakeStreamReader exec cvx exec
- //PDFR_DEBUG {
- (FunctionType4Proc : ) print dup ==
- } if
-} bind def
-
-/FunctionToProc1 % <function_dict> FunctionToProc <proc>
-{ % Assuming a 1-argument function.
- dup /FunctionType get
- { dup 0 eq {
- pop //FunctionToProc10 exec exit
- } if
- dup 2 eq {
- pop //FunctionToProc12 exec exit
- } if
- dup 4 eq {
- pop //FunctionToProc14 exec exit
- } if
- mark exch (Function type ) exch ( isn't implemented yet.) //error exec
- } loop
-} bind def
-
-/FunctionToProc20 % <function_dict> FunctionToProc20 <proc>
-{ % Assuming a 2-argument function type 0.
- PDFR_DEBUG {
- (FunctionToProc20, Range = ) print dup /Range get ==
- } if
- dup /Order //knownget exec {
- 1 ne {
- (Underimplemented function Type 0 Order 3.) =
- } if
- } if
- dup //StreamToArray exec % f
- dup /Range get length dup 2 eq {
- pop //FunctionToProc_x01 exec % proc
- } {
- 2 idiv //FunctionToProc_x0n exec % proc
- } ifelse
-} bind def
-
-/FunctionToProc % <function_dict> FunctionToProc <proc>
-{ //PDFR_DEBUG {
- (FunctionToProc beg ) print count =
- } if
- dup /Domain get length 2 idiv
- {
- dup 1 eq {
- pop //FunctionToProc1 exec exit
- } if
- dup 2 eq {
- pop //FunctionToProc20 exec exit
- } if
- mark (Functions with many arguments aren't implemented yet.) //error exec
- } loop
- //PDFR_DEBUG {
- (FunctionToProc end ) print count =
- } if
-} bind def
-
-/spotfunctions mark % Copied from pdf_draw.ps
- /Round {
- abs exch abs 2 copy add 1 le {
- dup mul exch dup mul add 1 exch sub
- } {
- 1 sub dup mul exch 1 sub dup mul add 1 sub
- } ifelse
- }
- /Diamond {
- abs exch abs 2 copy add .75 le {
- dup mul exch dup mul add 1 exch sub
- } {
- 2 copy add 1.23 le {
- .85 mul add 1 exch sub
- } {
- 1 sub dup mul exch 1 sub dup mul add 1 sub
- } ifelse
- } ifelse
- }
- /Ellipse {
- abs exch abs 2 copy 3 mul exch 4 mul add 3 sub dup 0 lt {
- pop dup mul exch .75 div dup mul add 4 div 1 exch sub
- } {
- dup 1 gt {
- pop 1 exch sub dup mul exch 1 exch sub
- .75 div dup mul add 4 div 1 sub
- } {
- .5 exch sub exch pop exch pop
- } ifelse
- } ifelse
- }
- /EllipseA { dup mul .9 mul exch dup mul add 1 exch sub }
- /InvertedEllipseA { dup mul .9 mul exch dup mul add 1 sub }
- /EllipseB { dup 5 mul 8 div mul exch dup mul exch add sqrt 1 exch sub }
- /EllipseC { dup mul .9 mul exch dup mul add 1 exch sub }
- /InvertedEllipseC { dup mul .9 mul exch dup mul add 1 sub }
- /Line { exch pop abs neg }
- /LineX { pop }
- /LineY { exch pop }
- /Square { abs exch abs 2 copy lt { exch } if pop neg }
- /Cross { abs exch abs 2 copy gt { exch } if pop neg }
- /Rhomboid { abs exch abs 0.9 mul add 2 div }
- /DoubleDot { 2 {360 mul sin 2 div exch } repeat add }
- /InvertedDoubleDot { 2 {360 mul sin 2 div exch } repeat add neg }
- /SimpleDot { dup mul exch dup mul add 1 exch sub }
- /InvertedSimpleDot { dup mul exch dup mul add 1 sub }
- /CosineDot { 180 mul cos exch 180 mul cos add 2 div }
- /Double { exch 2 div exch 2 { 360 mul sin 2 div exch } repeat add }
- /InvertedDouble {
- exch 2 div exch 2 { 360 mul sin 2 div exch } repeat add neg
- }
-.dicttomark readonly def
-
-% ===================== Color Spaces and Colors ==============
-
-/CheckColorSpace % <key> <val> CheckColorSpace <key> <val>
-{
- dup type /arraytype ne {
- mark (Resource ) 3 index ( must be an array.) //error exec
- } if
-} bind def
-
-/SubstitutePDFColorSpaceRec % <array> SubstitutePDFColorSpace <array>
-{ 0 % Will be bound below
- exec
-} bind def
-
-/SubstitutePDFColorSpace % <array> SubstitutePDFColorSpace <array>
-{ currentglobal true setglobal exch
- {
- dup 0 get /Pattern eq {
- dup length 1 gt {
- dup dup 1 //CheckColorSpace //ResolveA exec
- dup type /nametype ne {
- //SubstitutePDFColorSpaceRec exec
- } if
- 1 exch put
- } if
- exit
- } if
- dup 0 get /Indexed eq {
- exit
- } if
- dup 0 get /Separation eq {
- dup dup 2 //CheckColorSpace //ResolveA exec
- dup type /nametype ne {
- //SubstitutePDFColorSpaceRec exec
- } if
- 2 exch put
- exit
- } if
- dup 0 get /CalGray eq {
- 1 get % dict
- dup /Gamma //knownget exec {
- [ exch /exp load ] cvx
- 1 index exch /DecodeLMN exch put
- } if
- [ exch /CIEBasedA exch ] % []
- exit
- } if
- dup 0 get /CalRGB eq {
- 1 get % dict
- dup /Matrix //knownget exec {
- 1 index exch /MatrixLMN exch put
- } if
- dup /Gamma //knownget exec {
- aload pop
- [ exch /exp load ] cvx
- 3 1 roll
- [ exch /exp load ] cvx
- 3 1 roll
- [ exch /exp load ] cvx
- 3 1 roll
- 3 array astore
- 1 index exch /DecodeLMN exch put
- } if
- [ exch /CIEBasedABC exch ] % []
- exit
- } if
- dup 0 get /Lab eq {
- 1 get % dict
- begin
- currentdict /Range //knownget exec { aload pop } { -100 100 -100 100 } ifelse
- 0 100 6 2 roll 6 array astore
- /RangeABC exch def
- /DecodeABC [{16 add 116 div} bind {500 div} bind {200 div} bind] def
- /MatrixABC [1 1 1 1 0 0 0 0 -1] def
- { dup 6 29 div ge {dup dup mul mul} {4 29 div sub 108 841 div mul} ifelse }
- /DecodeLMN [
- % Store white point implicitly inside procedures.
- [ 3 index aload pop WhitePoint 0 get /mul load ] cvx
- [ 4 index aload pop WhitePoint 1 get /mul load ] cvx
- [ 5 index aload pop WhitePoint 2 get /mul load ] cvx
- ] def pop
- //PDFR_DEBUG {
- (Constructed from Lab <<) =
- currentdict { exch = == } forall
- (>>) =
- } if
- [ /CIEBasedABC currentdict ] % []
- end
- exit
- pop
- } if
- mark exch (Unimplemented color space ) exch //error exec
- } loop
- exch setglobal
-} bind def
-
-//SubstitutePDFColorSpaceRec 0 //SubstitutePDFColorSpace put
-
-/ResolveArrayElement % <array> <index> ResolveArrayElement <array>
-{ 2 copy get xcheck {
- 2 copy get exec
- 2 index 4 1 roll put
- } {
- pop
- } ifelse
-} bind def
-
-/ResolveColorSpaceArrayRec % <color_space> ResolveColorSpaceArrayRec <color_space>
-{ 0 % Will be bond below.
- exec
-} bind def
-
-/SetColorSpaceSafe % <color_space> SetColorSpaceSafe -
-{
- % This works against applying a pattern over a pattern space,
- % which may happen due to duplication of stroking and non-stroking colors.
- % gs3.70 fails when setting a pattern space and
- % the (old) current color space is a pattern space.
- %
- % If the new color space is an array and it appears equal to the old one,
- % do nothing. Otherwise set the new color space.
- PDFR_DEBUG {
- (SetColorSpaceSafe beg) =
- } if
- currentcolorspace dup type /arraytype eq { % cs cs'
- 1 index type /arraytype eq {
- dup length 2 index length eq {
- false exch % cs b cs'
- dup length 0 exch 1 exch 1 sub { % cs b cs' i
- dup % cs b cs' i i
- 4 index exch get exch % cs b cs' csi i
- 2 index exch get % cs b cs' csi cs'i
- ne { % cs b cs'
- exch pop true exch exit
- } if
- } for % cs b cs'
- pop % cs b
- {
- setcolorspace
- } {
- pop
- } ifelse %
- } {
- pop setcolorspace
- } ifelse
- } {
- pop setcolorspace
- } ifelse
- } { % cs cs'
- pop setcolorspace
- } ifelse
- PDFR_DEBUG {
- (SetColorSpaceSafe end) =
- } if
-} bind def
-
-/ResolveColorSpaceArray % <color_space> ResolveColorSpaceArray <color_space>
-{
- //PDFR_DEBUG {
- (ResolveColorSpaceArray beg ) print dup ==
- } if
- currentglobal true setglobal exch
- dup 0 get /Indexed eq {
- 1 //ResolveArrayElement exec
- dup dup 1 get
- dup type /arraytype eq {
- //SubstitutePDFColorSpace exec
- //ResolveColorSpaceArrayRec exec
- 1 exch put
- } {
- pop pop
- } ifelse
- } if
- dup 0 get /Separation eq {
- 3 //ResolveArrayElement exec
- dup 3 get //FunctionToProc exec
- 2 copy 3 exch put
- pop
- } if
- PDFR_DEBUG {
- (Construcrted color space :) =
- dup ==
- } if
- exch setglobal
- //PDFR_DEBUG {
- (ResolveColorSpaceArray end ) print dup ==
- } if
-} bind def
-
-//ResolveColorSpaceArrayRec 0 //ResolveColorSpaceArray put
-
-/ResolveColorSpace % <name> ResolveColorSpace <color_space>
-{
- //PDFR_DEBUG {
- (ResolveColorSpace beg ) print dup =
- } if
- dup //SimpleColorSpaceNames exch known not {
- dup //PDFColorSpaces exch //knownget exec {
- exch pop
- //PDFR_DEBUG {
- (ResolveColorSpace known ) =
- } if
- } {
- dup % n n
- //PDFReader /CurrentObject get /Context get /Resources get
- /ColorSpace //DoNothing //ResolveD exec
- exch //CheckColorSpace //ResolveD exec % n cs
- dup type /arraytype eq {
- //SubstitutePDFColorSpace exec
- //ResolveColorSpaceArray exec
- dup //PDFColorSpaces 4 2 roll put % []
- } if
- } ifelse
- } if
- //PDFR_DEBUG {
- (ResolveColorSpace end ) print dup ==
- } if
-} bind def
-
-/CheckPattern % <key> <val> CheckPattern <key> <val>
-{
- dup /PatternType //knownget exec {
- dup 1 ne {
- mark (Resource ) 4 index ( is a shading, which can't be handled at level 2. ) //error exec
- } if
- pop
- } if
- dup /Type get /Pattern ne {
- mark (Resource ) 4 index ( must have /Type/Pattern .) //error exec
- } if
-} bind def
-
-/PaintProc %
-{ /Context get % pattern_object
- //RunDelayedStream exec
-} bind def
-
-/ResolvePattern % <name> ResolvePattern <pattern>
-{
- dup % n n
- % Since makepattern makes a local dictionary,
- % we cahche them in userdict, which is in local VM.
- % Assuming unique resource name through the document
- userdict /PDFR_Patterns get % n n d
- exch //knownget exec { % n p
- exch pop % p
- } { % n
- dup % n n
- //PDFReader /CurrentObject get /Context get /Resources get
- /Pattern //DoNothing //ResolveD exec
- exch //CheckPattern //ResolveD exec % n o
- dup dup /Context exch put
- dup /Resources //DoNothing //ResolveD exec pop
- dup /PaintProc //PaintProc put
- gsave userdict /PDFR_InitialGS get setgstate
- currentglobal exch false setglobal % gs3_70 compatibility
- dup /Matrix get
- makepattern % n p
- exch setglobal % gs3_70 compatibility
- grestore
- dup userdict /PDFR_Patterns get % n p p d
- 4 2 roll % p d n p
- put % p
- } ifelse
-} bind def
-
-/SetColor % Same arguments and result as for scn
-{ //PDFR_DEBUG {
- (SetColor beg) =
- } if
- currentcolorspace dup type /nametype eq {
- pop setcolor
- } {
- 0 get /Pattern eq {
- //ResolvePattern exec setpattern
- } {
- setcolor
- } ifelse
- } ifelse
- //PDFR_DEBUG {
- (SetColor end) =
- } if
-} bind def
-
-% ===================== Images ===============================
-
-/ImageKeys 15 dict begin
- /BPC /BitsPerComponent def
- /CS /ColorSpace def
- /D /Decode def
- /DP /DecodeParms def
- /F /Filter def
- /H /Height def
- /IM /ImageMask def
- % /Intent is undefined - pdfwrite must take care of.
- /I /Interpolate def
- /W /Width def
-currentdict end readonly def
-
-/ImageValues 15 dict begin
- /G /DeviceGray def
- /RGB /DeviceRGB def
- /CMYK /DeviceCMYK def
- /I /Indexed def
- /AHx /ASCIIHexDecode def
- /A85 /ASCII85Decode def
- /LZW /LZWDecode def
- /Fl /FlateDecode def
- /RL /RunLengthDecode def
- /CCF /CCITTFaxDecode def
- /DCT /DCTDecode def
-currentdict end readonly def
-
-/GetColorSpaceRange
-{ 2 index /ColorSpace get
- dup type /arraytype eq {
- 1 get
- } if
- exch //knownget exec {
- exch pop
- } if
-} bind def
-
-/DecodeArrays 15 dict begin
- /DeviceGray { [0 1] } def
- /DeviceRGB { [0 1 0 1 0 1] } def
- /DeviceCMYK { [0 1 0 1 0 1 0 1] } def
- /Indexed { dup /ColorSpace get 2 get [ exch 0 exch ] } def
- /Separation { [0 1] } def
- /CIEBasedA { [0 1] /RangeA //GetColorSpaceRange exec } def
- /CIEBasedABC { [0 1 0 1 0 1] /RangeABC //GetColorSpaceRange exec } def
-currentdict end readonly def
-
-/Substitute % <key> <dict> Substitute <key>
-{ 1 index //knownget exec {
- exch pop
- } if
-} bind def
-
-/DebugImagePrinting % <image_dict> DebugImagePrinting <image_dict>
-{
- //PDFR_DEBUG {
- (Image :) =
- dup { exch //=only exec ( ) print ==
- } forall
- } if
-} bind def
-
-/CompleteImage % <dict> CompleteImage <image_dict>
-{
- dup /ColorSpace known {
- dup /ColorSpace //CheckColorSpace //ResolveD exec pop
- } if
- dup /Decode known not {
- dup /ColorSpace //knownget exec {
- dup type /arraytype eq {
- 0 get
- } if
- //DecodeArrays exch get exec
- } {
- [0 1]
- } ifelse
- 1 index exch /Decode exch put
- } if
- dup /ImageMatrix [2 index /Width get 0 0 5 index /Height get neg
- 0 7 index /Height get] put % Not sure why upside down ?
- //DebugImagePrinting exec
-} bind def
-
-/CompleteInlineImage % <dict> CompleteInlineImage <image_dict>
-{
- //PDFR_DEBUG {
- (CompleteInlineImage beg) =
- } if
- dup /ImageType known not {
- dup /ImageType 1 put
- } if
- dup length dict exch { % d key val
- exch //ImageKeys //Substitute exec
- dup /Filter eq {
- exch //ImageValues //Substitute exec exch
- } if
- dup /ColorSpace eq {
- exch
- dup //ImageValues exch //knownget exec {
- exch pop
- } {
- //ResolveColorSpace exec
- } ifelse
- exch
- } if
- exch
- 2 index 3 1 roll put
- } forall
- //CompleteImage exec
- dup /DataSource 2 copy get % d d /n f
- 2 index //AppendFilters exec put
- //PDFR_DEBUG {
- (CompleteInlineImage end) =
- } if
-} bind def
-
-/CompleteOutlineImage % <dict> CompleteOutlineImage <image_dict>
-{
- currentglobal exch dup gcheck setglobal
- //PDFR_DEBUG {
- (CompleteOutlineImage beg) =
- } if
- % todo: ResetStreamReader if DataSource already exists.
- dup dup //MakeStreamReader exec /DataSource exch put
- dup /ImageType known not {
- //CompleteImage exec
- dup /ImageType 1 put
- dup /ColorSpace known {
- dup /ColorSpace //CheckColorSpace //ResolveD exec
- dup type /arraytype eq {
- //ResolveColorSpaceArray exec
- //SubstitutePDFColorSpace exec
- 1 index exch /ColorSpace exch put
- } {
- pop
- } ifelse
- } if
- } if
- //PDFR_DEBUG {
- (CompleteOutlineImage end) =
- } if
- exch setglobal
-} bind def
-
-/DoImage % <image_dict> DoImage -
-{
- //PDFR_DEBUG {
- (DoImage beg) =
- } if
- gsave
- dup /ColorSpace //knownget exec { setcolorspace } if
- dup /ImageMask //knownget exec not { false } if
- { imagemask } { image } ifelse
- grestore
- //PDFR_DEBUG {
- (DoImage end) =
- } if
-} bind def
-
-% ===================== Viewer State ===============
-
-/GSave % - GSave -
-{
- gsave
- //PDFReader /GraphicStateStackPointer get
- dup //GraphicStateStack exch get null eq {
- currentglobal true setglobal exch
- dup //GraphicStateStack exch //InitialGraphicState length dict put
- exch setglobal
- } if
- dup //GraphicStateStack exch get
- //GraphicState exch copy pop
- 1 add //PDFReader exch /GraphicStateStackPointer exch put
-} bind def
-
-/GRestore % - GRestore -
-{
- grestore
- //PDFReader /GraphicStateStackPointer get
- 1 sub dup
- //PDFReader exch /GraphicStateStackPointer exch put
- //GraphicStateStack exch get
- //GraphicState copy pop
-} bind def
-
-
-% ===================== Interpret Data Streams ===============
-
-/SetFont % <resource_name> <size> SetFont -
-{ dup //GraphicState exch /FontSize exch put
- //ResolveAndSetFont exec
- //GraphicState /FontMatrixNonHV currentfont /FontMatrix get 1 get 0 ne put
-} bind def
-
-/ShowText % <string> ShowText -
-{ //GraphicState /TextRenderingMode get 0 eq {
- //GraphicState /WordSpacing get 0
- 32
- //GraphicState /CharacterSpacing get 0
- 6 5 roll
- //GraphicState /FontMatrixNonHV get {
- % Use xshow to force wy in text space to be 0 (PDF1.7 5.3.3 "Text Space Details")
- %stack: wordspacing_wx wordspacing_wy space_char charspacing_wx charspacing_wy string
- [ % wwx wwy sp cwx cwy str [
- 7 -2 roll pop % sp cwx cwy str [ ww
- 5 -2 roll pop % sp str [ ww cw
- 5 -1 roll % str [ ww cw sp
- { % str [ ... ww cw sp c wx wy
- exch % will be removed, unless FontMatrix.xx == 0 (FontMatrixNonHV already true)
- pop % str [ ... ww cw sp c w
- 3 index add % str [ ... ww cw sp c w+cw
- exch 2 index eq { 3 index add } if % str [ ... ww cw sp w+cw[+ww]
- 4 1 roll % str [ ... w+cw[+ww] ww cw sp
- }
- currentfont /FontMatrix get 0 get 0 ne {
- 1 1 index length 1 sub getinterval cvx % drop the "exch"
- } if
- 5 index % str [ ww cw sp {cshowproc} str
- cshow % str [ widths... ww cw sp
- pop pop pop ] % str [widths...]
- xshow
- } {
- awidthshow
- } ifelse
- } {
- //GraphicState /CharacterSpacing get 0 eq
- //GraphicState /FontMatrixNonHV get not and
- //GraphicState /WordSpacing get 0 eq and {
- true charpath
- } {
- % Emulate with "{ charpath } cshow".
- % Not sure how it works with CID fonts.
- { % c wx wy
- exch % will be removed, unless FontMatrixNonHV && FontMatrix.xx == 0
- pop 0 % (PDF1.7 5.3.3 "Text Space Details")
- currentpoint 5 4 roll % wx wy x y c
- ( ) dup 0 3 index put true charpath % wx wy x y c
- 5 1 roll % c wx wy x y
- moveto rmoveto % c
- //GraphicState /CharacterSpacing get 0 rmoveto % c
- 32 eq { %
- //GraphicState /WordSpacing get 0 rmoveto
- } if
- }
- //GraphicState /FontMatrixNonHV get dup not exch {
- pop currentfont /FontMatrix get 0 get 0 ne
- } if {
- 1 1 index length 1 sub getinterval cvx
- } if
- exch cshow
- } ifelse
- } ifelse
-} bind def
-
-/ShowTextBeg % - ShowTextBeg -
-{ //GraphicState /TextRenderingMode get 0 ne {
- currentpoint newpath moveto
- } if
-} bind def
-
-/ShowTextEnd % - ShowTextEnd -
-{ //GraphicState /TextRenderingMode get
- { dup 1 eq {
- stroke exit
- } if
- dup 2 eq {
- gsave fill grestore stroke exit
- } if
- dup 3 eq {
- currentpoint newpath moveto
- } if
- dup 4 eq {
- gsave fill grestore clip exit
- } if
- dup 5 eq {
- gsave stroke grestore clip exit
- } if
- dup 6 eq {
- gsave fill grestore gsave stroke grestore fill exit
- } if
- dup 7 eq {
- clip exit
- } if
- exit
- } loop
- pop
-} bind def
-
-/ShowTextWithGlyphPositioning % <array> ShowTextWithGlyphPositioning -
-{ //ShowTextBeg exec
- { dup type /stringtype eq {
- //ShowText exec
- } {
- neg 1000 div //GraphicState /FontSize get mul 0 rmoveto
- } ifelse
- } forall
- //ShowTextEnd exec
-} bind def
-
-/CheckFont % key val CheckFont key val
-{ dup /Type get /ExtGState ne {
- mark (Resource ) 3 index ( must have /Type/ExtGState.) //error exec
- } if
-} bind def
-
-/SetTransfer % <operand> SetTransfer -
-{
- //PDFR_DEBUG { (SetTransfer beg ) print count = } if
- dup type /arraytype eq 1 index xcheck not and {
- 0 4 getinterval aload pop
- setcolortransfer
- } {
- settransfer
- } ifelse
- //PDFR_DEBUG { (SetTransfer end ) print count = } if
-} bind def
-
-/CheckExtGState % <id> <obj> CheckExtGState <id> <obj>
-{ dup /Type get /ExtGState ne {
- mark (Resource ) 3 index ( must have /Type/ExtGState.) //error exec
- } if
-} bind def
-
-/CheckHalftone % <id> <obj> CheckHalftone <id> <obj>
-{ dup /HalftoneType known not {
- mark (Resource ) 3 index ( must have /HalftoneType.) //error exec
- } if
-} bind def
-
-/ResolveFunction % <dict> <name> ResolveFunction <dict> <proc>
-{
- //PDFR_DEBUG { (ResolveFunction beg ) print dup = count = } if
- 2 copy get //IsObjRef exec {
- 2 copy //DoNothing //ResolveD exec
- 3 copy put pop
- } if
- 2 copy get dup type /arraytype eq exch xcheck and not {
- 2 copy get
- dup type /arraytype eq 1 index xcheck not and {
- dup length 1 sub -1 0 {
- 2 copy //DoNothing ResolveA
- dup /Identity eq {
- pop 2 copy {} put
- } {
- //FunctionToProc exec
- 3 copy put pop
- } ifelse
- pop
- } for
- } {
- dup /Default eq {
- % Leave it. ExtGState methods will resolve.
- } {
- dup /Identity eq {
- pop {}
- } { dup type /nametype eq {
- //spotfunctions exch get
- } {
- //FunctionToProc exec
- } ifelse
- } ifelse
- } ifelse
- } ifelse
- 3 copy put
- exch pop
- } {
- 1 index exch get
- } ifelse
- //PDFR_DEBUG { (ResolveFunction end ) print dup == count = } if
-} bind def
-
-/ResolveFunctionSafe % <dict> <name> ResolveFunctionSafe <dict>
-{ 2 copy known {
- //ResolveFunction exec
- } if
- pop
-} bind def
-
-/CreateHalftoneThresholds % <halftone_dict> CreateHalftoneThresholds <halftone_dict>
-{
- dup /Thresholds known not {
- dup /HalftoneType get 10 eq {
- dup dup //MakeStreamReader exec
- /Thresholds exch put
- } if
- dup /HalftoneType get dup 3 eq exch 6 eq or {
- dup dup //MakeStreamReader exec
- //BlockBuffer readstring pop
- dup length
- dup 0 eq {
- mark (Could not read Thresholds) //error exec
- } if
- string copy /Thresholds exch put
- dup /HalftoneType 3 put % replace Type 6 with Type 3.
- } if
- } if
-} bind def
-
-
-/SetExtGState % <name> SetExtGState -
-{
- //PDFReader /CurrentObject get /Context get /Resources get
- /ExtGState //DoNothing //ResolveD exec
- exch //CheckExtGState //ResolveD exec % s gs
- dup /LW //knownget exec {
- setlinewidth
- } if
- dup /LC //knownget exec {
- setlinecap
- } if
- dup /LJ //knownget exec {
- setlinejoin
- } if
- dup /ML //knownget exec {
- setmeterlimit
- } if
- dup /D //knownget exec {
- setdash
- } if
- dup /RI //knownget exec {
- % Ghostscript never writes it.
- mark (Unimplemented ExtGState.RI) //error exec
- } if
- dup /OP //knownget exec {
- % pdfwrite must take care of stroking/filling
- setoverprint
- } if
- dup /op //knownget exec {
- setoverprint
- } if
- dup /OPM //knownget exec {
- % pdfwrite must take care of.
- mark (Unimplemented ExtGState.OPM) //error exec
- } if
- dup /Font //knownget exec {
- % Ghostscript never writes it.
- mark (Unimplemented ExtGState.Font) //error exec
- } if
- dup /BG known {
- /BG //ResolveFunction exec
- setblackgeneration
- } if
- dup /BG2 known {
- /BG2 //ResolveFunction exec
- dup /Default eq {
- //InitialExtGState /BG2 get
- } if
- setblackgeneration
- } if
- dup /UCR known {
- /UCR //ResolveFunction exec
- setundercolorremoval
- } if
- dup /UCR2 known {
- /UCR2 //ResolveFunction exec
- dup /Default eq {
- //InitialExtGState /UCR2 get
- } if
- setundercolorremoval
- } if
- dup /TR known {
- /TR //ResolveFunction exec
- //SetTransfer exec
- } if
- dup /TR2 known {
- /TR2 //ResolveFunction exec
- dup /Default eq {
- pop //InitialExtGState /TR2 get
- aload pop setcolortransfer
- } {
- //SetTransfer exec
- } ifelse
- } if
- dup /HT //knownget exec {
- dup /Default eq {
- pop //InitialExtGState /HT get
- sethalftone
- } {
- //PDFR_DEBUG { (Ht beg) = } if
- pop dup /HT //CheckHalftone //ResolveD exec
- /SpotFunction //ResolveFunctionSafe exec
- /TransferFunction //ResolveFunctionSafe exec
- null exch
- dup /HalftoneType get dup 5 eq exch dup 4 eq exch 2 eq or or {
- dup { % null h n v
- dup //IsObjRef exec {
- pop
- 1 index exch //CheckHalftone ResolveD
- } if
- dup type /dicttype eq {
- dup /SpotFunction //ResolveFunctionSafe exec
- /TransferFunction //ResolveFunctionSafe exec
- //CreateHalftoneThresholds exec
- dup /HalftoneType get 5 gt { % null h n v
- 4 3 roll pop
- dup 4 1 roll
- } if
- } if
- pop pop
- } forall
- } if
- //CreateHalftoneThresholds exec
- //PDFR_DEBUG {
- (HT:)=
- dup {
- 1 index /Default eq {
- (Default <<)=
- exch pop
- { exch = == } forall
- (>>)=
- } {
- exch = ==
- } ifelse
- } forall
- (HT end)= flush
- } if
- exch dup null ne {
- (Warning: Ignoring a halftone with a Level 3 component halftone Type ) print dup /HalftoneType get =
- pop pop
- } {
- pop
- dup /HalftoneType get 5 gt {
- (Warning: Ignoring a Level 3 halftone Type ) print dup /HalftoneType get =
- pop
- } {
- sethalftone
- } ifelse
- } ifelse
- //PDFR_DEBUG { (HT set)= flush } if
- } ifelse
- } if
- dup /FL //knownget exec {
- setflattness
- } if
- dup /SM //knownget exec {
- setsmoothness
- } if
- dup /SA //knownget exec {
- setstrokeadjust
- } if
- dup /BM //knownget exec {
- % pdfwrite must take care of.
- mark (Unimplemented ExtGState.BM) //error exec
- } if
- dup /SMask //knownget exec {
- % pdfwrite must take care of.
- mark (Unimplemented ExtGState.SMask) //error exec
- } if
- dup /CA //knownget exec {
- % pdfwrite must take care of.
- mark (Unimplemented ExtGState.CA) //error exec
- } if
- dup /ca //knownget exec {
- % pdfwrite must take care of.
- mark (Unimplemented ExtGState.ca) //error exec
- } if
- dup /AIS //knownget exec {
- % pdfwrite must take care of.
- mark (Unimplemented ExtGState.AIS) //error exec
- } if
- dup /TK //knownget exec {
- % pdfwrite must take care of.
- mark (Unimplemented ExtGState.TK) //error exec
- } if
- pop
-} bind def
-
-/CheckXObject % <id> <obj> CheckHalftone <id> <obj>
-{ dup /Subtype get dup /Image ne exch dup /Form ne exch /PS ne and and {
- mark (Resource ) 3 index ( must have /Subtype /Image or /Form or /PS.) //error exec
- } if
-} bind def
-
-/DoXObject % <name> DoXObject -
-{
- //PDFReader /CurrentObject get /Context get /Resources get
- /XObject //DoNothing //ResolveD exec
- exch //CheckXObject //ResolveD exec
- dup /Subtype get
- dup /Image eq {
- pop
- //CompleteOutlineImage exec
- //DoImage exec
- } {
- dup /PS eq {
- PDFR_DEBUG {
- (Executing a PS Xobject) =
- } if
- pop
- //RunDelayedStream exec
- } {
- dup /Form eq {
- pop
- PDFR_DEBUG {
- (Executing a Form XObject) =
- } if
- //PDFReader /CurrentObject get exch
- dup //PDFReader exch << exch /Context exch >> /CurrentObject exch put
- dup /Matrix get concat
- dup /BBox get aload pop exch 3 index sub exch 2 index sub rectclip
- //RunDelayedStream exec
- //PDFReader exch /CurrentObject exch put
- } {
- mark exch (unimplemented XObject type ) exch //error exec
- } ifelse
- } ifelse
- } ifelse
-} bind def
-
-/Operators 50 dict begin
- /q { //GSave exec } bind def
- /Q { //GRestore exec } bind def
- /cm { //TempMatrix astore concat } bind def
- /i { 1 .min setflat } bind def
- /J /setlinecap load def
- /d /setdash load def
- /j /setlinejoin load def
- /w /setlinewidth load def
- /M /setmiterlimit load def
- /gs { SetExtGState } bind def
-
- /g /setgray load def
- /rg /setrgbcolor load def
- /k /setcmykcolor load def
- /cs { //ResolveColorSpace exec //SetColorSpaceSafe exec
- } bind def
- /sc /setcolor load def
- /scn { //SetColor exec } bind def
- /G /setgray load def
- /RG /setrgbcolor load def
- /K /setcmykcolor load def
- /CS //cs def
- /ri { SetColorRenderingIntent } bind def
- /SC /setcolor load def
- /SCN { //SetColor exec } bind def
-
- /m /moveto load def
- /l /lineto load def
- /c /curveto load def
- /v { currentpoint 6 2 roll curveto } bind def
- /y { 2 copy curveto } bind def
- /re {
- 4 2 roll moveto exch dup 0 rlineto 0 3 -1 roll rlineto neg 0 rlineto
- closepath
- } def
- /h /closepath load def
- /n /newpath load def
- /S /stroke load def
- /s { closepath stroke } bind def
- /f /fill load def
- /f* /eofill load def
- /B { gsave fill grestore stroke } bind def
- /b { closepath gsave fill grestore stroke } bind def
- /B* { gsave eofill grestore stroke } bind def
- /b* { closepath gsave eofill grestore stroke } bind def
- /W /clip load def
- /W* /eoclip load def
- /sh { % Reserved for ps3write.
- ResolveShading
- dup /Background known {
- gsave
- dup /ColorSpace get setcolorspace
- dup /Background get aload pop setcolor
- pathbbox % x0 y0 x1 y1
- 2 index sub exch 3 index sub exch
- rectfill
- grestore
- } if
- shfill
- } bind def
-
- /Do { //DoXObject exec } bind def
-
- /BI { currentglobal false setglobal << } bind def
- /ID { >>
- dup /DataSource currentfile
- % HACK BEG
- % This hack provides a compatibility to HP LaserJet 1320,
- % which sometimes closes the underlying stream when EOD
- % is reached in the ASCII85Decode filter.
- % This portion is not required by the Postscript language definition.
- 2 index /F //knownget exec {
- /A85 eq {
- 0 (~>) /SubFileDecode filter
- } if
- } if
- % HACK END
- put
- //CompleteInlineImage exec
- exch setglobal
- //DoImage exec
- } bind def
- /EI {} bind def
-
- /BT { gsave //GraphicState /InitialTextMatrix get currentmatrix pop } bind def
- /ET { grestore } bind def
- /Tc { //GraphicState exch /CharacterSpacing exch put } bind def
- /TL { //GraphicState exch /TextLeading exch put } bind def
- /Tr { //GraphicState exch /TextRenderingMode exch put } bind def
- /Ts { % Ghostscript never generates it.
- mark (Unimplemented SetTextRise) //error exec
- } bind def
- /Tw { //GraphicState exch /WordSpacing exch put } bind def
- /Tz { % Ghostscript never generates it.
- mark (Unimplemented SetHorizontalTextScaling) //error exec
- } bind def
- /Td { translate 0 0 moveto } bind def
- /TD { dup neg //TL exec //Td exec } bind def
- /Tm { //GraphicState /InitialTextMatrix get setmatrix
- //TempMatrix astore concat
- 0 0 moveto } bind def
- /T* { 0 //GraphicState /TextLeading get neg //Td exec } bind def
- /Tj { //ShowTextBeg exec //ShowText exec //ShowTextEnd exec } bind def
- /' { //T* exec //ShowText exec //ShowTextEnd exec } bind def
- /" { 3 2 roll //Tw exec exch //Tc exec //' exec} bind def
- /TJ //ShowTextWithGlyphPositioning def
- /Tf //SetFont def
-
- /d0 /setcharwidth load def
- /d1 /setcachedevice load def
-
- /BDC { BeginMarkedContentSequenceWithPropertyList } bind def
- /BMC { BeginMarkedContentSequence } bind def
- /EMC { EndMarkedContentSequence } bind def
- /BX { BeginCompatibilitySection } bind def
- /EX { EndCompatibilitySection } bind def
- /DP { DefineMarkedContentPointWithPropertyList } bind def
- /MP { DefineMarkedContentPoint } bind def
- /PS { cvx exec } bind def
-currentdict end def
-
-//PDFR_STREAM {
- % Rebind operators with a debug tracing.
- //Operators length dict begin
- //Operators { % n p
- exch dup % p n n
- [ exch //=only /exec load % p n [ n =only exec
- ( ) /print load % p n [ n =only exec () print
- 8 7 roll % n [ n =only exec () print p
- dup type /arraytype eq {
- /exec load % n [ n =only exec () print p exec
- } if
- ( ) /print load
- ] cvx % n {}
- def
- } forall
- currentdict end /Operators exch def
-} if
-
-% Functions for handling Ghostscript library files that define encodings.
-
-/.registerencoding
-{ pop pop
-} bind def
-
-/.defineencoding
-{ def
-} bind def
-
-/.findencoding
-{ load
-} bind def
-
-
-% Leaving the procset on the dictionary stack to provide
-% definitions of obj, endobj, stream, endstream, R, xref.
-%%EndPrologue
-
diff --git a/Master/tlpkg/tlgs/lib/packfile.ps b/Master/tlpkg/tlgs/lib/packfile.ps deleted file mode 100644 index 549ca5b7294..00000000000 --- a/Master/tlpkg/tlgs/lib/packfile.ps +++ /dev/null @@ -1,333 +0,0 @@ -% Copyright (C) 1994, 1995, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: packfile.ps 6300 2005-12-28 19:56:24Z giles $
-% packfile.ps
-% Pack groups of files together, with compression, for use in
-% storage-scarce environments.
-
-% ****** NOTE: This file must be kept consistent with gs_pfile.ps.
-
-% ---------------- Huffman coding utilities ---------------- %
-
-% We count runs of zeros, and individual byte frequencies separately
-% depending on whether they follow or do not follow a run of zeros.
-/zruns 256 array def
-/zfreq 256 array def
-/nzfreq 256 array def
-/maxcode 13 def % max code length, must be between 10 and 16
-/maxzrun 100 def % max length of zero run, must be <= 100
-/statbuf 10000 string def
-
-% Initialize statistics.
-/initstats % - initstats -
- { 0 1 255 { zruns exch 0 put } for
- 0 1 255 { zfreq exch 0 put } for
- 0 1 255 { nzfreq exch 0 put } for
- } bind def
-
-% Accumulate statistics from an individual file.
-/addstats % <file> addstats -
- { 0
- { 1 index //statbuf readstring 3 1 roll
- % Stack: file eof numzeros data
- { dup 0 eq
- { pop 1 add
- }
- { 1 index 0 ne
- { exch 255 .min
- //zruns exch 2 copy get 1 add put
- 0 exch //zfreq
- }
- { //nzfreq
- }
- ifelse
- exch 2 copy get 1 add put
- }
- ifelse
- } forall
- exch not { exit } if (.) print flush
- } loop
- pop closefile
- } bind def
-
-% Compute the Huffman codes from the statistics.
-/statcodes % - statcodes <array>
- { maxcode 1 add 256 add maxzrun 2 sub add 1 add array % full array
- dup maxcode 1 add dup 2 index length exch sub getinterval % data
- % Put statistics into array
- dup 0 1 255
- { zfreq 1 index get nzfreq 2 index get add put dup
- } for
- 0 zruns 1 get put
- 256 zruns 2 maxzrun 2 sub getinterval putinterval
- dup dup length 1 sub 1 put % EOD
- maxcode .computecodes
- } bind def
-
-% ---------------- File handling ---------------- %
-
-% Copy one file to another.
-% Close the input file, but not the output file.
-/copyfile % <infile> <outfile> copyfile <outfile> <length>
- { 0 mark statbuf
- { 4 index 1 index readstring
- exch 5 index 1 index writestring
- length 5 -1 roll add 4 1 roll
- not { exit } if (.) print flush
- } loop
- cleartomark 3 -1 roll closefile dup == flush
- } bind def
-
-% Represent a Type 1 font in its most compressed format.
-% Requires -dWRITESYSTEMDICT to run.
-% Does not close the output file.
-(wrfont.ps) runlibfile
-/compressfont % <fontname> <outfile> compressfont <outfile>
- { exch save
- systemdict /executeonly /readonly load put
- systemdict /noaccess /readonly load put
- systemdict readonly pop
- wrfont_dict begin
- /binary_CharStrings true def
- /binary_tokens true def
- /encrypt_CharStrings false def
- /standard_only false def
- /use_lenIV 0 def
- /smallest_output true def
- end
- exch findfont setfont
- 1 index writefont
- restore
- } bind def
-
-% ---------------- Main program ---------------- %
-
-% Find the length of a file.
-/filelength % <filename> filelength <length>
- { status { pop pop exch pop } { -1 } ifelse
- } bind def
-
-% Define the header string for a compressed file.
-/beginfilestring
-({dup token pop exch[/MaxCodeLength 2 index token pop/Tables 4 index token pop
-/EndOfData true/EncodeZeroRuns 256 .dicttomark
-/BoundedHuffmanDecode filter/MoveToFrontDecode filter
-[/BlockSize 4 -1 roll .dicttomark/BWBlockSortDecode filter
-}) readonly def
-
-% Write a 16-bit big-endian non-negative integer on a file.
-/write16 % <file> <int> write16 -
- { 2 copy -8 bitshift write 255 and write
- } bind def
-
-% Compress a group of files together.
-% Return a dictionary in which the keys are the input file names
-% and the values are [startpos length] in the uncompressed concatenation.
-% Does not open or close the output file.
-/tempname (t.em) def
-/packfiles % <filenames> <outfile> packfiles <outfile> <posdict>
- { % Concatenate files to a temporary file.
- tempname (w) file
- dup /MoveToFrontEncode filter
- dup <<
- /BlockSize 1000000
- >> /BWBlockSortEncode filter
- % Stack: filenames outfile tempfile mtfe bwe
- 5 -1 roll dup length dict 0 6 2 roll
- { % Stack: outfile posdict pos tempfile mtfe bwe infilename
- dup ==only dup (r) file 2 index copyfile exch pop
- dup 7 index 4 2 roll 7 index exch 2 array astore put
- 5 -1 roll add 4 1 roll
- } forall
- closefile closefile closefile pop exch
- % Stack: posdict outfile
- % Compute an optimal Huffman code.
- initstats
- tempname (r) file addstats
- % Actually compress the file.
- % Write the decompression information on the output first.
- dup tempname filelength write==
- dup maxcode write==
- % Write the code table as a homogenous number array.
- statcodes exch
- dup 149 write dup 32 write dup 2 index length write16
- exch { 2 copy write16 pop } forall
- dup <<
- /MaxCodeLength maxcode
- /EndOfData true
- /EncodeZeroRuns 256
- /Tables statcodes
- >> /BoundedHuffmanEncode filter
- tempname (r) file exch copyfile pop closefile
- exch
- } bind def
-
-% Squeeze a font to a .cpf file in anticipation of compression.
-/squeezefont % <fontname> squeezefont <filename.cpf>
- { dup type /nametype ne { cvn } if
- dup
- { dup type /stringtype eq { exit } if
- Fontmap exch get
- }
- loop
- % Stack: fontname filename
- dup dup
- { (.) search not { exit } if
- exch pop exch 3 -1 roll pop
- }
- loop
- % Stack: fontname filename noextname extension
- exch
- { (/) search not { (\\) search not { exit } if } if
- pop pop
- }
- loop
- % If the font extension is anything other than
- % .pfa or .pfb, we assume it can't be rewritten
- % using compressfont.
- % Stack: fontname filename extension basename
- (.cpf) concatstrings dup 5 1 roll (w) file
- % Stack: outfilename fontname filename extension outfile
- exch dup (pfa) eq exch (pfb) eq or
- % Stack: outfilename fontname filename outfile bool
- { exch pop compressfont
- }
- { 3 -1 roll pop
- exch findlibfile pop exch pop
- exch copyfile pop
- }
- ifelse closefile
- } bind def
-
-% ---------------- Production code ---------------- %
-
-% The following code constructs a packed version of the commercial-quality
-% fonts available from Aladdin Enterprises. To use this code:
-% - If desired, change the output file names below.
-% - Make sure you have the synthetic font data (fontmap.shs and the
-% *.ps files for the commercial fonts) in a directory that is on
-% Ghostscript's search path.
-% - Construct the packed fonts by running
-% gs -dNODISPLAY -dWRITESYSTEMDICT packfile.ps
-% - If desired, move the output files to the directory that will be
-% used at run time. You no longer need the *.pfb or *.ps files
-% for the original fonts; however, you do still need the Fontmap
-% for these fonts, because it defines the font name aliases.
-% - Add the following line to the end of gs_fonts.ps:
-% (ALL.cmp) run
-% (substituting the definition of allmapname if you changed it).
-
-% Define the output file names. The extensions are arbitrary;
-% any legal file name is allowed.
-/allname (ALL.cff) def % the compressed font file
-/allmapname (ALL.cmp) def % the Fontmap override file
-
-% Load an alternate Fontmap that references the synthetic oblique and
-% narrow fonts.
-true .setglobal
-(fontmap.shs) findlibfile pop exch pop .loadFontmap
-false .setglobal
-
-% Define the packaging of fonts into font groups.
-% Fewer larger groups compress better, but make decompression slower.
-/Lists [
-[ % The oblique and narrow fonts are synthetic,
- % and take very little space.
- /AvantGarde-BookOblique /AvantGarde-DemiOblique
- /Courier-Oblique /Courier-BoldOblique
- /Helvetica-Oblique /Helvetica-BoldOblique
- /Helvetica-Narrow /Helvetica-Narrow-Oblique
- /Helvetica-Narrow-Bold /Helvetica-Narrow-BoldOblique
-]
-[/AvantGarde-Book /AvantGarde-Demi
- /Bookman-Light] [/Bookman-LightItalic
- /Bookman-Demi /Bookman-DemiItalic
- /Courier] [/Courier-Bold
- /Helvetica /Helvetica-Bold]
-[/NewCenturySchlbk-Roman /NewCenturySchlbk-Italic
- /NewCenturySchlbk-Bold /NewCenturySchlbk-BoldItalic]
-[/Palatino-Roman /Palatino-Italic
- /Palatino-Bold /Palatino-BoldItalic]
-[/Times-Roman /Times-Italic
- /Times-Bold /Times-BoldItalic]
-[/Symbol
- /ZapfChancery-MediumItalic
- /ZapfDingbats]
-] def
-
-% We need to register the fonts under their true names, not aliases.
-/Lists Lists mark exch
- { mark exch
- { { Fontmap 1 index get dup type /nametype ne { pop exit } if
- exch pop
- }
- loop
- }
- forall ]
- }
-forall ] def
-
-% Squeeze the fonts to their .cpf format.
-(Squeezing... ) print flush
-/fdict mark
-Lists
- { { dup squeezefont } forall } forall
-.dicttomark def
-(done.\n) print flush
-
-% Invert fdict.
-/f2dict fdict length dict def
-fdict { exch f2dict 3 1 roll put } forall
-
-% Construct the compressed font file.
-(Creating ) print allname print (... ) print flush
-/posdict fdict length dict def
-/all allname (w) file def
-all beginfilestring writestring
-Lists
- { dup == flush
- /fbegin all fileposition def
- mark exch { fdict exch get } forall ]
- all packfiles exch pop
- /flength all fileposition fbegin sub def
- { fbegin flength 3 -1 roll aload pop 4 packedarray
- exch f2dict exch get exch posdict 3 1 roll put
- }
- forall
- }
-forall
-all closefile
-(done.\n) print flush
-
-% Write the Fontmap addendum for accessing compressed fonts.
-(Writing ) print allmapname print (... ) print flush
-allmapname (w) file
-dup (%!
-/.runpackedlibfile where{pop}{(gs_pfile.ps)runlibfile}ifelse
-.currentglobal true .setglobal
-) writestring
-posdict
- { exch 2 index exch write==only exch dup ({) writestring
- dup allname write==only
- exch { 1 index dup ( ) writestring exch write==only } forall
- dup ( .runpackedlibfile}bind .definefontmap
-) writestring
- }
-forall
-dup (.setglobal
-) writestring
-closefile
-(done.\n) print flush
diff --git a/Master/tlpkg/tlgs/lib/pcharstr.ps b/Master/tlpkg/tlgs/lib/pcharstr.ps deleted file mode 100644 index e85e23748c7..00000000000 --- a/Master/tlpkg/tlgs/lib/pcharstr.ps +++ /dev/null @@ -1,126 +0,0 @@ -% Copyright (C) 1990, 1992, 1997, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pcharstr.ps 6300 2005-12-28 19:56:24Z giles $
-% pcharstr.ps
-% Print the CharStrings and Subrs (if present) from a Type 1 font,
-% in either a PostScript-like or a C-compatible form,
-% depending on whether CSFormat is defined as /PS or /C.
-
-% Load the Type 1 utilities.
-(type1ops.ps) runlibfile
-
-% Define the printing procedures for PostScript-like output.
-/pcs_ps_dict mark
- /, {( ) print}
- /charname {==only}
- /csbegin {}
- /beginchars {(%---------------- CharStrings\n) print}
- /charbegin {==only}
- /char1 {( ) print ==only}
- /endchars {}
- /beginsubrs {(%---------------- Subrs\n) print}
- /subrbegin {=only}
- /endsubrs {}
- /beginboxes {(%---------------- Encoding & metrics\n) print}
- /notdefbox {}
- /boxbegin {=only ( ) print}
- /boxend {(\n) print}
- /endboxes {(%----------------\n) print}
-.dicttomark readonly def
-
-% Define the printing procedures for C-like output.
-/pcs_c_dict mark
- /, {(, ) print}
- /charname {(") print =only (") print}
- /csbegin {counttomark =only ,}
- /beginchars {(\nconstdata int CSCharData[] = {\n) print}
- /charbegin {pop}
- /char1 {=only ,}
- /endchars {
- (-1\n};\nconstdata char *CSCharNames[] = {\n) print
- CharStrings {pop charname ,} forall (0\n};\n) print
- }
- /beginsubrs {(\nconstdata int CSSubrs[] = {\n) print}
- /subrbegin {pop}
- /endsubrs {(-1\n};\n) print}
- /beginboxes {(\nconstdata type1_box CSboxes[] = {\n) print}
- /notdefbox {( {""},\n) print}
- /boxbegin {pop ( {) print}
- /boxend {(},) =}
- /endboxes {( {0}\n};\n) print}
-.dicttomark readonly def
-
-/printcs
- { dup type /stringtype eq
- { printcs1 (\n) print }
- { ( ) print == }
- ifelse
- } bind def
-/printcs1
- { save exch
- lenIV 0 ge {
- 4330 exch dup length string .type1decrypt exch pop
- dup length lenIV sub lenIV exch getinterval
- } if
- 0 () /SubFileDecode filter
- mark exch charstack_read csbegin
- counttomark 1 sub -1 0 { index char1 } for
- cleartomark restore
- } bind def
-
-/printfont
- { pcs_ps_dict
- /CSFormat where { pop CSFormat /C eq { pop pcs_c_dict } if } if
- begin
- currentfont begin Private begin 10 dict begin
-
- % Print the CharStrings and Subrs
-
- beginchars
- CharStrings { exch charbegin printcs } forall
- endchars
- /Subrs where
- { pop % the dictionary
- beginsubrs
- 0 1 Subrs length 1 sub
- { dup subrbegin
- Subrs exch get printcs
- } for
- endsubrs
- } if
-
- % Print the bounding boxes
-
- gsave nulldevice FontMatrix matrix invertmatrix concat
- beginboxes
- 0 1 Encoding length 1 sub
- { dup Encoding exch get dup /.notdef eq
- { pop pop notdefbox
- }
- { 1 index boxbegin charname ,
- ( ) dup 0 4 -1 roll put
- newpath 0 0 moveto false charpath
- pathbbox ({) print 4 -1 roll =only ,
- 3 -1 roll =only , exch =only , =only (}) print
- boxend
- }
- ifelse
- } for
- endboxes
- grestore
-
- end end end end
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/pdf2dsc.ps b/Master/tlpkg/tlgs/lib/pdf2dsc.ps deleted file mode 100644 index 97d47ba1c65..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf2dsc.ps +++ /dev/null @@ -1,254 +0,0 @@ -% Copyright (C) 1994, 1995, 1996, 1997, 1998 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdf2dsc.ps 8546 2008-02-25 05:48:45Z alexcher $
-% pdf2dsc.ps
-% read pdf file and produce DSC "index" file.
-%
-% Input file is named PDFname
-% Output file is named DSCname
-%
-% Run using:
-% gs -dNODISPLAY -sPDFname=pdffilename -sDSCname=tempfilename pdf2dsc.ps
-% Then display the PDF file with
-% gs tempfilename
-%
-% Modified by Jason McCarty, bug 688071
-% Add PageLabels support.
-% Modified by Geoff Keating <geoffk@ozemail.com.au> 21/12/98:
-% Add DocumentMedia, PageMedia comments
-% Use inherited BoundingBox and Orientation
-% Reformat, add new macro 'puts', generally clean up
-% Modified by Johannes Plass <plass@dipmza.physik.uni-mainz.de> 1996-11-05:
-% Adds BoundingBox and Orientation if available.
-% Modified by rjl/lpd 9/19/96
-% Updates for compatibility with modified pdf_*.ps code for handling
-% page ranges (i.e., partial files) better.
-% Modified by Geoff Keating <Geoff.Keating@anu.edu.au> 7/3/96:
-% include Title and CreationDate DSC comments (these are displayed by
-% Ghostview);
-% reduce the size of typical output files by a factor of about 3.
-% Modified by L. Peter Deutsch 3/18/96:
-% Removes unnecessary and error-prone code duplicated from pdf_main.ps
-% Modified by L. Peter Deutsch for GS 3.33
-% Originally by Russell Lang 1995-04-26
-
-/PDFfile PDFname (r) file def
-/DSCfile DSCname (w) file def
-systemdict /.setsafe known { .setsafe } if
-
-/puts { DSCfile exch writestring } bind def
-/DSCstring 255 string def
-/MediaTypes 10 dict def
-
- GS_PDF_ProcSet begin
- pdfdict begin
- PDFfile
- pdfopen begin
- /FirstPage where { pop } { /FirstPage 1 def } ifelse
- /LastPage where { pop } { /LastPage pdfpagecount def } ifelse
-
-% scan through for media sizes, keep them in the dictionary
- FirstPage 1 LastPage {
- pdfgetpage /MediaBox pget pop % MediaBox is a required attribute
- aload pop
- 3 -1 roll sub 3 1 roll exch sub exch
- 2 array astore
- aload 3 1 roll 10 string cvs exch 10 string cvs
- (x) 3 -1 roll concatstrings concatstrings cvn
- MediaTypes 3 1 roll exch put
- } for
-
-% write header and prolog
- (%!PS-Adobe-3.0\n) puts
- Trailer /Info knownoget
- {
- dup /Title knownoget
- {
- (%%Title: ) puts
- DSCfile exch write==
- }
- if
- /CreationDate knownoget
- {
- (%%CreationDate: ) puts
- DSCfile exch write==
- }
- if
- }
- if
- % This is really supposed to be sorted by frequency of usage...
- (%%DocumentMedia: )
- MediaTypes {
- exch pop
- 1 index puts
- (y) puts dup 1 get DSCstring cvs puts
- (x) puts dup 0 get DSCstring cvs puts
- ( ) puts dup 0 get DSCstring cvs puts
- ( ) puts 1 get DSCstring cvs puts
- ( 70 white ()\n) puts
- pop (%%+ )
- } forall
- pop
-
- (%%Pages: ) puts
- LastPage FirstPage sub 1 add DSCstring cvs puts
- (\n%%EndComments\n) puts
- (%%BeginProlog\n) puts
- (/Page null def\n/Page# 0 def\n/PDFSave null def\n) puts
- (/DSCPageCount 0 def\n) puts
- (/DoPDFPage {dup /Page# exch store pdfgetpage pdfshowpage } def\n) puts
- (GS_PDF_ProcSet begin\npdfdict begin\n) puts
- (%%EndProlog\n) puts
- (%%BeginSetup\n) puts
- DSCfile PDFname write==only
- ( \(r\) file { DELAYSAFER { .setsafe } if } stopped pop\n) puts
- ( pdfopen begin\n) puts
- ( copy_trailer_attrs\n) puts
- (%%EndSetup\n) puts
-
- /.hasPageLabels false def % see "Page Labels" in the PDF Reference
- Trailer /Root knownoget {
- /PageLabels knownoget {
- /PageLabels exch def
- /.pageCounter 1 def
- /.pageCounterType /D def
- /.pagePrefix () def
-
- % (TEXT) .ToLower (text) -- convert text to lowercase -- only letters!
- /.ToLower {
- dup length 1 sub -1 0 {
- 1 index exch 2 copy get 2#00100000 or put
- } for
- } def
-
- % int .CvAlpha (int in alphabetic base 26) -- convert a positive
- % integer to base 26 in capital letters, with 1=A; i.e. A..Z, AA..AZ, ...
- /.CvAlpha { % using cvrs seems futile since this isn't zero-based ...
- [ exch % construct an array of ASCII values, in reverse
- { % the remainder stays on the top of stack
- dup 0 eq { pop exit } if % quit if the value is zero
- dup 26 mod dup 0 eq { 26 add } if % so that the division is correct
- dup 64 add 3 1 roll sub 26 idiv % save the ASCII value and iterate
- } loop ]
- dup length dup string 3 1 roll
- dup -1 1 { % put the letters in a string
- 4 copy sub exch 4 -1 roll 1 sub get put
- } for pop pop
- } def
-
- % int .CvRoman (int in capital Roman numerals)
- % convert a positive integer to capital Roman numerals
- % return a decimal string if >= 4000
- /.CvRoman {
- dup DSCstring cvs % start with the decimal representation
- exch 4000 lt { % convert only if Roman numerals can represent this
- dup length
- [ [ () (I) (II) (III) (IV) (V) (VI) (VII) (VIII) (IX) ]
- [ () (X) (XX) (XXX) (XL) (L) (LX) (LXX) (LXXX) (XC) ]
- [ () (C) (CC) (CCC) (CD) (D) (DC) (DCC) (DCCC) (CM) ]
- [ () (M) (MM) (MMM) ] ] % Roman equivalents
- () % append the Roman equivalent of each decimal digit to this string
- 2 index -1 1 {
- 2 index 1 index 1 sub get
- 5 index 5 index 4 -1 roll sub get
- 48 sub get concatstrings
- } for
- 4 1 roll pop pop pop
- } if
- } def
-
- /PageToString <<
- /D { DSCstring cvs }
- /R { .CvRoman }
- /r { .CvRoman .ToLower }
- /A { .CvAlpha }
- /a { .CvAlpha .ToLower }
- >> def
- /.hasPageLabels true def
- } if
- } if
-
- % process each page
- FirstPage 1 LastPage {
- (%%Page: ) puts
-
- .hasPageLabels {
- dup 1 sub PageLabels exch numoget dup null ne {
- % page labels changed at this page, reset the values
- dup /S known { dup /S get } { null } ifelse
- /.pageCounterType exch def
-
- dup /P known { dup /P get } { () } ifelse
- /.pagePrefix exch def
-
- dup /St known { /St get } { pop 1 } ifelse
- /.pageCounter exch def
- } { pop } ifelse
-
- % output the page label
- (\() .pagePrefix
- .pageCounterType //null ne dup {
- PageToString .pageCounterType known and
- } if { % format the page number
- .pageCounter dup 0 gt { % don't try to format nonpositive numbers
- PageToString .pageCounterType get exec
- } {
- DSCstring cvs
- } ifelse
- } { () } ifelse
- (\)) concatstrings concatstrings concatstrings puts
-
- /.pageCounter .pageCounter 1 add def
- } {
- dup DSCstring cvs puts
- } ifelse
- ( ) puts
- dup DSCstring cvs puts
- (\n) puts
-
- dup pdfgetpage
- dup /MediaBox pget pop
- (%%PageMedia: y) puts
- aload pop 3 -1 roll sub DSCstring cvs puts
- (x) puts exch sub DSCstring cvs puts
- (\n) puts
- dup /CropBox pget {
- (%%PageBoundingBox: ) puts
- {DSCfile exch write=only ( ) puts} forall
- (\n) puts
- } if
- /Rotate pget {
- (%%PageOrientation: ) puts
- 90 div cvi 4 mod dup 0 lt {4 add} if
- [(Portrait) (Landscape) (UpsideDown) (Seascape)] exch get puts
- (\n) puts
- } if
-
- DSCfile exch DSCstring cvs writestring
- ( DoPDFPage\n) puts
- } for
- currentdict pdfclose
- end
- end
- end
-% write trailer
-(%%Trailer\n) puts
-(currentdict pdfclose\nend\nend\nend\n) puts
-(%%EOF\n) puts
-% close output file and exit
-DSCfile closefile
-quit
-% end of pdf2dsc.ps
diff --git a/Master/tlpkg/tlgs/lib/pdf_base.ps b/Master/tlpkg/tlgs/lib/pdf_base.ps deleted file mode 100644 index b65f0bf1fcb..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf_base.ps +++ /dev/null @@ -1,1052 +0,0 @@ -% Copyright (C) 1994-2006 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdf_base.ps 8358 2007-11-10 17:20:49Z alexcher $
-% pdf_base.ps
-% Basic parser for PDF reader.
-
-% This handles basic parsing of the file (including the trailer
-% and cross-reference table), as well as objects, object references,
-% streams, and name/number trees; it doesn't include any facilities for
-% making marks on the page.
-
-/.setlanguagelevel where { pop 2 .setlanguagelevel } if
-.currentglobal true .setglobal
-/pdfdict where { pop } { /pdfdict 100 dict def } ifelse
-pdfdict begin
-
-% Define the name interpretation dictionary for reading values.
-/valueopdict mark
- (<<) cvn { mark } bind % don't push an actual mark!
- (>>) cvn { { .dicttomark } stopped {
- ( **** File has an unbalanced >> \(close dictionary\).\n)
- pdfformaterror
- } if
- } bind
- ([) cvn { mark } bind % ditto
- (]) cvn dup load
-% /true true % see .pdfexectoken below
-% /false false % ibid.
-% /null null % ibid.
- /F dup cvx % see Objects section below
- /R dup cvx % see Objects section below
- /stream dup cvx % see Streams section below
-.dicttomark readonly def
-
-% ------ Utilities ------ %
-
-% Define a scratch string. The PDF language definition says that
-% no line in a PDF file can exceed 255 characters, but this string
-% is also used to search for %PDF-, which needs 1024 characters.
-/pdfstring 1024 string def
-
-% Read the previous line of a file. If we aren't at a line boundary,
-% read the line containing the current position.
-% Skip any blank lines.
-/prevline % - prevline <startpos> <substring>
- { PDFfile fileposition dup () pdfstring
- 2 index 257 sub 0 .max PDFfile exch setfileposition
- { % Stack: initpos linepos line string
- PDFfile fileposition
- PDFfile 2 index readline pop
- dup length 0 gt
- { 3 2 roll 5 -2 roll pop pop 2 index }
- { pop }
- ifelse
- % Stack: initpos linepos line string startpos
- PDFfile fileposition 5 index ge { exit } if
- pop
- }
- loop pop pop 3 -1 roll pop
- } bind def
-
-% Handle the PDF 1.2 #nn escape convention when reading from a file.
-% This should eventually be done in C.
-/.pdffixname { % <execname> .pdffixname <execname'>
- PDFversion 1.2 ge {
- dup .namestring (#) search {
- name#escape cvn exch pop
- } {
- pop
- } ifelse
- } if
-} bind def
-/name#escape % <post> <(#)> <pre> name#escape <string>
-{ exch pop
- 1 index 2 () /SubFileDecode filter dup (x) readhexstring
- % Stack: post pre stream char t/f
- not { % tolerate, but complain about bad syntax
- pop closefile (#) concatstrings exch
- ( **** Warning: Invalid hex following '#' name escape, using literal '#' in name.\n)
- pdfformaterror
- } {
- exch closefile concatstrings
- exch 2 1 index length 2 sub getinterval
- } ifelse
- (#) search { name#escape } if concatstrings
-} bind def
-
-% Execute a file, interpreting its executable names in a given
-% dictionary. The name procedures may do whatever they want
-% to the operand stack.
-/.pdftokenerror { % <count> <opdict> <errtoken> .pdftokenerror -
- BXlevel 0 le {
- ( **** Unknown operator: ') pdfformaterror
- dup =string cvs pdfformaterror
- % Attempt a retry scan of the element after changing to PDFScanInvNum
- << /PDFScanInvNum true >> setuserparams
- =string cvs
- token pop exch pop dup type
- dup /integertype eq exch /realtype eq or {
- exch pop exch pop
- (', processed as number, value: ) pdfformaterror
- dup =string cvs pdfformaterror (\n) pdfformaterror
- << /PDFScanInvNum null >> setuserparams % reset to default scanning rules
- false % suppress any stack cleanup
- } {
- % error was non-recoverable with modified scanning rules
- ('\n) pdfformaterror
- true
- } ifelse
- } {
- true
- } ifelse
- { % clean up the operand stack if this was non-recoverable
- pop pop count exch sub { pop } repeat % pop all the operands
- } if
-} bind def
-/.pdfexectoken { % <count> <opdict> <exectoken> .pdfexectoken ?
- PDFDEBUG {
- pdfdict /PDFSTEPcount known not { pdfdict /PDFSTEPcount 1 .forceput } if
- PDFSTEP {
- pdfdict /PDFtokencount 2 copy .knownget { 1 add } { 1 } ifelse .forceput
- PDFSTEPcount 1 gt {
- pdfdict /PDFSTEPcount PDFSTEPcount 1 sub .forceput
- } {
- dup ==only
- ( step # ) print PDFtokencount =only
- ( ? ) print flush 1 false .outputpage
- (%stdin) (r) file 255 string readline {
- token {
- exch pop pdfdict /PDFSTEPcount 3 -1 roll .forceput
- } {
- pdfdict /PDFSTEPcount 1 .forceput
- } ifelse % token
- } {
- pop /PDFSTEP false def % EOF on stdin
- } ifelse % readline
- } ifelse % PDFSTEPcount > 1
- } {
- dup ==only () = flush
- } ifelse % PDFSTEP
- } if % PDFDEBUG
- 2 copy .knownget {
- exch pop exch pop exch pop exec
- } {
- % Normally, true, false, and null would appear in opdict
- % and be treated as "operators". However, there is a
- % special fast case in the PostScript interpreter for names
- % that are defined in, and only in, systemdict and/or
- % userdict: putting these three names in the PDF dictionaries
- % destroys this property for them, slowing down their
- % interpretation in all PostScript code. Therefore, we
- % check for them explicitly here instead.
- dup dup dup /true eq exch /false eq or exch /null eq or {
- exch pop exch pop //systemdict exch get
- } {
- % Hackish fix to detect missing whitespace after "endobj". Yet another
- % problem that (you guessed it!) Adobe Acrobat ignores silently
- 256 string cvs (endobj) anchorsearch {
- ( **** Missing whitespace after 'endobj'.\n) pdfformaterror
- exch pop cvn get exch pop exec
- } {
- .pdftokenerror
- } ifelse
- } ifelse
- } ifelse
-} bind def
-/PDFScanRules_true << /PDFScanRules true >> def
-/PDFScanRules_null << /PDFScanRules null >> def
-/.pdfrun { % <file> <opdict> .pdfrun -
- % Construct a procedure with the stack depth, file and opdict
- % bound into it.
- 1 index cvlit count 2 sub 3 1 roll mark
- /PDFScanRules .getuserparam //null eq {
- //PDFScanRules_true { setuserparams } 0 get % force PDF scanning mode
- mark 7 4 roll
- } {
- mark 5 2 roll
- } ifelse
- { % Stack: ..operands.. count opdict file
- { token } stopped {
- dup type /filetype eq { pop } if % pop the operand if it is restored
- ( **** Error reading a content stream. The page may be incomplete.\n)
- pdfformaterror
- //false
- } if {
- dup type /nametype eq {
- dup xcheck {
- .pdfexectoken
- } {
- .pdffixname
- exch pop exch pop PDFDEBUG {
- PDFSTEPcount 1 le {
- dup ==only ( ) print flush
- } if
- } if
- } ifelse
- } {
- exch pop exch pop PDFDEBUG {
- PDFSTEPcount 1 le {
- dup ==only ( ) print flush
- } if
- } if
- } ifelse
- } {
- (%%EOF) cvn cvx .pdfexectoken
- } ifelse
- }
- aload pop .packtomark cvx
- { loop } 0 get 2 packedarray cvx
- { stopped } 0 get
- /PDFScanRules .getuserparam //null eq {
- //PDFScanRules_null { setuserparams } 0 get % reset PDF scannig mode if it was off
- } if
- /PDFsource PDFsource
- { store { stop } if } aload pop .packtomark cvx
- /PDFsource 3 -1 roll store exec
-} bind def
-currentdict /PDFScanRules_true undef
-currentdict /PDFScanRules_null undef
-
-% Execute a file, like .pdfrun, for a marking context.
-% This temporarily rebinds LocalResources and DefaultQstate.
-/.pdfruncontext { % <resdict> <file> <opdict> .pdfruncontext -
- /.pdfrun load LocalResources DefaultQstate
- /LocalResources 7 -1 roll store
- /DefaultQstate qstate store
- 3 .execn
- /DefaultQstate exch store
- /LocalResources exch store
-} bind def
-
-% Get the depth of the PDF operand stack. The caller sets pdfemptycount
-% before calling .pdfrun or .pdfruncontext. It is initially set by
-% pdf_main, and is also set by any routine which changes the operand
-% stack depth (currently .pdfpaintproc, although there are other callers
-% of .pdfrun{context} which have not been checked for opstack depth.
-/.pdfcount { % - .pdfcount <count>
- count pdfemptycount sub
-} bind def
-
-% Read a token, but simply return false (no token read) in the case of an
-% error. This is messy because 'token' either may or may not pop its operand
-% if an error occurs, and because the return values are different depending
-% on whether the source is a file or a string. To avoid closing the file
-% check for '{' before trying 'token'.
-/token_nofail_dict mark
- ( ) { dup ( ) readstring pop pop } bind
- (\t) 1 index
- (\r) 1 index
- (\n) 1 index
- (\000) 1 index
- ({) { //null //true exit } bind
-.dicttomark def
-
-/token_nofail { % <file|string> token_nofail false
- % <file> token_nofail <token> true
- % <string> token_nofail <post> <token> true
- dup type /filetype eq {
- { dup ( ) .peekstring not { ({) } if
- //token_nofail_dict exch .knownget not {
- //null 1 index { token } .internalstopped exit
- } if
- exec
- } loop
- { % stack: source null [source]
- //null ne { pop } if pop //false
- } { % stack: source null ([post] token true | false)
- { 3 1 roll pop pop //true }
- { pop pop //false }
- ifelse
- } ifelse
- } {
- //null 1 index % stack: source null source
- { token } .internalstopped { % stack: source null [source]
- //null ne { pop } if pop //false
- } { % stack: source null ([post] token true | false)
- { 4 2 roll pop pop //true }
- { pop pop //false }
- ifelse
- } ifelse
- } ifelse
-} bind def
-
-currentdict /token_nofail_dict .undef
-
-% ================================ Objects ================================ %
-
-% Since we may have more than 64K objects, we have to use a 2-D array to
-% hold them (and the parallel Generations structure).
-/lshift 9 def
-/lnshift lshift neg def
-/lsubmask 1 lshift bitshift 1 sub def
-/lsublen lsubmask 1 add def
-/larray { % - larray <larray>
- [ [] ]
-} bind def
-/lstring { % - lstring <lstring>
- [ () ]
-} bind def
-/ltype { % <lseq> type <type>
- 0 get type
-} bind def
-/lget { % <lseq> <index> lget <value>
- dup //lsubmask and 3 1 roll //lnshift bitshift get exch get
-} bind def
-/lput { % <lseq> <index> <value> lput -
- 3 1 roll
- dup //lsubmask and 4 1 roll //lnshift bitshift get
- 3 1 roll put
-} bind def
-/llength { % <lseq> llength <length>
- dup length 1 sub dup //lshift bitshift
- 3 1 roll get length add
-} bind def
-% lgrowto assumes newlength > llength(lseq)
-/growto { % <string/array> <length> growto <string'/array'>
- 1 index type /stringtype eq { string } { array } ifelse
- 2 copy copy pop exch pop
-} bind def
-/lgrowto { % <lseq> <newlength> lgrowto <lseq'>
- dup //lsubmask add //lnshift bitshift dup 3 index length gt {
- % Add more sub-arrays. Start by completing the last existing one.
- % Stack: lseq newlen newtoplen
- 3 -1 roll dup llength 1 sub //lsubmask or 1 add lgrowto
- % Stack: newlen newtoplen lseq
- [ exch aload pop
- counttomark 2 add -1 roll % newtoplen
- counttomark sub { dup 0 0 getinterval lsublen growto } repeat
- dup 0 0 getinterval ] exch
- } {
- pop
- } ifelse
- % Expand the last sub-array.
- 1 sub //lsubmask and 1 add
- exch dup dup length 1 sub 2 copy
- % Stack: newsublen lseq lseq len-1 lseq len-1
- get 5 -1 roll growto put
-} bind def
-/lforall { % <lseq> <proc> lforall -
- /forall cvx 2 packedarray cvx forall
-} bind def
-
-% We keep track of PDF objects using the following PostScript variables:
-%
-% Generations (lstring): Generations[N] holds 1+ the current
-% generation number for object number N. (As far as we can tell,
-% this is needed only for error checking.) For free objects,
-% Generations[N] is 0.
-%
-% Objects (larray): If object N is loaded, Objects[N] is the actual
-% object; otherwise, Objects[N] is an executable integer giving
-% the file offset of the object's location in the file. If
-% ObjectStream[N] is non-zero then Objects[N] contains the index
-% into the object stream instead of the file offset of the object.
-%
-% ObjectStream (larray): If object N is in an object stream then
-% ObjectStream[N] holds the object number of the object stream.
-% Otherwise ObjectStream[N] contains 0. If ObjectStream[N]
-% is non-zero then Objects[N] contains the index into the object
-% stream.
-%
-% GlobalObjects (dictionary): If object N has been resolved in
-% global VM, GlobalObjects[N] is the same as Objects[N]
-% (except that GlobalObjects itself is stored in global VM,
-% so the entry will not be deleted at the end of the page).
-%
-% IsGlobal (lstring): IsGlobal[N] = 1 iff object N was resolved in
-% global VM. This is an accelerator to avoid having to do a
-% dictionary lookup in GlobalObjects when resolving every object.
-
-% Initialize the PDF object tables.
-/initPDFobjects { % - initPDFobjects -
- /ObjectStream larray def
- /Objects larray def
- /Generations lstring def
- .currentglobal true .setglobal
- /GlobalObjects 20 dict def
- .setglobal
- /IsGlobal lstring def
-} bind def
-
-% Grow the tables to a specified size.
-/growPDFobjects { % <minsize> growPDFobjects -
- dup ObjectStream llength gt {
- dup ObjectStream exch lgrowto /ObjectStream exch def
- } if
- dup Objects llength gt {
- dup Objects exch lgrowto /Objects exch def
- } if
- dup Generations llength gt {
- dup Generations exch lgrowto /Generations exch def
- } if
- dup IsGlobal llength gt {
- dup IsGlobal exch lgrowto /IsGlobal exch def
- } if
- pop
-} bind def
-
-% We represent an unresolved object reference by a procedure of the form
-% {obj# gen# resolveR}. This is not a possible PDF object, because PDF has
-% no way to represent procedures. Since PDF in fact has no way to represent
-% any PostScript object that doesn't evaluate to itself, we can 'force'
-% a possibly indirect object painlessly with 'exec'.
-% Note that since we represent streams by executable dictionaries
-% (see below), we need both an xcheck and a type check to determine
-% whether an object has been resolved.
-/resolved? { % <object#> resolved? <value> true
- % <object#> resolved? false
- Objects 1 index lget dup xcheck { % Check if executable
- dup type /integertype eq { % Check if an integer
- % Check whether the object is in GlobalObjects.
- pop IsGlobal 1 index lget 0 eq { % 0 --> Not in GlabalObjects
- pop false % The object is not resolved
- } { % The object is in GlobalObjects
- % Update Objects from GlobalObjects
- PDFDEBUG { (%Global=>local: ) print dup == } if
- GlobalObjects 1 index get dup Objects 4 1 roll lput true
- } ifelse
- } { % Else object is executable but not integer
- exch pop true % Therefore must be executable dict. (stream)
- } ifelse
- } { % Else object is not executable.
- exch pop true % Therefore it must have been resolved.
- } ifelse
-} bind def
-/oforce /exec load def
-/oget { % <array> <index> oget <object>
- % <dict> <key> oget <object>
- % Before release 6.20, this procedure stored the resolved
- % object back into the referring slot. In order to support
- % PDF linearization, we no longer do this.
- get oforce
-} bind def
-/oforce_array { % <array> oforce_array <array>
- [ exch { oforce } forall ]
-} bind def
-/oforce_elems { % <array> oforce_elems <first> ... <last>
- { oforce } forall
-} bind def
-/oforce_recursive { % <any> oforce_recursive <any>
- oforce dup type dup /arraytype eq {
- pop [ exch { oforce_recursive } forall ]
- } {
- /dicttype eq {
- << exch { oforce_recursive exch oforce exch } forall >>
- } if
- } ifelse
-} bind def
-
-% A null value in a dictionary is equivalent to an omitted key;
-% we must check for this specially.
-/knownoget { % <dict> <key> knownoget <value> true
- % <dict> <key> knownoget false
- % See oget above regarding this procedure.
- .knownget {
- oforce dup //null eq { pop //false } { //true } ifelse
- } {
- //false
- } ifelse
-} bind def
-
-% PDF 1.1 defines a 'foreign file reference', but not its meaning.
-% Per the specification, we convert these to nulls.
-/F { % <file#> <object#> <generation#> F <object>
- % Some PDF 1.1 files use F as a synonym for f!
- .pdfcount 3 lt { f } { pop pop pop null } ifelse
-} bind def
-
-% Verify the generation number for a specified object
-% Note: The values in Generations is the generation number plus 1.
-% If the value in Generations is zero then the object is free.
-/checkgeneration { % <object#> <generation#> checkgeneration <object#> <OK>
- Generations 2 index lget 1 sub 1 index eq { % If generation # match ...
- pop true % Then return true
- } { % Else not a match ...
- QUIET not { % Create warning message if not QUIET
- Generations 2 index lget 0 eq { % Check if object is free ...
- ( **** Warning: reference to free object: )
- 2 index =string cvs concatstrings ( ) concatstrings % put obj #
- exch =string cvs concatstrings ( R\n) concatstrings % put gen #
- } {
- ( **** Warning: wrong generation: )
- 2 index =string cvs concatstrings ( ) concatstrings % put obj #
- exch =string cvs concatstrings % put gen #
- (, xref gen#: ) concatstrings 1 index Generations % put xref gen #
- exch lget 1 sub =string cvs concatstrings (\n) concatstrings
- } ifelse
- pdfformaterror % Output warning message
- } { % Else QUIET ...
- pop % Pop generation number
- } ifelse
- % We should return false for an incorrect generation number, however
- % we are simply printing a warning and then returning true. This makes
- % Ghostscript tolerant of of bad generation numbers.
- true
- } ifelse
-} bind def
-/R { % <object#> <generation#> R <object>
- /resolveR cvx 3 packedarray cvx
-} bind def
-
-% If we encounter an object definition while reading sequentially,
-% we just store it away and keep going.
-/objopdict mark
- valueopdict { } forall
- /endobj dup cvx
-.dicttomark readonly def
-
-/obj { % <object#> <generation#> obj <object>
- PDFfile objopdict .pdfrun
-} bind def
-
-/endobj { % <object#> <generation#> <object> endobj <object>
- 3 1 roll
- % Read the xref entry if we haven't yet done so.
- % This is only needed for generation # checking.
- 1 index resolved? {
- pop
- } if
- checkgeneration {
- % The only global objects we bother to save are
- % (resource) dictionaries.
- 1 index dup gcheck exch type /dicttype eq and {
- PDFDEBUG { (%Local=>global: ) print dup == } if
- GlobalObjects 1 index 3 index put
- IsGlobal 1 index 1 put
- } if
- Objects exch 2 index lput
- } {
- pop pop null
- } ifelse
-} bind def
-
-% When resolving an object reference in an object stream, we stop at
-% the end of file. Note: Objects in an object stream do not have either
-% a starting 'obj' or and ending 'endobj'.
-/resolveobjstreamopdict mark
- valueopdict { } forall
- (%%EOF) cvn { exit } bind
-.dicttomark readonly def
-
-% Note: This version of this function is not currently being used.
-% Resolve all objects in an object stream
-/resolveobjectstream { % <object stream #> resolveobjectstream -
- PDFDEBUG { (%Resolving object stream: ) print } if
- 0 resolveR % Get the objectstream dict, all objstrms use 0 as the gen #
- dup /First get % Save location of first object onto the stack
- 1 index /N get % Save number of objects onto the stack
- 2 index false resolvestream % Convert stream dict into a stream
- /ReusableStreamDecode filter % We need to be able to position stream
- % Objectstreams begin with list of object numbers and locations
- % Create two arrays to hold object numbers and stream location
- 1 index array % Array for holding object number
- 2 index array % Array for holding stream object location
- % Get the object numbers and locations.
- 0 1 5 index 1 sub { % Loop and collect obj # and locations
- % Stack: objstreamdict First N objectstream [obj#] [loc] index
- 2 index 1 index % Setup to put obj# into object number array
- 5 index token pop put % Get stream, then get obj# and put into array
- 1 index 1 index % Setup to put object loc into location array
- 5 index token pop put % Get stream, get obj loc and put into array
- pop % Remove loop index
- } for
- % Create a bytestring big enough for reading any object data
- % Scan for the size of the largest object
- 0 0 % Init max object size and previous location
- 2 index { % Loop through all object locations
- % Stack: ... maxsize prevloc currentloc
- dup 4 1 roll % Save copy of object location into stack
- exch sub % Object size = currentloc - prevloc
- .max % Determine maximum object size
- exch % Put max size under previous location
- } forall
- pop % Remove previous location
- .bigstring % Create bytestring based upon max obj size
- % Move to the start of the object data
- 3 index 6 index % Get objectstream and start of first object
- setfileposition % Move to the start of the data
- % Read the data for all objects except the last. We do
- % not know the size of the last object so we need to treat
- % it as a special case.
- 0 1 6 index 2 sub {
- dup 4 index exch get % Get our current object number
- % Stack: objstreamdict First N objectstream [obj#] [loc]
- % bytestring loopindex object#
- dup resolved? { % If we already have this object
- (yyy) = pstack (yyy) = flush xxx
- pop pop % Remove object and object number
- 1 add 2 index exch get % Get location of next object
- 6 index add 6 index exch % Form location of next object and get stream
- setfileposition % Move to the start of the next object data
- } { % Else this is a new object ...
- % We are going to create a string for reading the object
- 2 index 0 % use our working string
- % Determine the size of the object
- 5 index 4 index 1 add get % Get location of the next object
- 6 index 5 index get % Get location of this object
- sub % Size of object = next loc - this loc
- getinterval % Create string for reading object
- 6 index exch readstring pop % Read object
- /ReusableStreamDecode filter % Convert string into a stream
- resolveobjstreamopdict .pdfrun % Get PDF object
- Objects exch 2 index exch lput % Put object into Objects array
- pop pop % Remove object # and loop index
- } ifelse
- } for
- pop pop % Remove our working string and loc array
- % Now read the last object in the object stream. Since it
- % is the last object, we can use the original stream and
- % terminate when we hit the end of the stream
- % Stack: objstreamdict First N objectstream [obj#]
- 2 index 1 sub get % Get our current object number
- dup resolved? not { % If we do not already have this object
- exch % Get our object stream
- resolveobjstreamopdict .pdfrun % Get PDF object
- Objects exch 2 index exch lput % Put object into Objects array
- } if
- pop pop pop pop % Clear stack
-} bind def
-
-% Resolve all objects in an object stream
-/resolveobjectstream { % <object stream #> resolveobjectstream -
- PDFDEBUG { (%Resolving object stream: ) print } if
- 0 resolveR % Get the objectstream dict, all objstrms use 0 as the gen #
- dup /Type get /ObjStm ne { % Verify type is object stream
- ( **** Incorrect Type in object stream dictionary.\n) pdfformaterror
- /resolveobjectstream cvx /typecheck signalerror
- } if
- dup /N get % Save number of objects onto the stack
- 1 index false resolvestream % Convert stream dict into a stream
- /ReusableStreamDecode filter % We need to be able to position stream
- % Objectstreams begin with list of object numbers and locations
- 1 index array % Create array for holding object number
- % Get the object numbers
- 0 1 4 index 1 sub { % Loop and collect obj numbers
- % Stack: objstreamdict N PDFDEBUG objectstream [obj#] loopindex
- 1 index 1 index % Setup to put obj# into object number array
- 4 index token pop put % Get stream, then get obj# and put into array
- 2 index token pop pop pop % Get stream, get obj loc and clear stack
- } for
- % Move to the start of the object data
- 1 index 4 index /First get % Get objectstream and start of first object
- setfileposition % Move to the start of the data
- % We disable PDFDEBUG while reading the data stream. We will
- % print the data later
- PDFDEBUG /PDFDEBUG false def % Save PDFDEBUG and disable it while reading
- % Read the data for all objects. We check to see if we get
- % the number of objects that we expect.
- % Stack: objstreamdict N objectstream [obj#] PDFDEBUG
- mark 4 -1 roll % Get objectstream
- count 5 index add % Determine stack depth with objects
- /PDFObjectStkCount exch def
- resolveobjstreamopdict .pdfrun % Get PDF objects
- PDFObjectStkCount count ne { % Check stack depth
- ( **** Incorrect object count in object stream.\n) pdfformaterror
- /resolveobjectstream cvx /rangecheck signalerror
- } if
- % We have the object data
- counttomark array astore % Put objects into an array
- exch pop % Remove mark
- exch /PDFDEBUG exch def % Restore PDFDEBUG flag
- % Save the objects into Objects
- 0 1 2 index length 1 sub { % Loop through all objects
- % Stack: objstreamdict N [obj#] [objects] loopindex
- dup 3 index exch get % Get our current object number
- dup resolved? { % If we already have this object
- pop pop % Remove object and object number
- } { % Else if we do not have this object
- PDFDEBUG { (%Resolving compressed object: [) print dup =only ( 0]) = } if
- Objects exch 3 index % Put the object into Objects
- 3 index get
- PDFDEBUG { dup === flush } if
- lput
- } ifelse
- pop % Remove loop index
- } for
- pop pop pop pop % Remove objstream, N, (obj#], and [objects]
-} bind def
-
-% When resolving an object reference, we stop at the endobj or endstream.
-/resolveopdict mark
- valueopdict { } forall
- /endstream { endobj exit } bind
- /endobj { endobj exit } bind
- % OmniForm generates PDF file with endobj missing in some
- % objects. AR ignores this. So we have to do it too.
- /obj { pop pop endobj exit } bind
-.dicttomark readonly def
-
-/resolveR { % <object#> <generation#> resolveR <object>
- PDFDEBUG {
- PDFSTEPcount 1 le {
- (%Resolving: ) print 2 copy 2 array astore ==
- } if
- } if
- 1 index resolved? { % If object has already been resolved ...
- exch pop exch pop % then clear stack and return object
- } { % Else if not resolved ...
- PDFfile fileposition 3 1 roll % Save current file position
- 1 index Objects exch lget % Get location of object from xref
- 3 1 roll checkgeneration { % Verify the generation number
- % Stack: savepos objpos obj#
- ObjectStream 1 index lget dup 0 eq { % Check if obj in not an objstream
- pop exch PDFoffset add PDFfile exch setfileposition
- PDFfile token pop 2 copy ne
- { ( **** Unrecoverable error in xref!\n) pdfformaterror
- /resolveR cvx /rangecheck signalerror
- }
- if pop PDFfile token pop
- PDFfile token pop /obj ne
- { ( **** Unrecoverable error in xref!\n) pdfformaterror
- /resolveR cvx /rangecheck signalerror
- }
- if
- pdf_run_resolve % PDFfile resolveopdict .pdfrun
- } { % Else the object is in an ObjectStream
- % Process an objectstream object. We are going to resolve all
- % of the objects in sthe stream and place them into the Objects
- % array.
- % Stack: savepos objpos obj# objectstream#
- resolveobjectstream
- resolved? { % If object has already been resolved ...
- exch pop % Remove object pos from stack.
- } {
- pop pop null % Pop objpos and obj#, put null for object
- } ifelse
- } ifelse
- } { % Else the generation number is wrong
- % Don't cache if the generation # is wrong.
- pop pop null % Pop objpos and obj#, put null for object
- } ifelse % ifelse generation number is correct
- exch PDFfile exch setfileposition % Return to original file position
- } ifelse
-} bind def
-
-% ================================ Streams ================================ %
-
-% We represent a stream by an executable dictionary that contains,
-% in addition to the contents of the original stream dictionary:
-% /File - the file or string where the stream contents are stored,
-% if the stream is not an external one.
-% /FilePosition - iff File is a file, the position in the file
-% where the contents start.
-% /StreamKey - the key used to decrypt this stream, if any.
-% We do the real work of constructing the data stream only when the
-% contents are needed.
-
-% Construct a stream. The length is not reliable in the face of
-% different end-of-line conventions, but it's all we've got.
-%
-% PDF files are inconsistent about what may fall between the 'stream' keyword
-% and the actual stream data, and it appears that no one algorithm can
-% detect this reliably. We used to try to guess whether the file included
-% extraneous \r and/or \n characters, but we no longer attempt to do so,
-% especially since the PDF 1.2 specification states flatly that the only
-% legal terminators following the 'stream' keyword are \n or \r\n, both of
-% which are properly skipped and discarded by the token operator.
-% Unfortunately, this doesn't account for other whitespace characters that
-% may have preceded the EOL, such as spaces or tabs. Thus we back up one
-% character and scan until we find the \n terminator.
-/stream { % <dict> stream <modified_dict>
- dup /Length oget 0 eq {
- dup /Filter undef % don't confuse any filters that require data
- } if
- dup /F known dup PDFsource PDFfile eq or {
- not {
- dup /File PDFfile put
- % make sure that we are just past the EOL \n character
- PDFfile dup fileposition 1 sub setfileposition % back up one
-
- PDFfile read pop
- dup 13 eq {
- % If there had been a \n, token would have advanced over it
- % thus, if the terminator was \r, we have a format error!
- ( **** Warning: stream operator not terminated by valid EOL.\n) pdfformaterror
- pop % fileposition is OK (just past the \r).
- } {
- % Otherwise, scan past \n
- { 10 eq { exit } if
- PDFfile read pop
- } loop
- } ifelse
- dup /FilePosition PDFfile fileposition put
- PDFDEBUG {
- PDFSTEPcount 1 le {
- (%FilePosition: ) print dup /FilePosition get ==
- } if
- } if
- } if
- % Some (bad) PDf files have invalid stream lengths. This causes problems
- % if we reposition beyond the end of the file. So we compare the given
- % length to number of bytes left in the file.
- dup /Length oget
- dup PDFfile bytesavailable lt { % compare to to bytes left in file
- PDFfile fileposition % reposition to the end of stream
- add PDFfile exch setfileposition
- } {
- pop % bad stream length - do not reposition.
- % This will force a length warning below
- } ifelse
- } {
- pop
- % We're already reading from a stream, which we can't reposition.
- % Capture the sub-stream contents in a string.
- dup /Length oget string PDFsource exch readstring
- not {
- ( **** Warning: Unexpected EOF in stream!\n) pdfformaterror
- /stream cvx /rangecheck signalerror
- } if
- 1 index exch /File exch put
- } ifelse
- PDFsource token_nofail not { null } if
- dup /endobj eq {
- % Another case that Acrobat Reader handles -- 'endobj' without 'endstream'.
- ( **** Warning: stream missing 'endstream'.\n) pdfformaterror
- pop /endstream % fake a valid endstream
- } if
- /endstream ne {
- ( **** Warning: stream Length incorrect.\n) pdfformaterror
- dup /Length undef % prevent the use of the incorrect length.
- cvx endobj exit % exit from .pdfrun now.
- } if
- cvx
-} bind def
-/endstream {
- exit
-} bind def
-
-% Contrary to the published PDF (1.3) specification, Acrobat Reader
-% accepts abbreviated filter names everywhere, not just for in-line images,
-% and some applications (notably htmldoc) rely on this.
-/unabbrevfilterdict mark
- /AHx /ASCIIHexDecode /A85 /ASCII85Decode /CCF /CCITTFaxDecode
- /DCT /DCTDecode /Fl /FlateDecode /LZW /LZWDecode /RL /RunLengthDecode
-.dicttomark readonly def
-
-% Extract and apply filters.
-/filterparms { % <dict> <DPkey> <Fkey> filterparms
- % <dict> <parms> <filternames>
- 2 index exch knownoget {
- oforce_recursive
- exch 2 index exch knownoget {
- % Both filters and parameters.
- oforce_recursive
- exch dup type /nametype eq {
- 1 array astore exch
- dup type /arraytype ne { 1 array astore } if exch
- } if
- } {
- % Filters, but no parameters.
- //null exch
- dup type /nametype eq { 1 array astore } if
- } ifelse
- } {
- % No filters: ignore parameters, if any.
- pop //null { }
- } ifelse
-} bind def
-/filtername { % <filtername> filtername <filtername'>
- //unabbrevfilterdict 1 index .knownget { exch pop } if
- dup /Filter resourcestatus { pop pop } {
- Repaired exch % this error is not the creator's fault
- ( **** ERROR: Unable to process ) pdfformaterror
- 64 string cvs pdfformaterror
- ( data. Page will be missing data.\n) pdfformaterror
- /Repaired exch store % restore the previous "Repaired" state
- % provide a filter that returns EOF (no data)
- /.EOFDecode
- } ifelse
-} bind def
-/applyfilters { % <parms> <source> <filternames> applyfilters <stream>
- 2 index null eq {
- { filtername filter }
- } {
- { % Stack: parms source filtername
- 2 index 0 oget dup null eq { pop } {
- exch filtername dup /JBIG2Decode eq { exch jbig2cachectx exch } if
- } ifelse filter
- exch dup length 1 sub 1 exch getinterval exch
- }
- } ifelse forall exch pop
-} bind def
-
-% JBIG2 streams have an optional 'globals' stream obj for
-% sharing redundant data between page images. Here we resolve
-% that stream reference (if any) and run it through the decoder,
-% creating a special -jbig2globalctx- postscript object our
-% JBIG2Decode filter implementation looks for in the parm dict.
-/jbig2cachectx { % <parmdict> jbig2cachectx <parmdict>
- dup /JBIG2Globals knownoget {
- % make global ctx
- PDFfile fileposition exch % resolvestream is not reentrant
- true resolvestream % stack after: PDFfileposition -file-
- % Read the data in a loop until EOF to so we can move the strings into a bytestring
- [ { counttomark 1 add index 60000 string readstring not { exit } if } loop ]
- exch pop 0 1 index { length add } forall % compute the total length
- % now copy the data from the array of strings into a bytestring
- .bytestring exch 0 exch { 3 copy putinterval length add } forall pop
- .jbig2makeglobalctx
- PDFfile 3 -1 roll setfileposition
- 1 index exch
- /.jbig2globalctx exch put
- } if
-} bind def
-
-% When used with a PDF image dict, the JPXDecode filter needs to know
-% about any ColorSpace entries, since this overrides whatever is in
-% the image stream itself. We therefore propagate any such key into
-% a filter's DecodeParms.
-/jpxparmfix { % <streamdict> <readdata?> jpxparmfix <streamdict <readdata?>
- 1 index /Filter .knownget
- { /JPXDecode eq % we only need to do this for JPXDecode filters
- % TODO: handle filter arrays
- {
- 1 index /ColorSpace knownoget {
- 2 index /DecodeParms knownoget {
- % insert in the existing DecodeParms dict
- /ColorSpace 3 -1 roll put
- }{
- 1 dict % need to create a custom DecodeParms dict
- dup /ColorSpace 4 -1 roll put
- 2 index exch /DecodeParms exch put
- } ifelse
- } if
- } if
- } if
-} bind def
-
-% Resolve a stream dictionary to a PostScript stream.
-% Streams with no filters require special handling:
-% - Whether we are going to interpret the stream, or If we are just
-% going to read data from them, we impose a SubFileDecode filter
-% that reads just the requisite amount of data.
-% Note that, in general, resolving a stream repositions PDFfile.
-% Clients must save and restore the position of PDFfile themselves.
-/resolvestream { % <streamdict> <readdata?> resolvestream <stream>
- jpxparmfix
- 1 index /F knownoget {
- % This stream is stored on an external file.
- (r) file 3 -1 roll
- /FDecodeParms /FFilter filterparms
- % Stack: readdata? file dict parms filternames
- 4 -1 roll exch
- pdf_decrypt_stream
- applyfilters
- } {
- exch
- dup /Length knownoget { 0 eq } { //false } ifelse {
- () 0 () /SubFileDecode filter
- } {
- dup /FilePosition .knownget {
- 1 index /File get exch setfileposition
- } if
- % Stack: readdata? dict
- /DecodeParms /Filter filterparms
- % Stack: readdata? dict parms filternames
- 2 index /File get exch
- % Stack: readdata? dict parms file/string filternames
- dup length 0 eq {
- % All the PDF filters have EOD markers, but in this case
- % there is no specified filter.
- exch dup type /filetype eq 5 index or {
- % Use length for any files or reading data from any source.
- 3 index /Length knownoget not { 0 } if
- } {
- 0 % Otherwise length of 0 for whole string
- } ifelse
- 4 index /IDFlag known { pop } { () /SubFileDecode filter } ifelse
- exch
- pdf_decrypt_stream % add decryption if needed
- pop exch pop
- } {
- % Stack: readdata? dict parms source filternames
- exch 3 index /Length knownoget {
- () /SubFileDecode filter
- } if exch
- pdf_decrypt_stream % add decryption if needed
- applyfilters
- } ifelse
- } ifelse
- } ifelse
- % Stack: readdata? dict file
- exch pop exch pop
-} bind def
-
-% ============================ Name/number trees ============================ %
-
-/nameoget { % <nametree> <key> nameoget <obj|null>
- exch /Names exch .treeget
-} bind def
-
-/numoget { % <numtree> <key> numoget <obj|null>
- exch /Nums exch .treeget
-} bind def
-
-/.treeget { % <key> <leafkey> <tree> .treeget <obj|null>
- dup /Kids knownoget {
- exch pop .branchget
- } {
- exch get .leafget
- } ifelse
-} bind def
-
-/.branchget { % <key> <leafkey> <kids> .branchget <obj|null>
- dup length 0 eq {
- pop pop pop null
- } {
- dup length -1 bitshift 2 copy oget
- % Stack: key leafkey kids mid kids[mid]
- dup /Limits oget aload pop
- % Stack: key leafkey kids mid kids[mid] min max
- 6 index lt {
- pop pop
- 1 add 1 index length 1 index sub getinterval .branchget
- } {
- 5 index gt {
- pop
- 0 exch getinterval .branchget
- } {
- exch pop exch pop .treeget
- } ifelse
- } ifelse
- } ifelse
-} bind def
-
-/.leafget { % <key> <pairs> .leafget <obj|null>
- dup length 2 eq {
- dup 0 get 2 index eq { 1 oget } { pop null } ifelse
- exch pop
- } {
- dup length -1 bitshift -2 and 2 copy oget
- % Stack: key pairs mid pairs[mid]
- 3 index gt { 0 exch } { 1 index length 1 index sub } ifelse
- getinterval .leafget
- } ifelse
-} bind def
-
-end % pdfdict
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/pdf_cslayer.ps b/Master/tlpkg/tlgs/lib/pdf_cslayer.ps deleted file mode 100644 index 7178d5eb4e3..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf_cslayer.ps +++ /dev/null @@ -1,121 +0,0 @@ -% Copyright (C) 2007 Artifex Software, Inc.
-% All Rights Reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied, modified
-% or distributed except as expressly authorized under the terms of that
-% license. Refer to licensing information at http://www.artifex.com/
-% or contact Artifex Software, Inc., 7 Mt. Lassen Drive - Suite A-134,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861, for further information.
-%
-% $Id: pdf_cslayer.ps 8284 2007-10-10 17:40:38Z giles $
-%
-% Layer data extraction from Illustator CS2/CS3 files
-%
-
-.languagelevel dup 2 .max .setlanguagelevel
-.currentglobal //true .setglobal
-/pdfdict load dup /pdfopdict get dup length dict copy dup begin /pdfopdict exch put
-
-/BMC {
- currentdevice //null //false mark
- /MarkType (BMC)
- /BMC_Tag 8 1 roll 256 string cvs
- //systemdict /CSLAYERDEBUG .knownget {
- { (### BMC to deviceparams, tag: ) print dup = flush } if
- } if
- .putdeviceparamsonly dup type /booleantype ne {
- cleartomark pop
- } if
- pop pop % discard the device and flag
- pop pop % discard /BMC_Tag and the tag name
-} bind def
-
-/BDC { % send selected BDC info to the device as properties
- 10 dict begin % private working dictionary
- /MarkType (BDC) def % BDC code
- % process the tag and Title for now
- exch 256 string cvs /BDC_Tag exch def % convert tag to a string
- dup type /nametype eq {
- dup Page /Properties rget not {
- pop 0 dict % empty dict in case missing Properties Resource
- } if
- exch pop % discard the resource name
- } if
-
- dup /Type knownoget { /OCG eq } { //false } ifelse {
- % Illustrator CS3 and higher
- dup /Name knownoget not { () } if % no Name, use an empty string
- /BDC_Title exch def
-
- dup /Usage knownoget not { 0 dict } if
- dup /View knownoget { /ViewState knownoget { /OFF ne } { //true } ifelse } { //true } ifelse
- /BDC_Visible exch def
- dup /Print knownoget { /PrintState knownoget { /OFF ne } { //true } ifelse } { //true } ifelse
- /BDC_Printed exch def
- pop % Usage dict
-
- dup /Intent knownoget {
- dup type /nametype eq {
- /Design eq
- } {
- //false exch { oforce /Design eq or } forall
- } ifelse
- } {
- //false
- } ifelse
- /BDC_Editable exch def
-
- /BDC_Preview //true def
- /BDC_Dimmed //false def
- /BDC_Transparency //true def
- /BDC_FlatLayer //true def
- } {
- % Illustrator CS2
- dup /Title knownoget not { () } if % no Title, use an empty string
- /BDC_Title exch def
- dup /Visible knownoget not { //true } if % no Visible flag, set true
- /BDC_Visible exch def
- dup /Preview knownoget not { //true } if % no preview flag, set true
- /BDC_Preview exch def
- dup /Editable knownoget not { //true } if % no Editable flag, set true
- /BDC_Editable exch def
- dup /Printed knownoget not { //true } if % no printed flag, set true
- /BDC_Printed exch def
- dup /Dimmed knownoget not { //true } if % no dimmed flag, set true
- /BDC_Dimmed exch def
- dup /Transparency knownoget not { //true } if % no Transparency flag, set true
- /BDC_Transparency exch def
- dup /FlatLayer knownoget not { //true } if % no flat layer flag, set true
- /BDC_FlatLayer exch def
- } ifelse
-
- % now send the collected info to the device
- //systemdict /CSLAYERDEBUG .knownget {
- { (### BDC info to deviceparams: ) print currentdict === flush } if
- } if
- currentdevice //null //false mark currentdict { } forall
- .putdeviceparamsonly dup type /booleantype ne {
- cleartomark pop
- } if
- pop pop % discard the device and flag
- end % discard private dict
- pop % done with properties dict
-} bind def
-
-/EMC {
- currentdevice //null //false mark /MarkType (EMC)
- //systemdict /CSLAYERDEBUG .knownget {
- { (### EMC to deviceparams) = flush } if
- } if
- .putdeviceparamsonly dup type /booleantype ne {
- cleartomark pop
- } if
- pop pop % discard the device and flag
-} bind def
-
-currentdict readonly pop end
-.setglobal
-.setlanguagelevel
diff --git a/Master/tlpkg/tlgs/lib/pdf_draw.ps b/Master/tlpkg/tlgs/lib/pdf_draw.ps deleted file mode 100644 index 538c9f57614..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf_draw.ps +++ /dev/null @@ -1,1683 +0,0 @@ -% Copyright (C) 1994, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdf_draw.ps 8554 2008-02-27 19:36:18Z leonardo $
-% pdf_draw.ps
-% PDF drawing operations (graphics, text, and images).
-
-/.setlanguagelevel where { pop 2 .setlanguagelevel } if
-.currentglobal true .setglobal
-/pdfdict where { pop } { /pdfdict 100 dict def } ifelse
-GS_PDF_ProcSet begin
-pdfdict begin
-
-% For simplicity, we use a single interpretation dictionary for all
-% PDF graphics operations, even though this is too liberal.
-/drawopdict 100 dict def
-
-% ================================ Graphics ================================ %
-
-% ---------------- Functions ---------------- %
-
-% Note that resolvefunction converts a PDF Function to a PostScript Function;
-% resolve*fnproc converts a PDF function to a PostScript procedure.
-% We need to process all required and optional parameters to resolve any
-% use of indirect references.
-
-/fnrdict mark
- 0 { .resolvefn0 }
- 2 { .resolvefn2 }
- 3 { .resolvefn3 }
- 4 { .resolvefn4 }
-.dicttomark readonly def
-
-/.resolvefn0 {
- dup length 1 add dict .copydict % make room for DataSource
- % now resolve any indirect references
- dup /Size 2 copy knownoget { put } { pop pop } ifelse
- dup /BitsPerSample 2 copy knownoget { put } { pop pop } ifelse
- dup /Order 2 copy knownoget { put } { pop pop } ifelse
- dup /Encode 2 copy knownoget { put } { pop pop } ifelse
- dup /Decode 2 copy knownoget { put } { pop pop } ifelse
-
- % Don't lose our place in PDFfile.
- PDFfile fileposition exch
- dup true resolvestream
- % The stream isn't positionable, so read all the data now.
- % Stack: filepos fndict stream
- 1 index /Range get length 2 idiv 2 index /BitsPerSample get mul
- 2 index /Size get { mul } forall
- 7 add 8 idiv string
- 1 index exch readstring pop exch closefile
- % Stack: filepos fndict data
- exch dup /DataSource 4 -1 roll put
- exch PDFfile exch setfileposition
-} bdef
-
-/.resolvefn2 {
- dup length dict .copydict
- dup /C0 2 copy knownoget { put } { pop pop } ifelse
- dup /C1 2 copy knownoget { put } { pop pop } ifelse
- dup /N 2 copy knownoget { put } { pop pop } ifelse
-} bdef
-
-/.resolvefn3 {
- dup length dict .copydict
- dup /Bounds 2 copy knownoget { put } { pop pop } ifelse
- dup /Encode 2 copy knownoget { put } { pop pop } ifelse
- dup /Functions 2 copy oget mark exch dup {
- oforce .resolvefn
- } forall
- counttomark -1 roll astore exch pop put
-} bdef
-
-/.resolvefn4 {
- PDFfile fileposition exch % filepos fndict
- dup true resolvestream % filepos fndict stream
- exch dup length dict copy % filepos stream fndict2
- dup /Function undef % filepos stream fndict2
- exch dup token not {
- () /rangecheck cvx signalerror
- } if
- exch token {
- /rangecheck cvx signalerror
- } if
- % Use .bind to avoid idiom recognition.
- .bind
- 1 index /Function 3 -1 roll put
- exch PDFfile exch setfileposition
-} bdef
-
-/.resolvefn { % <fndict> .resolvefn <fndict'>
- dup length dict .copydict
- dup /Domain 2 copy knownoget { put } { pop pop } ifelse
- dup /Range 2 copy knownoget { put } { pop pop } ifelse
- dup /FunctionType oget //fnrdict exch get exec
-} bdef
-
-/resolvefunction { % <fndict> resolvefunction <function>
- .resolvefn
- PDFDEBUG { pdfdict /PDFSTEPcount .knownget { 1 le } { true } ifelse { (%Function: ) print dup === flush } if } if
-} bdef
-
-/resolvefnproc { % <fndict> resolvefnproc <proc>
- resolvefunction .buildfunction
-} bdef
-
-/resolveidfnproc { % <fndict> resolveidfnproc <proc>
- dup /Identity eq { pop { } } { resolvefnproc } ifelse
-} bdef
-
-/resolvedefaultfnproc { % <fndict> <default> resolved'fnproc <proc>
- 1 index /Default eq { exch pop } { pop resolveidfnproc } ifelse
-} bdef
-
-% ---------------- Shadings ---------------- %
-
-/shrdict mark
- /BBox {
- dup dup dup aload pop normrect_elems
- 5 -1 roll astore
- } bind
- /ColorSpace {
- resolvecolorspace
- } bind
- /Function {
- dup type /dicttype eq {
- resolvefunction
- } {
- [ exch { oforce resolvefunction } forall ]
- } ifelse
- } bind
-.dicttomark readonly def
-
-/resolveshading { % <shadingstream> resolveshading <shading>
- dup /.shading_dict .knownget {
- exch pop
- dup /ShadingType get 4 ge {
- dup /DataSource get 0 setfileposition
- } if
- } {
- dup
- PDFfile fileposition exch
- mark exch {
- oforce //shrdict 2 index .knownget { exec } if
- } forall .dicttomark
- dup /ShadingType get 4 ge {
- dup dup true resolvestream
- % Make a reusable stream so that the shading doesn't
- % reposition PDFfile at unexpected times.
- /ReusableStreamDecode filter /DataSource exch put
- } if
- exch PDFfile exch setfileposition
- dup 3 1 roll /.shading_dict exch put
- } ifelse
-} bdef
-/resolvesh { % <shname> resolvesh <shading>
- % <shname> resolvesh <null>
- Page /Shading rget {
- resolveshading
- } {
- null
- }ifelse
-} bdef
-
-% ---------------- Halftones ---------------- %
-
-/spotfunctions mark
- /Round {
- abs exch abs 2 copy add 1 le {
- dup mul exch dup mul add 1 exch sub
- } {
- 1 sub dup mul exch 1 sub dup mul add 1 sub
- } ifelse
- }
- /Diamond {
- abs exch abs 2 copy add .75 le {
- dup mul exch dup mul add 1 exch sub
- } {
- 2 copy add 1.23 le {
- .85 mul add 1 exch sub
- } {
- 1 sub dup mul exch 1 sub dup mul add 1 sub
- } ifelse
- } ifelse
- }
- /Ellipse {
- abs exch abs 2 copy 3 mul exch 4 mul add 3 sub dup 0 lt {
- pop dup mul exch .75 div dup mul add 4 div 1 exch sub
- } {
- dup 1 gt {
- pop 1 exch sub dup mul exch 1 exch sub
- .75 div dup mul add 4 div 1 sub
- } {
- .5 exch sub exch pop exch pop
- } ifelse
- } ifelse
- }
- /EllipseA { dup mul .9 mul exch dup mul add 1 exch sub }
- /InvertedEllipseA { dup mul .9 mul exch dup mul add 1 sub }
- /EllipseB { dup 5 mul 8 div mul exch dup mul exch add sqrt 1 exch sub }
- /EllipseC { dup mul .9 mul exch dup mul add 1 exch sub }
- /InvertedEllipseC { dup mul .9 mul exch dup mul add 1 sub }
- /Line { exch pop abs neg }
- /LineX { pop }
- /LineY { exch pop }
- /Square { abs exch abs 2 copy lt { exch } if pop neg }
- /Cross { abs exch abs 2 copy gt { exch } if pop neg }
- /Rhomboid { abs exch abs 0.9 mul add 2 div }
- /DoubleDot { 2 {360 mul sin 2 div exch } repeat add }
- /InvertedDoubleDot { 2 {360 mul sin 2 div exch } repeat add neg }
- /SimpleDot { dup mul exch dup mul add 1 exch sub }
- /InvertedSimpleDot { dup mul exch dup mul add 1 sub }
- /CosineDot { 180 mul cos exch 180 mul cos add 2 div }
- /Double { exch 2 div exch 2 { 360 mul sin 2 div exch } repeat add }
- /InvertedDouble {
- exch 2 div exch 2 { 360 mul sin 2 div exch } repeat add neg
- }
-.dicttomark readonly def
-
-/htrdict mark
- 1 { .resolveht1 }
- 5 { .resolveht5 }
- % We don't support types 6, 10, or 16 yet.
-.dicttomark readonly def
-
-/.resolveht1 {
- mark exch {
- oforce
- 1 index /SpotFunction eq {
- dup type /nametype eq
- { //spotfunctions exch get } { resolvefnproc }
- ifelse
- } {
- 1 index /TransferFunction eq {
- resolveidfnproc
- } if
- } ifelse
- } forall .dicttomark
-} bdef
-
-/.resolveht5 {
- mark exch {
- oforce dup type /dicttype eq { resolvehalftone } if
- } forall .dicttomark
-} bdef
-
-/resolvehalftone { % <dict> resolvehalftone <halftone>
- dup /HalftoneType get
- dup //htrdict exch .knownget {
- exch pop exec
- } {
- (\n\n **** Unsupported HalftoneType ) pdfformaterror
- =string cvs pdfformaterror (. ***\n\n) pdfformaterror
- /resolvehalftone cvx /unregistered signalerror
- } ifelse
-} bdef
-
-% ---------------- Graphics state management ---------------- %
-
-/cmmatrix matrix def
-drawopdict begin
- % Graphics state stack
- /q { q } def
- /Q { Q } def
- % Graphics state setting
- /cm { //cmmatrix astore
- .getpath
- exch concat
- newpath { exec } forall
- % If inside a BT/ET block, we need to update the TextSaveMatrix
- currentdict /TextSaveMatrix .knownget {
- //cmmatrix exch dup concatmatrix pop
- } if
- } bdef
-
- /i { 1 .min setflat } bdef
- /J /setlinecap load def
- /d /setdash load def
- /j /setlinejoin load def
- /w /setlinewidth load def
- /M { 1 .max setmiterlimit } bdef
- /gs { gs } def
-end
-
-% Each entry in this dictionary is
-% <gsres> <value> -proc- <gsres>
-/gsbg {
- /BGDefault load resolvedefaultfnproc setblackgeneration
-} bdef
-/gsucr {
- /UCRDefault load resolvedefaultfnproc setundercolorremoval
-} bdef
-/gstr {
- dup type /arraytype eq {
- { oforce /TRDefault load resolvedefaultfnproc } forall
- setcolortransfer
- } {
- /TRDefault load resolvedefaultfnproc settransfer
- } ifelse
-} bdef
-/gsparamdict mark
- /SA { setstrokeadjust }
- /OP { 1 index /op known not { dup op } if OP }
- % The PDF 1.3 specification says that the name /Default is only
- % recognized for {BG,UCR,TR}2. However, PDF 1.3 files produced
- % by Adobe Acrobat Distiller 4.0 for Windows use the name /Default
- % with the older keys, so we have to implement this.
- /BG { 1 index /BG2 known { pop } { gsbg } ifelse }
- /UCR { 1 index /UCR2 known { pop } { gsucr } ifelse }
- /TR { 1 index /TR2 known { pop } { gstr } ifelse }
- /HT {
- dup /Default eq {
- pop .setdefaulthalftone
- } {
- %****** DOESN'T IMPLEMENT THE STREAM CASE YET ******
- resolvehalftone sethalftone
- } ifelse
- % the transfer function may dependent on the halftone, so make sure
- % it is set if included in the graphic state (otherwise this is
- % subject to order of a dictionary forall, which is unpredictable)
- dup /TR2 .knownget {
- dup /Default eq { oforce gsparamdict /TR2 get exec } { pop } ifelse
- } {
- dup /TR .knownget {
- /dup /Default eq { oforce gsparamdict /TR get exec } { pop } ifelse
- } if
- } ifelse
- }
- /HTP {
- % HTP may be present even if this isn't a DPS interpreter.
- /sethalftonephase where { pop aload pop sethalftonephase } { pop } ifelse
- }
- % PDF 1.3
- /Font { aload pop Tf }
- /LW { setlinewidth }
- /LC { setlinecap }
- /LJ { setlinejoin }
- /ML { 1 .max setmiterlimit }
- /D { aload pop setdash }
- /RI { ri }
- /op { op }
- /OPM { OPM }
- /BG2 { gsbg }
- /UCR2 { gsucr }
- /TR2 { gstr }
- /FL { 1 .min setflat }
- /SM {
- % SM may be present even if this is only a Level 2 interpreter.
- /setsmoothness where { pop setsmoothness } { pop } ifelse
- }
- % PDF 1.4
- % All of these require the "transparency" feature in the interpreter.
- /ca { ca }
- /CA { CA }
- /SMask { gssmask }
- /AIS { AIS }
- /BM { BM }
- /TK { TK }
-.dicttomark readonly def
-/gs { % <gsres> gs -
- Page /ExtGState rget {
- % We keep the dictionary on the stack during the forall so that
- % keys that interact with each other have access to it.
- dup {
- oforce exch gsparamdict exch .knownget { exec } { pop } ifelse
- } forall pop
- } if
-} bdef
-
-% ------ Transparency support ------ %
-
-/gssmask {
- dup /None eq PDFusingtransparency not or {
- pop null
- } {
- % Preprocess the SMask value into a parameter dictionary for
- % .begintransparencymaskgroup, with added /BBox and /Draw keys.
- mark exch % Stack: mark smaskdict
- dup /S oget /Subtype exch 3 2 roll
- % Stack: mark ... smaskdict
- dup /BC knownoget {
- dup /Background exch 4 2 roll
- gsave
- 1 index /G oget /Group oget /CS knownoget {
- csresolve dup setgcolorspace csput
- } if
- aload pop setcolor [ currentgray ]
- grestore
- /GrayBackground exch 3 2 roll
- } if
- dup /TR knownoget {
- resolveidfnproc /TransferFunction exch 3 2 roll
- } if
- dup /G oget dup /BBox oget /BBox exch 4 2 roll
- /.execmaskgroup cvx 2 packedarray cvx /Draw exch 3 2 roll
- pop .dicttomark
- } ifelse SMask
-} bdef
-
-% This procedure is called to actually render the soft mask.
-/.execmaskgroup { % <masknum> <paramdict> <formdict> .execmaskgroup -
- % Save our place in PDFfile, and do a gsave to avoid resetting
- % the color space.
- currentcolorspace 4 1 roll
- PDFfile fileposition 4 1 roll
- % We have to select the group's color space so that the
- % background color will be interpreted correctly.
- dup /Group oget /CS knownoget { csresolve dup setgcolorspace csput } if
- exch dup /BBox get aload pop .begintransparencymaskgroup {
- dup /Resources knownoget { oforce } { 0 dict } ifelse
- exch false resolvestream
- .execgroup .endtransparencymask
- } stopped {
- .discardtransparencymask stop
- } if
- PDFfile exch setfileposition
- setcolorspace
-} bdef
-% Paint a Form+Group XObject, either for a transparency mask or for a Do.
-/.execgroup { % <resdict> <stream> .execgroup -
- gsave //nodict begin
- null SMask
- 1 .setopacityalpha 1 .setshapealpha
- /Compatible .setblendmode
- % Execute the body of the Form, similar to DoForm.
- pdfopdict .pdfruncontext
- end grestore
-} bdef
-
-/.beginformgroup { % groupdict bbox .beginformgroup -
- exch mark exch % bbox mark groupdict
- dup /CS knownoget { csresolve setgcolorspace } if
- dup /I knownoget { /Isolated exch 3 2 roll } if
- dup /K knownoget { /Knockout exch 3 2 roll } if
- pop .dicttomark
- % Stack: bbox paramdict
- exch aload pop
- .begintransparencygroup
-} bdef
-
-% .paintgroupform implements the Form PaintProc in the case where the
-% Form XObject dictionary includes a Group key. See .paintform below.
-/.paintgroupform { % <resdict> <stream> <formdict> .paintgroupform -
- dup /Group oget exch /BBox oget
- % Stack: resdict stream groupdict bbox
- .beginformgroup {
- .execgroup
- } stopped {
- .discardtransparencygroup stop
- } if .endtransparencygroup
-} bdef
-
-% Make an ImageType 103 (soft-masked) image.
-/makesoftmaskimage { % <datasource> <imagemask> <SMask> makesoftmaskimage
- % <datasource> <imagemask>, updates currentdict =
- % imagedict
- % See the ImageType 3 case of makemaskimage below.
- % SMask is a stream, another Image XObject.
- % Stack: datasource imagemask(false) smaskstreamdict
- PDFfile fileposition exch
- dup /Matte knownoget { /Matte exch def } if
- dup length dict makeimagedict pop
- % In order to prevent the two data sources from being
- % aliased, we need to make at least one a reusable stream.
- % We pick the mask, since it's smaller (in case we need to
- % read all its data now).
- % Stack: datasource imagemask(false) savedpos
- % maskdict is currentdict
- /DataSource DataSource mark
- /Intent 1
- /AsyncRead true
- .dicttomark .reusablestreamdecode def
- PDFfile exch setfileposition
- currentdict end currentdict end
- 5 dict begin
- /ImageType 103 def
- /DataDict exch def
- dup /InterleaveType 3 put
- DataDict /Matte knownoget {
- /Matte exch def
- } if
- AlphaIsShape { /ShapeMaskDict } { /OpacityMaskDict } ifelse exch def
- /ColorSpace DataDict /ColorSpace get def
-} bdef
-
-% ---------------- Color setting ---------------- %
-
-/01_1 [0 1] readonly def
-/01_3 [0 1 0 1 0 1] readonly def
-/01_4 [0 1 0 1 0 1 0 1] readonly def
-
-% The keys here are resolved (PostScript, not PDF) color space names.
-/csncompdict mark
- /DeviceGray { pop 1 }
- /DeviceRGB { pop 3 }
- /DeviceCMYK { pop 4 }
- /CIEBasedA { pop 1 }
- /CIEBasedABC { pop 3 }
- /ICCBased { 1 oget /N oget }
- /Separation { pop 1 }
- /DeviceN { 1 oget length }
-.dicttomark readonly def
-
-/csrdict mark
- /DeviceGray { }
- /DeviceRGB { }
- /DeviceCMYK { }
- /CalGray {
- 1 oget 6 dict begin
- dup /Gamma knownoget {
- /exp load 2 packedarray cvx /DecodeA exch def
- } if
- dup /BlackPoint knownoget { /BlackPoint exch def } if
- dup /WhitePoint knownoget {
- dup /WhitePoint exch def
- dup /MatrixA exch def
- /RangeLMN [ 3 2 roll { 0 exch } forall ] def
- } if
- /PDFColorSpace exch def [ /CIEBasedA currentdict end ]
- }
- /CalRGB {
- 1 oget 6 dict begin
- dup /Gamma knownoget {
- [ exch { /exp load 2 packedarray cvx } forall
- ] /DecodeABC exch def
- } if
- dup /Matrix knownoget { /MatrixABC exch def } if
- dup /BlackPoint knownoget { /BlackPoint exch def } if
- dup /WhitePoint knownoget { /WhitePoint exch def } if
- /PDFColorSpace exch def [ /CIEBasedABC currentdict end ]
- }
- /CalCMYK {
- pop /DeviceCMYK % not defined by Adobe
- }
- /Lab {
- 1 oget 6 dict begin
- dup /Range knownoget not { [-100 100 -100 100] } if
- [0 100 null null null null] dup 2 4 -1 roll putinterval
- /RangeABC exch def
- /DecodeABC [{16 add 116 div} bind {500 div} bind {200 div} bind] def
- /MatrixABC [1 1 1 1 0 0 0 0 -1] def
- dup /BlackPoint knownoget { /BlackPoint exch def } if
- dup /WhitePoint knownoget { /WhitePoint exch def } {
- ( **** Warning: Lab colorspace is missing WhitePoint.\n)
- pdfformaterror
- /WhitePoint [0.9505 1 1.089] def
- } ifelse
- % scaling function g() for DecodeLMN construction
- { dup 6 29 div ge {dup dup mul mul} {4 29 div sub 108 841 div mul} ifelse }
- /DecodeLMN [
- % Store white point implicitly inside procedures.
- [ 3 index aload pop WhitePoint 0 get /mul .systemvar ] cvx bind
- [ 4 index aload pop WhitePoint 1 get /mul .systemvar ] cvx bind
- [ 5 index aload pop WhitePoint 2 get /mul .systemvar ] cvx bind
- ] def pop
- /PDFColorSpace exch def [ /CIEBasedABC currentdict end ]
- }
- /ICCBased {
- dup 1 get type /dicttype ne { % don't resolve more than once
- PDFfile fileposition exch
- dup dup 1 oget
- mark exch { oforce } forall .dicttomark
- dup dup true resolvestream
- /ReusableStreamDecode filter /DataSource exch put
- 1 exch put
- exch PDFfile exch setfileposition
- % Resolve alternate color space
- dup 1 get % Get colorspace dictionary
- dup /Alternate .knownget % Check for alternate color space
- { oforce resolvecolorspace /Alternate exch put } % resolve and replace
- { pop } % remove colorspace dictionary
- ifelse
- } if
- } bind
- /Separation {
- aload pop exch oforce resolvecolorspace
- % Contrary to PDF manuals up to v.1.5, Acrobat Distiller 3.01
- % can use /Identity name here instead of a function.
- exch oforce resolveidfnproc
- 4 array astore
- }
- /DeviceN {
- [ exch aload pop ] % Copy into a new array
- dup dup 1 oget % Resolve Names array
- [ exch { oforce } forall ] % resolve each of the names
- 1 exch put
- dup dup 2 oget resolvecolorspace
- 2 exch put
- dup dup 3 oget resolvefnproc
- 3 exch put
- dup length 4 gt { % Check for attributes dict
- dup dup 4 oget % devn_array devn_array attr_dict
- dup /Colorants knownoget % Check for Colorants Dict
- { % Create a new attribute dict with only a Colorants dict entry.
- % Resolve all of the Colorant dict entries. This is needed
- % to prevent a conflict if we attempt to resolve the tint
- % transform functions of the Colorant color spaces multiple
- % times.
- exch pop % Remove old attributes dict
- << exch % Start new attributes dict
- % Build new Colorants dict with resolved entries
- << exch { oforce resolvecolorspace } forall >>
- /Colorants exch >> % Finish new attributes dict
- } if
- 4 exch put % Put resolved or new attributes dict
- } if
- }
- /Indexed {
- aload pop 3 -1 roll oforce resolvecolorspace
- % Stack: /Indexed hival lookup basespace
- % If the underlying space is a Lab space, we must scale
- % the output of the lookup table as part of DecodeABC.
- dup dup type /arraytype eq { 0 get } if /CIEBasedABC eq {
- dup 1 get /DecodeLMN known {
- 1 get dup length dict copy
- begin /DecodeABC [ 0 2 4 {
- RangeABC 1 index 1 add get RangeABC 2 index get sub /mul load
- RangeABC 3 index get /add load
- DecodeABC 6 -1 roll 2 idiv get [ 6 1 roll aload pop ] cvx
- } for ] def
- /RangeABC //01_3 def
- currentdict end /CIEBasedABC exch 2 array astore
- } if
- } if
- 3 1 roll
- oforce dup type /stringtype ne {
- % The color lookup table is a stream.
- % Get its contents. Don't lose our place in PDFfile.
- % Stack: /Indexed basespace hival lookup
- PDFfile fileposition 5 1 roll true resolvestream
- % Stack: filepos /Indexed basespace hival lookupstream
- 1 index 1 add
- % Stack: filepos /Indexed basespace hival lookupstream len
- 3 index
- dup dup type /arraytype eq { 0 get } if
- //csncompdict exch get exec mul
- string dup 3 1 roll readstring pop % the string is padded with 0s
- length 1 index length lt {
- ( **** Warning: Short look-up table in the Indexed color space was padded with 0's.\n)
- pdfformaterror
- } if
- % Stack: filepos /Indexed basespace hival table table'
- 5 -1 roll PDFfile exch setfileposition
- }
- if 4 array astore
- % Replace the PDFColorSpace with the Indexed space if needed.
- dup 1 get
- dup type /arraytype eq {
- dup length 2 ge {
- dup 1 get type /dicttype eq {
- dup 1 get /PDFColorSpace known {
- dup 1 get /PDFColorSpace 3 index put
- } if
- } if
- } if
- } if pop
- }
- /Pattern {
- dup type /nametype ne {
- dup length 1 gt {
- 1 oget resolvecolorspace
- /Pattern exch 2 array astore
- } if
- } if
- }
-.dicttomark readonly def
-
-/cssubst { % <csname> cssubst <cspace'> true
- % <csname> cssubst false
- dup resolvecolorspace
- dup 1 index ne { exch pop true } { pop pop false } ifelse
-} bdef
-
-/csnames mark
- /DeviceGray dup /DeviceRGB dup /DeviceCMYK dup /Pattern dup
-.dicttomark readonly def
-/csresolve { % <csresourcename> csresolve <cspace>
- dup type /nametype ne {
- (\n **** Warning: CS/cs (setcolorspace) operand not a name: ) pdfformaterror
- dup stderrfile dup 3 -1 roll write==only flushfile
- ( ****\n) pdfformaterror
- dup type /arraytype eq { % Adobe InDesign + PDF Library has array
- resolvecolorspace
- } if
- } {
- dup Page /ColorSpace rget {
- exch pop resolvecolorspace
- } {
- //csnames 1 index known not { /undefined cvx signalerror } if
- } ifelse
- } ifelse
-} bdef
-/resolvecolorspace { % <cspace> resolvecolorspace <cspace'>
- dup dup type /arraytype eq { 0 get } if
- //csrdict exch .knownget
- {
- exec dup type /nametype ne { dup length 1 eq { 0 get } if } if
- } {
- dup type /nametype eq { csresolve } { csset exch pop } ifelse
- } ifelse
-} bdef
-
-/scresolve { % <c0> ... scresolve <multi>
- % We can't really make sc[n] and SC[N] work, because
- % the color space information isn't available at
- % conversion time; so we hack it by assuming that
- % all the operands on the stack are used, and that
- % if the top operand is a name, it's a Pattern resource.
- dup type /nametype eq
- { Page /Pattern rget { resolvepattern } { null } ifelse }
- if
- dup type /dicttype eq {
- % Check the PaintType, if any (shading patterns don't
- % have one).
- dup /PaintType knownoget { 2 eq } { false } ifelse
- } {
- .pdfcount 1 gt
- } ifelse
-} bdef
-
-/.pdfpaintproc { % <patdict> <resdict> .pdfpaintproc -
- PDFDEBUG { pdfdict /PDFSTEPcount .knownget { 1 le } { true } ifelse { (%Begin PaintProc) print dup === flush } if } if
- % For uncolored patterns, we have to unbind the current
- % color and color space before running the PaintProc.
- % There's no harm in doing this for colored patterns,
- % so for simplicity, we always do it.
- PDFfile fileposition 3 1 roll
- q
- //null sc1 //null SC1
-
- % save old value of pdfemptycount on opstack, set to new value
- pdfemptycount /pdfemptycount count 3 sub def 3 1 roll
- countdictstack 3 1 roll
-
- exch //false resolvestream pdfopdict .pdfruncontext
-
- countdictstack exch sub dup 0 gt {
- ( **** Warning: Pattern stream has imbalanced q/Q operators (too many q's)\n)
- pdfformaterror
- { Q } repeat
- } {
- pop
- } ifelse
-
- % restore pdfemptycount
- /pdfemptycount exch def
-
- Q
- PDFDEBUG { pdfdict /PDFSTEPcount .knownget { 1 le } { //true } ifelse { (%End PaintProc) print dup === flush } if } if
- PDFfile exch setfileposition
-} bdef
-
-/resolvepattern { % <patternstreamdict> resolvepattern <patterndict>
- % Don't do the resolvestream now: just capture the data
- % from the file if necessary.
- dup length dict copy
- dup /FilePosition .knownget {
- 1 index /File get dup fileposition 3 1 roll
- % Stack: dict savepos pos file
- dup 3 -1 roll setfileposition
- dup 3 index /Length oget
-
- dup 65535 le {
- dup 0 eq {
- pop pop ()
- } {
- string readstring pop
- } ifelse
- } {
- () /SubFileDecode filter /ReusableStreamDecode filter
- } ifelse
- % Stack: dict savepos file string
- 3 1 roll exch setfileposition
- 1 index /File 3 -1 roll put
- dup /FilePosition undef
- } if
- dup /Shading knownoget {
- resolveshading 1 index /Shading 3 -1 roll put
- } if
- dup /PaintProc [
- % Bind the resource dictionary into the PaintProc.
- 2 index /Resources knownoget { oforce } { 0 dict } ifelse
- /.pdfpaintproc cvx
- ] cvx put
- PDFDEBUG { pdfdict /PDFSTEPcount .knownget { 1 le } { true } ifelse { (%Pattern: ) print dup === flush } if } if
-} bdef
-
-/ignore_color_op ( **** Warning: Ignoring a color operation in a cached context.\n) readonly def
-
-drawopdict begin
- /g { .incachedevice { % Bug 689302
- pop //ignore_color_op pdfformaterror
- } {
- /DeviceGray cssubst { cs sc1 } { g } ifelse
- } ifelse
- } bdef
-
- /rg { .incachedevice {
- pop pop pop //ignore_color_op pdfformaterror
- } {
- /DeviceRGB cssubst { cs sc* } { rg } ifelse
- } ifelse
- } bdef
-
- /k { .incachedevice {
- pop pop pop pop //ignore_color_op pdfformaterror
- } {
- k
- } ifelse
- } bdef
-
- /cs { .incachedevice {
- pop //ignore_color_op pdfformaterror
- } {
- csresolve cs
- } ifelse
- } bdef
-
- /sc { .incachedevice {
- .pdfcount { pop } repeat //ignore_color_op pdfformaterror
- } {
- scresolve { sc* } { sc1 } ifelse
- } ifelse
- } bdef
-
- /scn /sc load def
-
- /G { .incachedevice {
- pop //ignore_color_op pdfformaterror
- } {
- /DeviceGray cssubst { CS SC1 } { G } ifelse
- } ifelse
- } bdef
-
- /RG { .incachedevice {
- pop pop pop //ignore_color_op pdfformaterror
- } {
- /DeviceRGB cssubst { CS SC* } { RG } ifelse
- } ifelse
- } bdef
-
- /K { .incachedevice {
- pop pop pop pop //ignore_color_op pdfformaterror
- } {
- K
- } ifelse
- } bdef
-
- /CS { .incachedevice {
- pop //ignore_color_op pdfformaterror
- } {
- csresolve CS
- } ifelse
- } bdef
-
- /ri { .incachedevice {
- pop //ignore_color_op pdfformaterror
- } {
- ri
- } ifelse
- } bdef
-
- /SC { .incachedevice {
- .pdfcount { pop } repeat //ignore_color_op pdfformaterror
- } {
- scresolve { SC* } { SC1 } ifelse
- } ifelse
- } bdef
-
- /SCN /SC load def
-end
-
-currentdict /ignore_color_op undef
-
-% ---------------- Paths ---------------- %
-
-drawopdict begin
- % Path construction
- /m /moveto load def
- /l /lineto load def
- /c /curveto load def
- /v { currentpoint 6 2 roll curveto } def
- /y { 2 copy curveto } def
- /re {
- 4 2 roll moveto exch dup 0 rlineto 0 3 -1 roll rlineto neg 0 rlineto
- closepath
- } def
- /h /closepath load def
- % Path painting and clipping
- /n { n } def
- /S { S } def
- /s { s } def
- /f { f } def
- /f* { f* } def
- /B { B } def
- /b { b } def
- /B* { B* } def
- /b* { b* } def
- /W { W } def
- /W* { W* } def
- /sh { setfillstate resolvesh
- gsave 0 .setoverprintmode
- dup /.shading .knownget {
- exch
- pop
- } {
- dup
- .buildshading
- dup 3 1 roll /.shading exch put
- } ifelse
- .shfill grestore
- } def
-end
-
-% ---------------- XObjects ---------------- %
-
-/xobjectprocs mark % <dict> -proc- -
- /Image { DoImage }
- /Form { DoForm }
- /PS { DoPS }
-.dicttomark readonly def
-
-% Note that the keys in defaultdecodedict are resolved (PostScript, not PDF)
-% color space names.
-/defaultdecodedict mark
- /DeviceGray { pop //01_1 } bind
- /DeviceRGB { pop //01_3 } bind
- /DeviceCMYK { pop //01_4 } bind
- /CIEBasedA { 1 get /RangeA knownoget not { //01_1 } if } bind
- /CIEBasedABC { 1 get /RangeABC knownoget not { //01_3 } if } bind
- /ICCBased {
- 1 oget dup /Range knownoget {
- exch pop
- }{
- /N get [ exch {0 1} repeat ] readonly
- } ifelse
- } bind
- /Separation { pop //01_1 } bind
- /DeviceN {
- 1 oget length [ exch {0 1} repeat ] readonly
- } bind
- /Indexed {
- pop [ 0 1 BitsPerComponent bitshift 1 sub ]
- } bind
-.dicttomark readonly def
-
-/checkaltimage { % <resdict> checkaltimage <resdict[']>
- Printed {
- dup /Alternates knownoget {
- {
- dup /DefaultForPrinting knownoget {
- {
- /Image oget exch pop exit
- } {
- pop
- } ifelse
- } {
- pop
- } ifelse
- } forall
- } if
- } if
-} bdef
-
-/makeimagedict { % <resdict> <newdict> makeimagedict <imagemask>
- % On return, newdict' is currentdict
- begin
- /Width 2 copy oget def
- /Height 2 copy oget def
- % Handle missing BitsPerComponent later.
- /BitsPerComponent 2 copy knownoget { def } { pop } ifelse
- /Interpolate 2 copy knownoget { def } { pop } ifelse
- makeimagekeys
-} bdef
-/makeimagekeys { % <resdict> makeimagekeys <imagemask>
- % newdict is currentdict
- % Assumes Width, Height, BPC, Interpolate already copied.
- /ImageType 1 def
- /ImageMatrix Width 0 0
- % Handle 0-height images specially.
- Height dup 0 eq { pop 1 } if neg 0 1 index neg
- 6 array astore def
- dup /ImageMask knownoget dup { and } if {
- % Image mask
- % Decode is required for the PostScript image operators.
- % AI8 writes bogus decode array [0 1 0 0 0 0 0 0]
- /Decode 2 copy knownoget { 0 2 getinterval } { //01_1 } ifelse def
- % BitsPerComponent is optional for masks.
- /BitsPerComponent 2 copy known { pop } { 1 def } ifelse
- true
- } {
- % Opaque image
- dup /ColorSpace oget resolvecolorspace /ColorSpace exch def
- % Decode is required for the PostScript image operators.
- /Decode 2 copy knownoget not {
- ColorSpace //defaultdecodedict
- ColorSpace dup type /arraytype eq { 0 get } if get exec
- } if def
- false
- } ifelse
- % Even though we're going to read data,
- % pass false to resolvestream so that
- % it doesn't try to use Length (which may not be present).
- exch false resolvestream /DataSource exch def
-} bdef
-
-/DoImage {
- checkaltimage dup length 6 add dict
- 1 index /SMask knownoget { 1 index exch /SMask exch put } if
- 1 index /Mask knownoget { 1 index exch /Mask exch put } if
- makeimagedict doimagesmask
-} bdef
-/makemaskimage { % <datasource> <imagemask> <Mask> makemaskimage
- % <datasource> <imagemask>, updates currentdict =
- % imagedict
- dup type /arraytype eq {
- /ImageType 4 def
- % Check that every element of the Mask is an integer.
- //false 1 index {
- type /integertype ne or
- } forall {
- (\n **** Warning: Some elements of Mask array are not integers.\n)
- pdfformaterror
- [ exch { 0.5 add cvi } forall ] % following AR4, 5, 6 implementation
- } if
- % Check elements of array are within 0::(2**BitsPerComponent)-1
- % This is a PostScript error, but AR ignores Mask in that case
- 1 BitsPerComponent bitshift 1 sub //false 2 index {
- % stack: max_value result_bool value
- dup 0 lt exch 3 index gt or or
- } forall exch pop {
- (\n **** Warning: Some elements of Mask array are out of range.\n)
- pdfformaterror
- [ exch { 0 .max 1 BitsPerComponent bitshift 1 sub .min } forall ]
- } if
- /MaskColor exch def
- } {
- % Mask is a stream, another Image XObject.
- % Stack: datasource imagemask(false) maskstreamdict
- PDFfile fileposition exch
- dup length dict makeimagedict pop
- % In order to prevent the two data sources from being
- % aliased, we need to make at least one a reusable stream.
- % We pick the mask, since it's smaller (in case we need to
- % read all its data now).
- % Stack: datasource imagemask(false) savedpos
- % maskdict is currentdict
- /DataSource DataSource mark
- /Intent 1
- /AsyncRead true
- .dicttomark .reusablestreamdecode def
- PDFfile exch setfileposition
- currentdict end currentdict end
- 5 dict begin
- /ImageType 3 def
- /InterleaveType 3 def
- /DataDict exch def
- /MaskDict exch def
- /ColorSpace DataDict /ColorSpace get def
- } ifelse
-} bdef
-
-/doimagesmask { % <imagemask> doimagesmask -
- PDFusingtransparency { currentdict /SMask knownoget } { false } ifelse {
- .begintransparencymaskimage
- PDFfile fileposition exch
- gsave //nodict begin
- null /SoftMask gput
- 1 .setopacityalpha 1 .setshapealpha
- /Compatible .setblendmode
- DoImage
- end grestore
- PDFfile exch setfileposition
- 0 .endtransparencymask
- << /Subtype /Group /Isolated true
- /.image_with_SMask true % pdfwrite needs : see gs/src/ztrans.c, gs/src/gdevpdft.c
- >> 0 0 1 1 .begintransparencygroup
- doimage
- .endtransparencygroup
- } {
- doimage
- } ifelse
-} bdef
-/doimage { % <imagemask> doimage -
- % imagedict is currentdict, gets popped from dstack
- DataSource exch
- PDFusingtransparency {
- currentdict /SMask knownoget
- } {
- false
- } ifelse {
- makesoftmaskimage
- } {
- currentdict /Mask knownoget {
- makemaskimage
- } if
- } ifelse
- % Stack: datasource imagemask
- { currentdict end setfillstate { imagemask } }
- { ColorSpace setgcolorspace currentdict end setfillblend { image } }
- ifelse
- stopped {
- dup type /dicttype eq { pop } if % Sometimes image fails to restore the stack
- $error /errorname get dup /ioerror eq {
- pop (\n **** Warning: File has insufficient data for an image.\n)
- pdfformaterror
- } {
- (\n **** Warning: File encountered ')
- exch 40 string cvs concatstrings
- (' error while processing an image.\n) concatstrings
- pdfformaterror
- } ifelse
- } if
- % Close the input stream, unless it is PDFfile or
- % PDFsource.
- dup dup PDFfile eq exch PDFsource eq or { pop } { closefile } ifelse
-} bdef
-
-/.paintform { % <formdict> <resdict> <stream> .paintform -
- 3 -1 roll dup /Group known PDFusingtransparency and {
- .paintgroupform
- } {
- pop pdfopdict .pdfruncontext
- } ifelse
-} bdef
-
-/DoForm {
- % Adobe 2nd edition of the PDF 1.3 spec makes /FormType
- % and /Matrix keys optional. Cope with the missing keys.
- begin <<
- currentdict /FormType known not { /FormType 1 } if
- currentdict /Matrix known not { /Matrix { 1 0 0 1 0 0 } cvlit } if
- currentdict end { oforce } forall
- >>
- dup [ 2 index /Resources knownoget { oforce } { 0 dict } ifelse
- 3 index false /resolvestream cvx
- /.paintform cvx
- ] cvx /PaintProc exch put
- % Adjust pdfemptycount since we have an extra dictionary on the stack
- pdfemptycount exch
- /pdfemptycount where pop count 2 sub /pdfemptycount exch put
- q execform Q % gsave / grestore around the Form
- % Restore pdfemptycount
- /pdfemptycount where pop exch /pdfemptycount exch put
-} bdef
-
-/_dops_save 1 array def
-
-/DoPS {
- DOPS
- {
- //_dops_save 0 save put
- true resolvestream cvx exec
- //_dops_save 0 get restore
- }
- { pop }
- ifelse
-} bdef
-
-currentdict /_dops_save undef
-
-drawopdict begin
- /Do {
- setfillblend
- PDFfile fileposition exch
- dup Page /XObject rget {
- exch pop dup /Subtype get xobjectprocs exch get
- % Don't leave extra objects on the stack while executing
- % the definition of the form.
- 3 -1 roll 2 .execn
- } {
- % This should cause an error, but Acrobat Reader can
- % continue, so we do too.
- ( **** Undefined XObject resource: )
- exch =string cvs concatstrings (\n) concatstrings
- pdfformaterror
- } ifelse
- PDFfile exch setfileposition
- } bdef
-end
-
-% ---------------- In-line images ---------------- %
-
-% Undo the abbreviations in an in-line image dictionary.
-% Note that we must look inside array values.
-% /I is context-dependent.
-/unabbrevkeydict mark
- /BPC /BitsPerComponent /CS /ColorSpace /D /Decode /DP /DecodeParms
- /F /Filter /H /Height /I /Interpolate /IM /ImageMask /W /Width
-.dicttomark readonly def
-/unabbrevvaluedict mark
- /AHx /ASCIIHexDecode /A85 /ASCII85Decode /CC /CalCMYK
- /CCF /CCITTFaxDecode /CG /CalGray /CR /CalRGB
- /DCT /DCTDecode /CMYK /DeviceCMYK /Fl /FlateDecode
- /G /DeviceGray /RGB /DeviceRGB
- /I /Indexed /LZW /LZWDecode /RL /RunLengthDecode
-.dicttomark readonly def
-/unabbrevtypedict mark
- /nametype {
- //unabbrevvaluedict 1 index .knownget { exch pop } if
- }
- /arraytype {
- dup 0 1 2 index length 1 sub {
- 2 copy get unabbrevvalue put dup
- } for pop
- }
-.dicttomark readonly def
-/unabbrevvalue { % <obj> unabbrevvalue <obj'>
- oforce //unabbrevtypedict 1 index type .knownget { exec } if
-} bdef
-
-drawopdict begin
- /BI { mark } bdef
- /ID {
- counttomark 2 idiv dup 7 add dict begin {
- exch //unabbrevkeydict 1 index .knownget { exch pop } if
- exch unabbrevvalue def
- } repeat pop
- /IDFlag true def % flag for stream processing.
- /File PDFsource def
- currentdict makeimagekeys doimage
- % The Adobe documentation says that the data following ID
- % consists of "lines", and some PDF files (specifically, some files
- % produced by PCL2PDF from Visual Software) contain garbage bytes
- % between the last byte of valid data and an EOL.
- % Some files (PDFOUT v3.8d by GenText) have EI immediately following
- % the stream. Some have no EOL and garbage bytes.
- % Therefore, we skip all bytes before EI or EOL
- 0
- { PDFsource read not { //true exit } if
- dup 10 eq 1 index 13 eq or
- { pop PDFsource token pop /EI ne exit
- }
- if
- exch 69 eq 1 index 73 eq and { //false exit } if % 'EI'
- }
- loop
- exch pop
- { /ID cvx /syntaxerror signalerror
- }
- if
- } bdef
-end
-
-% ================================ Text ================================ %
-
-drawopdict begin
- % Text control
- /BT { BT } def
- /ET { ET } def
- /Tc { Tc } def
- /TL { TL } def
- /Tr { Tr } def
- /Ts { Ts } def
- /Tw { Tw } def
- /Tz { Tz } def
- % Text positioning
- /Td { Td } def
- /TD { TD } def
- /Tm { Tm } def
- /T* { T* } def
- % Text painting
- /Tj { Tj } def
- /' { ' } def
- /" { " } def
- /TJ { TJ } def
-
- /Tform { Tform } def % Text formatting and painting for AcroForm
- % without appearance streams.
-end
-
-% ============================== Annotations ============================== %
-
-
-
-% Get and normalize an annotation's rectangle.
-/annotrect { % <annot> annotrect <x> <y> <w> <h>
- /Rect get aload pop
- exch 3 index sub dup 0 lt { dup 5 -1 roll add 4 1 roll neg } if
- exch 2 index sub dup 0 lt { dup 4 -1 roll add 3 1 roll neg } if
-} bdef
-
-% Set an annotation color.
-/annotsetcolor { % <annot> annotsetcolor -
- /C knownoget { aload pop setrgbcolor } { 0 setgray } ifelse
-} bdef
-
-% Draw the border. Currently, we ignore requests for beveling, and we
-% don't round the corners of rectangles.
-/strokeborder { % <annot> <width> <dash> strokeborder -
- 1 index 0 ne { % do not draw if border width is 0
- gsave
- 2 index annotsetcolor
- 0 setdash dup setlinewidth
- exch annotrect
- 2 { 4 index sub 4 1 roll } repeat
- 2 { 4 index 0.5 mul add 4 1 roll } repeat
- rectstroke pop
- grestore
- } {
- pop pop pop
- } ifelse
-} bdef
-
-% Draw an annotation border.
-/drawborder { % <annot> drawborder -
- gsave
- dup /BS known 1 index /Border known or {
- dup /BS knownoget {
- dup type /dicttype ne % <annot> <border> <bad?>
- } {
- dup /Border oget
- dup type /arraytype ne % <annot> [border] <bad?>
- } ifelse
- {
- ( **** Warning: Wrong type of annotation border object.\n)
- pdfformaterror
- } if
- dup type /dicttype eq {
- dup /W knownoget not { 1 } if
- % Per PDF1.6 Reference table 8.13, /W in the border style dictionary is
- % expressed in points (an absolute unit), so compensate here for any
- % scaling of the PostScript user space done due to /UserUnit.
- % Scaling due to -dPDFFitPage is not undone, to keep the correct border width
- % compared to the size of the surrounding marks.
- //systemdict /NoUserUnit .knownget not { false } if not
- //systemdict /PDFFitPage known not and { % UserUnit is ignored if -dPDFFitPage
- Page /UserUnit knownoget { div } if
- } if
- [] 2 index /S knownoget {
- /D eq { 2 index /D knownoget not { [3] } if exch pop } if
- } if 3 -1 roll pop strokeborder
- } {
- dup 2 get
- exch dup length 3 gt { 3 get } { pop [] } ifelse
- strokeborder
- } ifelse
- } {
- 1 [] strokeborder
- } ifelse
- grestore
-} bdef
-
-%
-% The PDF annotation F (flags) integer is bit encoded.
-% Bit 1 (LSB) Invisible: 1 --> Do not display if no handler.
-% Note: We have no handlers but we ignore this bit.
-% Bit 2 Hidden: 1 --> Do not display. We will not display if this bit is set.
-% Bit 3 Print: 1 --> Display if printing. We will display if this bit set
-% (and not hidden) and Printed is true
-% Bit 4 NoZoom: 1 --> Do not zoom annotation even if image is zoomed.
-% Bit 5 NoRotate: 1 --> Do not rotate annotation even if image is rotated.
-% Bit 6 NoView: 0 --> Display if this is a 'viewer'. We will display
-% if this bit is not set (and not hidden) and Printed is false
-% Bit 7 Read Only - 1 --> No interaction. We ignore this bit
-%
-/annotvisible { % <annot> annotvisible <visible>
- /F knownoget not { 0 } if % Get flag value
- dup 2 and 0 eq % Check hidden flag
- exch dup 4 and 0 ne Printed and % Check print flag
- exch 32 and 0 eq Printed not and % Check noview flag
- or % Combine print and view
- and % Combine with 'hidden' flag test
-} bdef
-
-/drawwidget { % <scalefactor> <annot> drawwidget -
- dup /AP knownoget {
- dup /N known not {
- ( **** Appearance dictionary (AP) lacks the mandatory normal (N) appearance.\n)
- pdfformaterror
- } if
- false
- [/N /R /D] {
- % stack: scale annot appearance false key
- dup 3 index exch known {
- exch pop true exit
- } if
- pop
- } forall
- % stack: scale annot appearance key true
- % stack: scale annot appearance false
- dup {
- pop
- oget
- % Acrobat Distiller produces files in which this Form
- % XObject lacks Type and Subtype keys. This is illegal,
- % but Acrobat Reader accepts it. The only way we can
- % tell whether this is a Form or a set of sub-appearances
- % is by testing for the stream Length or File key.
- % If the stream lacks Length key, try File key.
- dup /Length known 1 index /File known or {
- % If this is a form then simply use it
- true
- } {
- 1 index /AS knownoget not {
- % If we do not have AS then use any appearance
- { exch pop oforce exit } forall true
- } {
- % Stack: annot Ndict AS
- % Get the specified appearance. If no appearance, then
- % display nothing - set stack = false.
- knownoget
- } ifelse
- } ifelse
- } {
- exch pop % discard useless AP dictionary
- } ifelse
-
- % Stack: scale annot appearance true
- % Stack: scale annot false
- {
- % Draw appearance
- % Initialize graphic following "7.4.4 Appearance Streams"
- q graphicsbeginpage textbeginpage
- 1 index annotrect pop pop translate
- 2 index dup scale % Apply scale factor
- DoForm Q
- } if
- } {
- dup /FT knownoget {
- /Tx eq {
- % Stack: scale annot
- dup /DA known 1 index /V known and {
- dup /DA oget
- q graphicsbeginpage textbeginpage
- 1 index annotrect pop pop translate
- 2 index dup scale % Apply scale factor
- cvx exec
- dup /V oget
- 0 0 moveto dup false charpath pathbbox newpath 3 -1 roll
- sub abs 3 1 roll sub abs
- 3 index annotrect 4 2 roll pop pop
- 6 index mul exch 6 index mul
- % stack: scale annot V vsize hsize vrect hrect
- % Calculate horizontal justification first
- % horizontal can be left (Q=0), center (Q=1), or right (Q=2) justification
- 3 -1 roll
- % stack: scale annot V vsize vrect hrect hsize
- 5 index /Q knownoget not { 0 } if % default 0 == left
- dup 0 eq {
- pop pop pop 0 % left justified
- } {
- 1 eq {
- 2 div exch 2 div exch sub % centered
- } {
- sub % right justified (hrect - hsize)
- } ifelse
- } ifelse
- % stack: scale annot V vsize vrect hoffset
- % Center the text vertically in the rect (Acrobat Reader seems to do this)
- 3 1 roll 2 div exch 2 div sub abs
- % stack: scale annot V hoffset voffset
- moveto show
- Q
- } if
- } if
- } if
- } ifelse
- pop pop
-} bdef
-
-% For stamp object we have to determine the size of the output rectangle
-% and the size of the BBox for the stamp image. From these we calculate
-% a scale factor for drawing the stamp.
-/calcstampscale { % <annot> calcstampscale scale
- dup /Rect known {
- dup annotrect 4 -2 roll pop pop % get width height size in user space
- 3 -1 roll /AP knownoget {
- /N knownoget {
- dup /Matrix knownoget {
- % transform /Annot /Rect xwidth to Form space
- 4 -2 roll 3 -1 roll dtransform 3 -1 roll
- } if
- /BBox knownoget {
- exch pop % discard y height
- aload pop pop exch pop sub % BBox width
- dup 0 eq {
- ( **** Warning: /BBox has zero width which is not allowed.\n)
- pdfformaterror
- pop pop 1 1 % 0 width -- revert to unity scaling
- } if
- div % scale x widths
- dup 0 lt { neg } if % get magnitude
- } {
- pop pop 1 % default to unity scaling
- } ifelse % if we have /BBox
- } {
- pop pop 1
- } ifelse % if we have /N
- } {
- pop pop 1
- } ifelse % if we have /AP
- } {
- ( **** Warning: /Annot dict is missing required /Rect entry.\n)
- pdfformaterror
- pop 1
- } ifelse
-} bdef
-
-/drawlink { % <annot> drawlink -
- dup drawborder dup calcstampscale exch drawwidget
-} bdef
-
-% Draw an annotation.
-/drawannottypes mark
- /Link { drawlink } bind
-.dicttomark readonly def
-/drawannot { % <annot> drawannot -
- dup annotvisible {
- gsave
- dup dup /Subtype knownoget {
- //drawannottypes exch .knownget {
- exec
- } {
- dup calcstampscale exch drawwidget % Use drawwidget for everything else
- } ifelse % type known
- } {
- pop
- ( **** Warning: /Annot dict without required /Subtype entry is ignored.\n)
- pdfformaterror
- } ifelse
- grestore
- } if pop % annotvisible
-} bdef
-currentdict /drawannottypes undef
-
-% ============================ AcroForm fields ============================ %
-
-% Get an attribure of the 0th annotation of a node
-/annot_oget { % <annot> /Name annot_oget <value>
- 1 index /Kids knownoget {
- 0 oget exch oget exch pop
- } {
- oget
- } ifelse
-} bdef
-
-% All procedures have the signature:
-% <acroform> <field> <annot|field> foo <acroform> <field> <annot|field>
-/draw_terminal_field_dict 4 dict begin
-
-/Btn {
- 1 index /Tf pget not { 0 } if
- dup 16#20000 and 0 ne {
- pop % Push button
- dup /AP known {
- dup 1 exch drawwidget
- } {
- (Push button without appearance stream is not yet implemented) =
- } ifelse
- } {
- 16#10000 and 0 ne {
- % Radio button
- dup /AP known {
- 1 index /Kids oget {
- 1 exch drawwidget
- } forall
- } {
- (Radio button without appearance stream is not yet implemented) =
- } ifelse
- } {
- % Checkbox
- dup /AP known {
- dup 1 exch drawwidget
- } {
- (CkeckBox without appearance stream is not yet implemented) =
- } ifelse
- } ifelse
- } ifelse
-} bdef
-
-/Tx {
- dup /AP known {
- dup 1 exch drawwidget
- } {
- 2 index /NeedAppearances knownoget not { //false } if {
- dup /AP << /N 10 dict dup cvx begin >> put
- /Subtype /Form def
- /BBox [ 0 0 4 index /Rect oget { oforce } forall 3 -1 roll sub abs 3 1 roll sub abs exch ] def
- /Resources 3 index /DR pget not { 0 dict } if def
- /File 1000 string dup 3 1 roll def
- /Length 0 def
- % <acroform> <field> <annot> (string)
- /NullEncode filter % <acroform> <field> <annot> file
-
- dup (BT ) writestring
- 2 index /DA pget not { () } if
- [ exch
- { token {
- dup /Tf eq {
- 2 index 0 eq {
- /BBox load 3 get
- 0.75 mul % empirical constant
- 4 -1 roll pop 3 1 roll
- } if
- } if
- exch
- } {
- exit
- } ifelse
- } loop
- ]
- { 1 index exch write== } forall
- dup 3 index /MaxLen pget not { 0 } if write=
- dup 3 index /V pget not { () } if write==
- dup 3 index /Ff pget not { 0 } if write=
- dup 3 index /Q pget not { 0 } if write=
- dup (Tform ET) write=
- end
- closefile % <acroform> <field> <annot>
- dup 1 exch drawwidget
- } if
- } ifelse
-} bdef
-
-/Ch {
- (Ch is not yet implemened) ==
-} bdef
-
-/Sig {
- (Sig is not yet implemened ) ==
-} bdef
-
-currentdict end def
-
-/draw_terminal_field { % <field> draw_terminal_field -
- dup /Kids knownoget { 0 oget } { dup } ifelse
- dup /P knownoget {
- /Page load eq {
- //draw_terminal_field_dict 2 index /FT pget not { 0 } if .knownget {
- exec
- } if
- } if
- } if
- pop pop
-} bdef
-
-% We distinguish 4 types of nodes on the form field tree:
-% - non-terminal field - has a kid that refers to the parent (or anywhere else)
-% - terminal field with separate widget annotations - has a kid that doesn't have a parent
-% - terminal field with a merged widget annotation - has no kids
-% - widget annotation - has /Subtype and /Rect
-%
-% The recursive enumeration of the form fields doesn't descend into widget annotations.
-
-/draw_form_field { % <field> draw_form_field -
- dup /Kids knownoget { % field []
- dup 0 oget /Parent knownoget { % field [] kid
- pop % mon-terminal field % field []
- exch pop % []
- { oforce draw_form_field } forall
- } {
- pop draw_terminal_field % separate annots % -
- } ifelse
- } {
- draw_terminal_field % merged annotation % -
- } ifelse
-} bdef
-
-/draw_acro_form { % <form> draw_acro_form -
- dup /Fields knownoget {
- { oforce draw_form_field } forall
- } if
- pop
-} bdef
-
-currentdict /draw_terminal_field_dict undef
-
-end % pdfdict
-end % GS_PDF_ProcSet
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/pdf_font.ps b/Master/tlpkg/tlgs/lib/pdf_font.ps deleted file mode 100644 index 132c318f1e9..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf_font.ps +++ /dev/null @@ -1,1607 +0,0 @@ -% Copyright (C) 1994, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdf_font.ps 8509 2008-01-28 10:31:45Z mpsuzuki $
-% PDF font operations.
-
-% Finding a font by name can't give a proper result when PDF font names aren't unique.
-% But it is only the way to obtain a font in Postscript after a font file is executed.
-% Therefore using a FontName (and findfont) is allowed only
-% immediately after a font file is executed.
-% In all other cases the font to be found by a pointer through PDF structures.
-%
-% This ideal logics can't work for documents,
-% which define a font resource with an embedded font,
-% and another font resource with same BaseFont but with no embedded font
-% (and possibly with no font descriptor).
-% Our testbase does contain such examples.
-% In this case we do find font by FontName (with findfont),
-% since there is no other way to get a reasonable result.
-
-/.setlanguagelevel where { pop 2 .setlanguagelevel } if
-.currentglobal true .setglobal
-/pdfdict where { pop } { /pdfdict 100 dict def } ifelse
-GS_PDF_ProcSet begin
-pdfdict begin
-
-% We cache the PostScript font in an additional element of the
-% font resource dictionary, called PSFont.
-
-% ---------------- Encodings ---------------- %
-
-/.notdefEncoding 256 { /.notdef } repeat 256 packedarray def
-
-% Apply a list of differences to an Encoding.
-% Note that the differences may cause the array to grow.
-/updateencoding { % <encoding|null> <differences> updateencoding <enc'>
- % Calculate the length of the result.
- % in case the incoming Encoding is null, use .notdefEncoding
- exch dup null eq { pop .notdefEncoding } if
- 0 0 3 index {
- dup type /nametype ne { exch pop oforce } { pop 1 add } ifelse
- % Differences list may not be in order, update the largest_index
- % stack: <Differences> <encoding> <largest_index> <at_index>
- 2 copy lt { exch pop dup } if % at_index is new largest
- } forall
- pop 1 index length .max array dup 0 4 -1 roll putinterval
- exch 0 exch {
- % Stack: enc' code element
- dup type /nametype ne
- { exch pop oforce }
- { 3 copy put pop 1 add }
- ifelse
- } forall pop
-} bdef
-
-% Get the Encoding for a font.
-/getencoding % <base-encoding> <font-resource> getencoding <enc>
- { /Encoding knownoget
- { dup type /nametype eq
- {
- % The published PDF specification says the Encoding name
- % "must be" one of the 3 predefined Encodings, implying
- % that an error should occur if it isn't. However, Acrobat
- % Reader simply ignores unknown names, and since there are
- % some buggy applications that rely on this, we do the same.
-
- dup dup dup /MacRomanEncoding eq
- exch /MacExpertEncoding eq or
- exch /WinAnsiEncoding eq or
- { exch pop findencoding }
- { pop }
- ifelse
- }
- { dup type /arraytype eq
- { exch pop
- ( **** Warning: Encoding is an array, not name or dictionary.\n) pdfformaterror
- }
- { dup /BaseEncoding knownoget
- { dup / eq
- { pop
- ( **** Warning: Ignoring bad BaseEncoding name.\n) pdfformaterror
- % as found in a PDF file from J.D.Edwards OneWorld (B7333), bug 687786
- }
- { findencoding 3 -1 roll pop exch }
- ifelse
- }
- if
- /Differences knownoget { updateencoding } if
- }
- ifelse
- }
- ifelse
- } {
- ( **** Warning: Encoding not present.\n) pdfformaterror
- }
- ifelse
- } bdef
-
-/checkGlyphNames2Unicode % <dict> checkGlyphNames2Unicode -
-{
- PDFDEBUG {
- dup /FontInfo .knownget {
- /GlyphNames2Unicode .knownget {
- (Has GlyphNames2Unicode) =
- pop % { exch == ==} forall
- } if
- } if
- } if
- pop
-} bind def
-
-% Define a font using it's FontName as the key.
-% Adjust a font according to the Encoding and Widths in the font resource.
-/adjustfont { % <font-resource> <font> adjustfont <font'>
- getfontencoding
- 3 copy .processToUnicode
- getfontmetrics 5 -1 roll pop .updatefont { dup /FontName get exch definefont } if
-} bind def
-
-% Get the (possibly modified) encoding of a font.
-/getfontencoding { % <font-resource> <font> getfontencoding
- % <font-resource> <font> <Encoding|null>
- //systemdict /IgnoreTTEncoding .knownget not { //false } if {
- 1 index /Subtype get /TrueType eq } { //false } ifelse {
- //null
- } {
- 1 index /Encoding known {
- dup /Encoding knownoget { 2 index getencoding } { //null } ifelse
- } {
- //null
- } ifelse
- } ifelse
-} bdef
-
-% Returns true if the current glyph is in the Differences array at
-% the specified index value. This is needed because the Widths
-% array may map to the same glyph at different positions from the
-% Encoding. We want to use the Width that was associated with the
-% one specified in the Encoding::Differences list.
-/match_in_diff % <Differences> <index> <glyphname> match_in_diff <bool>
-{ false 4 1 roll 0 4 -1 roll % stack: false index glyphname at_index==0 Differences
- { exch 1 index type /nametype ne {
- % stack: false index glyphname Diff_element at_index
- pop % Diff_element is new at_index
- } {
- % stack: false index glyphname Diff_element at_index
- exch 2 index eq {
- % stack: false index glyphname at_index
- dup 3 index eq {
- true 5 1 roll % stack: true false index glyphname at_index
- pop exit
- } if
- } if
- 1 add % at_index++ stack: false index glyphname at_index'
- } ifelse
- } forall
- % stack: true false index glyphname
- % or : false index glyphname at_index
- pop pop pop
-} bdef
-
-/unique_name { % <dict> </root> unique_name </unique>
- %
- % Note : this function interacts with pdf_write_encoding in src/gdevpdtw.c
- % and with copied_drop_extension_glyphs in src\gxfcopy.c
- % by adding a reserved substring (~GS~).
- %
- .namestring % <<>> (root)
- 0 1 65535 {
- 5 string cvs % <<>> (root) (0)
- (~GS~) exch concatstrings
- 1 index exch % <<>> (root) (root) (~GS~0)
- concatstrings % <<>> (root) (root~GS~0)
- dup % <<>> (root) (root~GS~0) (root~GS~0)
- 3 index exch % <<>> (root) (root~GS~0) <<>> (root~GS~0)
- known not {
- exch pop exit % <<>> (root~GS~0)
- } if
- pop
- } for
- exch pop cvn % /root0
-} bdef
-
-% Get the metrics of a font, if specified.
-/getfontmetrics { % <font-resource> <font> <Encoding|null> getfontmetrics
- % <font-resource> <font> <Encoding|null>
- % <Metrics|null> <GlyphMap|null>
-
- 2 index /Widths known {
- dup //null eq { pop dup /Encoding get } if
- 7 dict begin
- dup length dict
- /Metrics exch def
- /Encoding exch def
- /GlyphMap //null def
- exch
- dup /Widths oget /Widths exch def
- % Stack: font font-res
- % Note that widths are always based on a 1000-unit
- % character space, but the FontMatrix may specify
- % some other scale factor. Compensate for this here,
- % by scaling the Widths if necessary.
- 0.001 2 index /FontMatrix get 0 get
- dup 0 eq {
- % FontMatrix.xx == 0, so we cannot scale down by xx.
- % - FontMatrix[0] == 0 implies either FontMatrix[1] <> 0 or
- % FontMatrix cannot be inverted. In the 1st case we have
- % FontMatrixNonHV == true and will render text with cshow + xshow.
- % In the 2nd case, metrics in the PDF Font object cannot be enforced
- % [by altering metrics in PS glyph space].
- % HACK:
- % - we scale down by FontMatrix[1];
- % - given the format of Metrics entries we use, wy = 0 in glyph space;
- % - as a result, the cshow procedure receives as wy the value we
- % need for wx (all of this in PS user space).
- pop
- 2 index /FontMatrix get 1 get
- dup 0 eq { pop 1 } if % sorry, no way to enforce PDF metrics by altering the font
- } if
- div
- % Stack: font font-res mscale
- /FirstChar 2 index /FirstChar oget def
- /LastChar 2 index /LastChar oget def
-
- Encoding length LastChar le {
- ( **** Warning: Font Encoding array size is smaller than character range.\n)
- pdfformaterror
- } if
-
- 1 index /FontDescriptor knownoget {
- /MissingWidth knownoget not { 0 } if
- }
- { 1000
- }
- ifelse /MissingWidth exch def
-
- Widths length LastChar FirstChar sub le {
- ( **** Warning: Font Widths array size is smaller than character range.\n)
- pdfformaterror
- /Widths [Widths aload length LastChar FirstChar sub exch sub MissingWidth exch {dup} repeat] def
- } if
- FirstChar
-
- 0 Encoding
- { % Stack: font font-res mscale first-char index charname
-
- 1 index FirstChar lt { MissingWidth } {
- 1 index LastChar gt { MissingWidth } { Widths 2 index FirstChar sub get } ifelse
- } ifelse
-
- % Stack: font font-res mscale first-char index charname width
- 4 index mul
- % The following 'loop' is only context for 'exit'.
- {
- % Work around a bug in pdfTeX, which can generate Encoding
- % vectors containing nulls :
- 1 index //null eq { exit } if
- Metrics 2 index .knownget {
- 1 index ne
- } {
- //false
- } ifelse {
- % Two or more Encoding elements refer same glyph name,
- % and Widths specify different wihts for it.
- % Since a Postscript font can't have different
- % Metrics for same glyph name,
- % we generate an unique name, and create a new
- % Charstrings entry with same glyph value.
- GlyphMap //null eq {
- /Encoding Encoding dup length array copy def
- /GlyphMap 4 dict def
- } if
- % To prevent too many new names, check whether
- % we can use one already created for same glyph.
- //true
- GlyphMap { % f r s c i n w b n1 n2
- 4 index eq { % f r s c i n w b n1
- dup Metrics exch get % f r s c i n w b n1 w1
- 3 index eq { % f r s c i n w b n1
- 4 3 roll pop % f r s c i w b n1
- 3 1 roll pop % f r s c i n1 w
- Encoding 3 index 3 index put
- //false % f r s c i n1 w b
- exit
- } {
- pop
- } ifelse
- } { % f r s c i n w b n1
- pop
- } ifelse
- } forall % f r s c i n w b
- { % Do create a new name.
- Metrics 2 index //unique_name exec % f r s c i n w nn
- Encoding 4 index 2 index put
- GlyphMap 1 index 5 -1 roll put % f r s c i w nn
- exch
- % Stack: font font-res mscale first-char index new_name width
- } if
- } if
- 2 copy Metrics 3 1 roll put
- exit
- } loop
- pop pop
- 1 add
- }
- forall pop pop pop
- exch Encoding Metrics GlyphMap end
- } {
- //null //null
- } ifelse
-} bdef
-
-currentdict /unique_name undef
-currentdict /match_in_diff undef
-
-/ToUnicodeCMapReader 3 dict begin
- /defineresource % <name> <dict> <cat-name> defineresource <dict>
- {
- pop
- dup userdict exch /.lastToUnicode exch put
- exch pop
- } bind def
- /CIDSystemInfo
- {
- ( **** Warning: ToUnicode CMap has invalid syntax near CIDSystemInfo.\n) pdfformaterror
- /CIDSystemInfo
- } bind def % A work around a bug in Altona.Page_3.2002-09-27.pdf - a slash is missed.
- /CMapName
- {
- ( **** Warning: ToUnicode CMap has no CMapName.\n\
- See the comment to revision 6201 in gs/doc/ps2pdf.htm#Problems .\n) pdfformaterror
- /CMap1 % arbitrary, PDF defineresource tolerates non-unique names
- } bind def % A work around incorrect ToUnicode CMap generated by GS before rev. 6201.
-currentdict end readonly def
-
-/string2number % <string> string2number <number>
-{ 0 exch dup 0 exch 1 exch length 1 sub { % n () i
- 1 index exch get % n () v
- 3 2 roll 256 mul add exch % v+n*256 ()
- } for
- pop % N
-} bind def
-
-/copy&def % <key> <value> <bool> copy&def -
-{
- { true
- } {
- currentdict gcheck {
- dup gcheck not
- } {
- false
- } ifelse
- } ifelse
- { currentglobal currentdict gcheck setglobal
- exch dup length string copy exch
- setglobal
- } if
- def
-} bind def
-
-/.convert_ToUnicode-into-g2u % <GlyphNames2Unicode> <Encoding|null> <CMap> .convert_ToUnicode-into-g2u -
-{
- PDFDEBUG {
- (.convert_ToUnicode-into-g2u beg) =
- } if
- 3 2 roll begin
- /.CodeMapData get % About the data format see gs_cmap.ps, the comment after "CMap operators".
- 1 get % code maps
- {
- PDFDEBUG {
- dup ==
- } if
- dup length 1 sub 0 exch 5 exch { % e [] i
- 2 copy get % e [] i (prefix)
- string2number % e [] i prefix
- 2 index 2 index 1 add get % e [] i prefix (key_size,?is_range,value_type,value_size)
- dup 0 get 8 mul % e [] i prefix (key_size,?is_range,value_type,value_size) key_size*8
- 3 2 roll exch bitshift exch % e [] i prefix<<key_size*8 (key_size,?is_range,value_type,value_size)
- dup 0 get exch 3 get % e [] i offset key_size value_size
- 4 index 4 index 2 add get % e [] i offset key_size value_size (keys)
- 5 index 5 index 3 add get % e [] i offset key_size value_size (keys) (values)
- PDFDEBUG {
- ( offset=) print 4 index =string cvs print
- ( key_size=) print 3 index =string cvs print
- ( value_size=) print 2 index =
- ( keys=) print 1 index ==
- ( values=) print dup ==
- } if
- 1 index length 0 eq {
- % A single pair.
- exch pop exch pop exch pop exch % e [] i (values) offset
- 4 index null ne {
- 4 index length 1 index gt {
- 4 index exch get
- } if
- } if % e [] i (values) cid|name
- exch
- PDFDEBUG {
- ( defined single: ) print 1 index =string cvs print ( ) print dup ==
- } if
- false copy&def % e [] i
- pop % e []
- } {
- % A range. % e [] i offset key_size value_size (keys) (values)
- dup length string copy % protect the original string from modifications below.
- 0 4 index 2 mul 3 index length 1 sub { % e [] i offset key_size value_size (keys) (values) j
- 2 index 1 index 6 index getinterval
- string2number % e [] i offset key_size value_size (keys) (values) j keyL
- PDFDEBUG {
- ( keyL=) print dup =string cvs print
- } if
- 3 index 2 index 7 index add 7 index getinterval
- string2number % e [] i offset key_size value_size (keys) (values) j keyL keyH
- PDFDEBUG {
- ( keyH=) print dup =
- } if
- 3 2 roll 6 index idiv 5 index mul % e [] i offset key_size value_size (keys) (values) keyL keyH J
- 3 index exch 6 index getinterval % e [] i offset key_size value_size (keys) (values) keyL keyH (valueL)
- 3 1 roll 1 exch { % e [] i offset key_size value_size (keys) (values) (value) k
- 9 index null ne {
- 9 index exch get % e [] i offset key_size value_size (keys) (values) (value) name
- } if % e [] i offset key_size value_size (keys) (values) (value) cid|name
- 1 index % e [] i offset key_size value_size (keys) (values) (value) cid|name (value)
- PDFDEBUG {
- ( defined from range: ) print 1 index =string cvs print ( ) print dup ==
- } if
- true copy&def % e [] i offset key_size value_size (keys) (values) (value)
- % Assuming the lowest byte of 'value' changes, others don't.
- dup dup length 1 sub % e [] i offset key_size value_size (keys) (values) (value) (value) l
- 2 copy get % e [] i offset key_size value_size (keys) (values) (value) (value) l v
- % Modulo 256 increment prevents a rangecheck error when the result is stored in a string.
- % The adjustment can happen only at the end of the loop where the string is discarded. Bug 688535.
- 1 add 255 and put % e [] i offset key_size value_size (keys) (values) (value')
- } for % e [] i offset key_size value_size (keys) (values) (value)
- } for
- pop pop pop pop pop pop pop % e []
- } ifelse
- } for
- pop % e
- } forall
- end
- pop %
- PDFDEBUG {
- (.convert_ToUnicode-into-g2u end) =
- } if
-} bind def
-
-/.processToUnicode % <font-resource> <font-dict> <encoding|null> .processToUnicode -
-{
- % Currently pdfwrite is only device which can handle GlyphNames2Unicoide to
- % generate a ToUnicode CMaps. So don't bother with other devices.
- currentdevice .devicename /pdfwrite eq {
- PDFDEBUG {
- (.processToUnicode beg) =
- } if
- 2 index /ToUnicode knownoget {
- dup type /nametype eq {
- % Bug687351.pdf defines /ToUnicode /Identity-H, what is incorrect.
- ( **** Warning: Ignoring bad ToUnicode CMap.\n) pdfformaterror
- pop
- } {
- PDFfile fileposition exch
- false resolvestream
-
- //ToUnicodeCMapReader begin
- % Following Acrobat we ignore everything outside begincmap..endcmap.
- dup 0 (begincmap) /SubFileDecode filter flushfile
- /CIDInit /ProcSet findresource begin 12 dict begin
- 0 (endcmap) /SubFileDecode filter cvx /begincmap cvx exch 2 .execn
- endcmap
- userdict /.lastToUnicode currentdict put
- end end end
-
- PDFfile exch setfileposition
- 1 index /FontInfo .knownget not {
- 1 index /FontInfo 5 dict dup 4 1 roll put
- } if
- dup /GlyphNames2Unicode .knownget not {
- currentglobal exch dup gcheck setglobal
- dup /GlyphNames2Unicode 100 dict dup 4 1 roll .forceput
- 3 2 roll setglobal
- } if % font-res font-dict encoding|null font-info g2u
- exch pop exch % font-res font-dict g2u encoding|null
- userdict /.lastToUnicode get % font-res font-dict g2u Encoding|null CMap
- .convert_ToUnicode-into-g2u % font-res font-dict
- null % font-res font-dict null
- } ifelse
- } if
- PDFDEBUG {
- (.processToUnicode end) =
- } if
- } if
- pop pop pop
-} bind def
-
-% ---------------- Descriptors ---------------- %
-
-% Partial descriptors for the 14 built-in fonts. Note that
-% from PDF 1.1 to PDF 1.2, the meaning of the Flag 6 in the FontDescriptor
-% object has undergone a subtle change in its meaning which has serious
-% consequences for searching with Acrobat:
-% In PDF 1.1, the flag meant: Font has StandardEncoding
-% In PDF 1.2, the flag means: Font has (subset of) StandardRomanCharacterSet
-/standardfontdescriptors mark
- /Courier mark /Flags 16#23 .dicttomark
- /Courier-Oblique 1 index
- /Courier-Bold 1 index
- /Courier-BoldOblique 1 index
- /Helvetica mark /Flags 16#20 .dicttomark
- /Helvetica-Oblique 1 index
- /Helvetica-Bold 1 index
- /Helvetica-BoldOblique 1 index
- /Times-Roman mark /Flags 16#22 .dicttomark
- /Times-Bold 1 index
- /Times-Italic mark /Flags 16#62 .dicttomark
- /Times-BoldItalic 1 index
- /Symbol mark /Flags 16#4 .dicttomark
- /ZapfDingbats 1 index
-.dicttomark readonly def
-
-% ---------------- Utilities ---------------- %
-
-
-/.pdforigfontcache_g 20 dict def
-currentglobal false setglobal
-systemdict /.pdforigfontcache_l 20 dict .forceput
-setglobal
-
-% Find an original font, using cache to prevent adjustfont to accumulate changes.
-/pdffindcachedfont { % <font_name> pdffindcachedfont <font>
- dup //.pdforigfontcache_g exch .knownget {
- exch pop
- } {
- dup .pdforigfontcache_l exch .knownget {
- exch pop
- } {
- dup findfont dup
- dup gcheck { //.pdforigfontcache_g } { .pdforigfontcache_l } ifelse
- % Stack : font_name font font cache
- 4 2 roll .growput
- } ifelse
- } ifelse
-} bind def
-
-% Add original font to cache to prevent adjustfont to accumulate changes.
-/pdfaddcachedfont { % <font_name> pdfaddcachedfont <font>
- dup findfont dup % name font font
- dup gcheck { //.pdforigfontcache_g } {.pdforigfontcache_l} ifelse
- 4 2 roll % font d name font
- put % font
-} bind def
-
-/.remove_font_name_prefix { % <name> .remove_font_name_prefix <name>
- dup .namestring (+) search {
- true exch
- { dup 65 lt exch 90 gt or {
- pop false exit
- } if
- } forall
- { pop exch pop cvn
- } {
- pop pop
- } ifelse
- } {
- pop
- } ifelse
-} bind def
-
-% Find a font (except for embedded ones), and adjust its encoding if necessary.
-/.pdfdfndict mark
- /defaultfontname /Helvetica
-.dicttomark readonly def
-/pdffindfont { % <font-resource> <fontname> pdffindfont <font>
- % If the font isn't available, synthesize one based on
- % its descriptor.
- dup /Font resourcestatus {
- pop pop dup pdffindcachedfont
- dup .isregisteredfont
- % <font-resource> <fontname> <font> true % font preloaded from disk
- % <font-resource> <fontname> <font> false % font preloaded from document
- { exch pop false } { pop true } ifelse
- } {
- true
- } ifelse
- % <font-resource> <font> false % font preloaded from disk
- % <font-resource> <fontname> true % font not loaded yet or embedded
- {
- 1 index /FontDescriptor knownoget {
- % Stack: font-res fontname fontdesc
- dup /Flags oget
- dup 16#40 and -6 bitshift % 1, oblique/italic
- 1 index 16#40000 and -17 bitshift add % 2, bold
- exch 16#2 and 2 bitshift add % 8, serif
- % We should look at the fixed flag, too.
- % Stack: font-res fontname fontdesc properties
-
- % Even though /FontName is a required key in FontDescriptor dict
- % (As of the PDF 1.4 Reference Manual), In the case of missing
- % /FontName key, we substitue /BaseFont for the value of /FontName.
- % Yet another case of broken PDF's that Adobe Reader accepts.
- 1 index dup /FontName known {
- /FontName oget
- } {
- ( **** FontDescriptor missing required /FontName key. BaseFont name used.\n)
- pdfformaterror
- pop 2 index % grab the BaseFont from the stack.
- } ifelse
- .remove_font_name_prefix
- exch
- % Analyzes font name and extract "Bold" and "Narrow" properties
- % which are not described by the FontDescriptor Flags.
- 0 2 index .fontnameproperties 6 and or
- % Rebind the default font name to Helvetica so that
- % fonts with no properties are handled correctly.
- //.pdfdfndict begin .substitutefontname end
- % Stack: font-res fontname fontdesc substname|null
- Fontmap 1 index known not {
- % No available good substitution, use the standard one.
- pop 1 index .substitutefont
- } if
- dup 3 index ne QUIET not and {
- (Substituting font ) print dup =only
- ( for ) print 2 index =only (.) = flush
- } if
- pdffindcachedfont
- % Stack: font-res fontname fontdesc font
- % If this is a small-caps font, replace the CharString
- % entries for a..z.
- exch /Flags oget 16#20000 and 0 ne {
- true .copyfontdict
- dup /CharStrings 2 copy get dup length dict .copydict
- % stack: font-res fontname font font /CharStrings CharStringsdict
- 5 index /FirstChar get 97 .max
- 6 index /LastChar get 122 .min 1 exch {
- % Stack: font-res fontname font' font' /CharStrings charstrings code
- % Note that this only remaps a-z, not accented characters.
- 6 index /Widths oget 1 index 8 index /FirstChar get sub oget
- 1 string dup 0 5 -1 roll put
- % Stack: font-res font' font' /CharStrings charstrings code
- % width (x)
- 2 index exch dup cvn exch
- dup 0 2 copy get 32 sub put 4 -1 roll {
- % Stack: operand (X) width
- 0 setcharwidth exch pop
- currentfont /FontMatrix get matrix invertmatrix concat
- 0.7 dup scale 0 0 moveto show
- } /exec cvx 4 packedarray cvx put
- } for put
- } if
- dup /FontName get 2 index ne {
- true .copyfontdict
- 2 copy exch /FontName exch put
- } if
- definefont
- } {
- % No descriptor available, use the default algorithm.
- pdffindcachedfont
- } ifelse
- } if
- exch pop
-} bdef
-
-% ---------------- Type 1 fonts ---------------- %
-
-/buildType1 % <Type1-font-resource> buildType1 <font>
- { dup /BaseFont get pdffindfont
- } bdef
-
-% Read an embedded Type 1 font.
-/readfontfilter { % <proc> readfontfilter <filter>
- 0 () /SubFileDecode filter
-} bdef
-
-% Adobe Acrobat doesn't skip space characters after eexec
-/eexec_pdf_param_dict mark
- .eexec_param_dict {} forall
- /keep_spaces true
-.dicttomark readonly def
-
-% When Type 1 font reading procedure is executing, a copy of this dictionary is current.
-% We have to do something special about embedded fonts that execute definefont
-% more than once -- that is the function of topFontDict.
-% The whole type1 stream can be executed directly. There's no need to process
-% Length1, 2, 3 keys.
-
-/readtype1dict 5 dict dup begin
- /definefont {
- dup topFontDict eq topFontDict null eq or {
- dup wcheck not { dup length dict copy } if
- exch pop savedFontName exch
- } if
- //systemdict /definefont get exec
- } bdef
-
- /undef_proc_warning {
- /Repaired true store % flag that we have warnings
- UndefProcList exch 2 copy .knownget { 1 add } { 1 } ifelse put
- } bdef
-
- /missing-type1-procs 6 dict begin
- /-| { string currentfile exch readstring pop /-| //undef_proc_warning exec } executeonly bdef
- /RD { string currentfile exch readstring pop /RD //undef_proc_warning exec } executeonly bdef
- /|- { noaccess def /|- //undef_proc_warning exec } executeonly bdef
- /ND { noaccess def /ND //undef_proc_warning exec } executeonly bdef
- /| { noaccess put /| //undef_proc_warning exec } executeonly bdef
- /NP { noaccess put /NP //undef_proc_warning exec } executeonly bdef
- currentdict end readonly def
-
- /eexec {
- % Assume the font dictionary is directly below the file on the stack
- count 0 gt { /topFontDict 2 index cvlit store } if
- //eexec_pdf_param_dict /eexecDecode filter
-
- //missing-type1-procs begin
- /userdict .systemvar begin
- //systemdict begin
- readtype1dictcopy begin cvx stopped
-
- { currentdict end //missing-type1-procs eq { exit } if } loop
- { stop } if
- } bdef
-
- /readonly-op-dict <<
- /stringtype 0
- /arraytype 0
- /packedarraytype 0
- /dicttype 0
- >> readonly def
-
- /readonly { % bug 689617
- dup type //readonly-op-dict exch known {
- readonly
- } {
- ( **** Warning: Type 1 font applies operator readonly to a wrong type.\n)
- pdfformaterror
- } ifelse } .bind def
-
- currentdict dup dup
- /undef_proc_warning undef
- /missing-type1-procs undef
- /readonly-op-dict undef
-
-end readonly def
-
-currentdict /eexec_pdf_param_dict .undef
-
-/readtype1 { % <font-resource> <stream-dict> readtype1 <font>
- 1 index exch % res res stream
- PDFfile fileposition 3 1 roll % res pos res stream
- dup /PFB known exch % res pos res pfb? stream
- true resolvestream % res pos res pfb? file
- exch {
- //false /PFBDecode filter
- } if
- % Some buggy embedded fonts leave extra junk on the stack,
- % so we have to make a closure that records the stack depth
- % in a fail-safe way. This code also removes the mark when
- % the implied cleartomark is not executed, i.e. Length3 == 0.
- % Also restore dictstack depth.
- %
- //systemdict begin
- % The PDF specification is somewhat muddy about whether
- % an embedded font's name is supposed to be the BaseFont
- % from the Font object or the FontName from the descriptor.
- % Acrobat Distiller requires the former. Save away the
- % name so we can substitute it at definefont time.
- //readtype1dict dup length 3 add dict copy begin
- 1 index /BaseFont oget /savedFontName exch def
- /topFontDict null def
- /readtype1dictcopy currentdict def
- { cvx exec } aload pop count 2 sub 3 packedarray cvx exec
- % clean up the dictstack
- { currentdict /topFontDict known not { end } { end end exit } ifelse } loop
- count exch sub { pop } repeat
- PDFfile 3 -1 roll setfileposition
- /BaseFont oget pdfaddcachedfont
- exch pop
- } bdef
-
-% ---------------- Type 3 fonts ---------------- %
-
-/buildType3 { % <Type3-font-resource> buildType3 <font>
- 8 dict begin
- /FontType 3 def
- % If the font does not contain a Resources entry, then we use
- % the resources from our current context. Page 391 of the PDF
- % 1.6 spec says that the Resources dict is optional and if not
- % present then we should use the Resources for the page.
- % However we have a test file (687989) which uses a Type3 font
- % inside a form XObject and the desired Resources are in the
- % XObject dict and not in the Page dict. So we are going to
- % the parent object to find resources instead of only going to
- % the page dict when a font does not specify its required
- % resources.
- /Resources 1 index /Resources knownoget {
- oforce
- } {
- LocalResources
- } ifelse def
- /FontBBox 1 index /FontBBox get cvx def
- /FontMatrix 1 index /FontMatrix oget def
- /CharProcs 1 index /CharProcs oget def
- 1 index /Widths knownoget {
- /Widths exch def
- /FirstChar 1 index /FirstChar oget def
- /LastChar 1 index /LastChar oget def
- } if
- /FontName 1 index /Name .knownget not {
- PDFfile fileposition 16 32 string cvrs cvn
- } if def
-
- /Encoding .notdefEncoding 2 index getencoding def
- % We have to define BuildChar rather than BuildGlyph:
- % there is no PDF equivalent of glyphshow, and we need
- % the character code to access the Widths.
- /BuildChar {
- % Stack: font charcode
- 1 index begin 3 dict begin
- /Font 3 -1 roll def /CharCode 1 index def
- Encoding exch get CharProcs exch knownoget {
- PDFfile fileposition exch
- //false resolvestream
- % Stack: filepos stream
- % Don't let setgcolor set the color inside the BuildGlyph
- % procedure, because this causes an /undefined error.
- q //null /FillColor gput //null /StrokeColor gput
- Font /Resources get exch pdfopdict .pdfruncontext
- Q
- PDFfile exch setfileposition
- } {
- % PDF Type 3 fonts don't use .notdef
- % d1 implementation adjusts the width as needed
- 0 0 0 0 0 0
- pdfopdict /d1 get exec
- } ifelse
- end end
- } bdef
- dup currentdict Encoding .processToUnicode
- FontName currentdict end definefont exch pop
-} bdef
-/.adjustcharwidth { % <wx> <wy> .adjustcharwidth <wx'> <wy'>
- % Enforce the metrics, in glyph space, to the values found in the PDF Font object
- % - force wy == 0 (assumed, and not stored in the PDF font)
- % Even though PDF1.3-1.7 specifications state that this must be 0,
- % Distiller sometimes creates Type3 fonts with non-zero wy. We set
- % it to 0 since this is apparently what Acrobat Reader 4 and 5 do.
- % PDF1.2 does not mention this restriction, it only says
- % "see setcharwidth/ setcachedevice in the PostScript Reference".
- % - get wx from the Widths array (do nothing if not present)
- pop 0
- /Widths where {
- begin
- CharCode FirstChar ge CharCode LastChar le and {
- exch pop Widths CharCode FirstChar sub get exch
- } if end
- } if
-} bdef
-
-% ---------------- TrueType fonts ---------------- %
-
-/TTfonts mark
- /Arial /Helvetica
- /Arial,Italic /Helvetica-Oblique
- /Arial,Bold /Helvetica-Bold
- /Arial,BoldItalic /Helvetica-BoldOblique
- /CourierNew /Courier
- /CourierNew,Bold /Courier-Bold
- /TimesNewRoman /Times-Roman
- /TimesNewRoman,Italic /Times-Italic
- /TimesNewRoman,Bold /Times-Bold
- /TimesNewRoman,BoldItalic /Times-BoldItalic
-.dicttomark readonly def
-
-/buildTrueType { % <TrueType-font-resource> buildTrueType <font>
- dup /BaseFont oget
- dup /Font resourcestatus dup { exch pop exch pop } if not
- TTfonts 2 index known and {
- dup TTfonts exch get
- QUIET not {
- (Substituting font ) print dup =only
- ( for ) print 1 index =only (.) = flush
- } if
- exch 3 1 roll pdffindfont
- true .copyfontdict
- 2 copy exch /FontName exch put
- definefont
- } {
- pdffindfont
- } ifelse
-} bdef
-
-% Read an embedded TrueType font.
-/readtruetype { % <font-resource> <stream-dict> readtruetype <font>
- 1 index exch
- PDFfile fileposition 3 1 roll
- true resolvestream readfontfilter
- % Stack: filepos fontres stream
- 1 index /Subtype get /CIDFontType2 eq {
- .loadttcidfont
- % Stack: filepos fontres cidfont
- } {
- % filepos fontres stream
- 1 index /FontDescriptor oget % filepos fontres stream fd
- /Flags get 4 and 0 ne % filepos fontres stream is_symbolic
- dup { //null } { StandardEncoding } ifelse
- 3 index /Encoding known {
- 3 index getencoding
- } if % filepos fontres stream is_symbolic Encoding
- dup 4 index exch % filepos fontres stream is_symbolic Encoding fontres Encoding
- /prebuilt_encoding exch put % filepos fontres stream is_symbolic Encoding
- .loadpdfttfont
- } ifelse
- exch pop
- PDFfile 3 -1 roll setfileposition
- % Ignore both the Encoding and the Widths.
- exch pop
-} bdef
-
-% ---------------- Type 0 fonts ---------------- %
-
-% Predefine the known CMaps, but only create them on demand.
-/knownCMaps mark
- /Identity-H { /Identity-H 0 makeIdentityCMap }
- /Identity-V { /Identity-V 1 makeIdentityCMap }
-.dicttomark def
-
-/makeIdentityCMap { % <cmapname> <wmode> .makeIdentityCMap -
- .currentglobal true .setglobal 3 1 roll
- /CIDInit /ProcSet findresource begin
- 12 dict begin
- begincmap
- /WMode exch def
- /CMapName exch def
- /CIDSystemInfo 3 dict dup begin
- /Registry (Adobe) def
- /Ordering (Identity) def
- /Supplement 0 def
- end def
- %/CMapName (see above)
- /CMapVersion 1 def
- /CMapType 1 def
- %WMode (see above)
- % The PDF documentation says that these CMaps map CIDs
- % "1 to 65,536". This is a misprint for 0 to 65,535.
- 1 begincodespacerange
- % <0001> <00ff> <0100> <ffff>
- <0000> <ffff>
- endcodespacerange
- 1 begincidrange
- % <0001> <00ff> 1 <0100> <ffff> 256
- <0000> <ffff> 0
- endcidrange
- endcmap
- CMapName currentdict /CMap defineresource
- knownCMaps CMapName 2 index put
- end % CMap
- end % CIDInit ProcSet
- exch .setglobal
-} bdef
-
-/buildType0 { % <Type0-font-resource> buildType0 <font>
- dup /BaseFont get % FontName
- 1 index /Encoding oget
- dup type /nametype eq {
- dup /CMap resourcestatus {
- pop pop /CMap findresource
- } {
- knownCMaps 1 index .knownget
- { exch pop exec } { /undefined signalerror } ifelse
- } ifelse
- } {
- PDFfile fileposition exch
- dup /CMapName get exch true resolvestream cvx exec
- /CMap findresource
- exch PDFfile exch setfileposition
- } ifelse % CMap
- [
- 3 index /DescendantFonts oget { exec resourcefont } forall
- ] % subfonts
- .composefontdict % composefont must insert FontInfo dictionary - see gs_cmap.ps .
- % Stack: fontres name font
- 3 copy exch pop null .processToUnicode
- /Font defineresource % Stack: fontres font
- 1 index /FontMatrix knownoget {
- dup aload pop true {0 0 1 0 0 1} {3 -1 roll eq and} forall {
- 1 index exch makefont exch /FontName get exch definefont
- } {
- pop
- } ifelse
- } if exch pop
-} bdef
-
-% ---------------- CIDFontType0/2 fonts ---------------- %
-
-% Insert metrics into a CIDFont, by saving the PDF W, W2, DW, and DW2
-% arrays and using a (currently very inefficient) CDevProc.
-% For detail, refer "PDF Reference" 2nd ed., p314 "5.6.3 CIDFonts".
-% It notes default DW is 0, but Acrobat Reader uses 1000 as default.
-% If DW is 0, currentpoint does not move by default in rendering text
-% horizontally, the result is unreadable. You can check it by Acrobat.
-
-/.pdfDefaultDW 1000 def
-/.pdfDefaultDW2 [ 880 -1000 ] def
-
-/addCIDmetrics { % <CIDFont-resource> <CIDFont> addCIDmetrics <fontdict>
- dup length 5 add dict .copydict
- dup /FID undef
- dup /UniqueID undef
- dup /XUID undef
- % Insert the widths into the font.
-
- % Stack: pdfresource newfont
-
- 1 index /DW knownoget {
- 1 index /DW 3 -1 roll put
- } {
- dup /DW .pdfDefaultDW put
- } ifelse
-
- 1 index /W knownoget {
- dup 2 index /W 3 -1 roll put
- .pdfMakeInternalW 1 index /.internalW 3 -1 roll put
- } if
-
- 1 index /DW2 knownoget {
- 1 index /DW2 3 -1 roll put
- } {
- dup /DW2 .pdfDefaultDW2 put
- } ifelse
-
- 1 index /W2 knownoget {
- dup 2 index /W2 3 -1 roll put
- .pdfMakeInternalW2 1 index /.internalW2 3 -1 roll put
- } if
-
- dup /CDevProc 1 index /CIDWProc load /exec load 3 packedarray cvx put
- exch pop
-} bdef
-
-/.pdfMakeInternalMTXArray { % <mtx_array> <item_size> .pdfConvertInternalW <mtx_array'>
-
- % convert /W or /W2 to internal expression
- %
- % mtx_array: original /W or /W2 array
- % item_size: number of metrics values per CID
- %
- % for detail of the metrics list format in PDF,
- % refer PDF Ref. p.317 "Glyph Metrics in CIDFonts".
- %
- % format of single entry in internal expression
- %
- % [
- % [cid_begin cid_end]
- % value_is_varied (bool)
- % [ [values for cid_begin...]
- % [values for cid_begin + 1]
- % ... ]
- % ]
- %
-
- 7 dict
- begin
- /itemSize exch def
- /M exch def % original /W or /W2
- /Msize M length def
- /Mi { M i get } def % W[i]
- /Mi1 { M i 1 add get } def % W[i + 1]
- /putMTXEntry <<
- /arraytype {
- [
- [Mi Mi Mi1 length itemSize idiv add 1 sub]
- true
- [
- 0 itemSize Mi1 length 1 sub {
- [ exch 1 1 index itemSize add 1 sub { Mi1 exch get } for ]
- } for
- ]
- ]
- /i i 2 add def
- }
- /integertype {
- [
- [Mi Mi1]
- false
- [[ i 2 add 1 i 1 add itemSize add { M exch get } for ]]
- ]
- /i i 3 add def
- }
- >> def
-
- /i 0 def
-
- [ { putMTXEntry Mi1 type get exec i Msize ge { exit } if } loop ]
- end
-} def
-
-/.pdfMakeInternalW { dup length 0 gt { 1 .pdfMakeInternalMTXArray } if } def
-/.pdfMakeInternalW2 { dup length 0 gt { 3 .pdfMakeInternalMTXArray } if } def
-
-/.pdfGetMTXByCID { % <internalMTXArray> <cid>
- % .pdfGetMTXByCID
- % { <MTXEntry> true | false }
-
- % get values for given CID from internal format of /W or /W2
-
- exch
- {
- {
- dup 0 get {} forall % Stack: <cid> <entry> <cid_0> <cid_1>
- 3 index lt { pop pop false exit } if
- 2 index exch sub dup 0 lt { pop pop false exit } if
- 1 index 1 get not { pop 0 } if
- exch 2 get exch get true exit
- } loop
- { exit } if
- } forall
- dup type /arraytype eq { exch pop true } { pop false } ifelse
-} def
-
-
-% Apply the [D]W[2] metrics to a character before displaying.
-/CIDWProc { % <w0x> <w0y> <llx> <lly> <urx> <ury>
- % <w1x> <w1y> <vx> <vy> <cid> <font> CIDWproc
- % <w0x'> ... <vy'>
- begin % push <font> to currentdict
- % <w1x> <w1y> <vx> <vy> won't be used and replaced, discard now
- 5 1 roll pop pop pop pop
-
- {
- currentdict /DW .knownget not { % no DW
- .pdfDefaultDW exit % replace <w0x> by defaultDW
- } if
-
- currentdict /.internalW .knownget not { % no W
- exit % use already-stacked DW
- } if
-
- dup length 0 eq { % W is null array
- pop % discard unusable W
- exit % use already-stacked DW
- } if
-
- % W is finite array, try to get W_cid
- 2 index .pdfGetMTXByCID { % got W, discard DW
- exch pop {} forall
- exit
- } if
-
- exit
- } loop
-
- FontType 11 eq {
- 1000 div % <w0x'> (normalized W)
- } if
- 0 % <w0y'>
-
- % Stack: <w0x> <w0y> <llx> <lly> <urx> <ury> <cid> <w0x'> <w0y'>
- 9 -2 roll pop pop % discard <w0x> <w0y>
- 7 2 roll % put <w0x'> <w0y'>
-
- % Stack: <w0x'> <w0y'> <llx> <lly> <urx> <ury> <cid>
- 0 % <w1x'>
- exch % put <w1x'>
-
- % Stack: <w0x'> <w0y'> <llx> <lly> <urx> <ury> <w1x'> <cid>
- {
- currentdict /DW2 .knownget not { % no DW2, use defaultDW2
- .pdfDefaultDW2 exit
- } if
-
- currentdict /.internalW2 .knownget not { % has DW2, no W2
- exit % use already-stacked DW2
- } if
-
- dup length 0 eq { % W2 is null array
- pop % discard unusable W2
- exit % use already-stacked DW2
- } if
-
- 2 index .pdfGetMTXByCID { % got W2_cid, discard DW2
- exch pop
- exit
- } if
-
- % could not get W2_cid
- exit
-
- } loop
-
- exch pop % discard <cid>
-
- % Stack: <w0x'> <w0y'> <llx> <lly> <urx> <ury> <w1x'> { [<vy'> <w1y'>] | [<w1y'> <vx'> <vy'>] }
- dup length 2 eq { % this is DW2
- FontType 11 eq {{1000 div}} {{}} ifelse forall exch
- 8 index 2 div % <vx'> = <w0x'> / 2
- exch
- }{ % assume W2
- FontType 11 eq {{1000 div}} {{}} ifelse forall
- } ifelse
- end % recover currentdict
-
-} def
-
-% <string> <match> tailmatch ==> <pre> true
-% ==> <string> false
-/tailmatch {
- 2 copy length 1 index length .min
- dup 2 index length exch sub exch getinterval
- 1 index eq {
- length 1 index length exch sub
- 0 exch getinterval true
- } {
- pop false
- } ifelse
-} bind def
-
-/makeboldfont {
- 16 dict begin
- /strokewidth exch def
- /basecidfont exch def
- /FontMatrix [ 1 0 0 1 0 0 ] def
-
- /CIDFontName /.boldfont def
- /CIDFontType 1 def
-
- /basefont-H /.basefont-H /Identity-H [ basecidfont ] composefont def
- /basefont-V /.basefont-V /Identity-V [ basecidfont ] composefont def
-
- /CIDSystemInfo dup basecidfont exch get def
- /FontBBox [ basecidfont /FontBBox get cvx exec
- 4 2 roll basecidfont /FontMatrix get transform
- 4 2 roll basecidfont /FontMatrix get transform
- ] def
-
- /tmpstr 2 string def
- /BuildGlyph {
- gsave
- exch begin
- dup 256 idiv tmpstr exch 0 exch put
- 256 mod tmpstr exch 1 exch put
- rootfont /WMode known { rootfont /WMode get 1 eq } { false } ifelse
- { basefont-V } { basefont-H } ifelse setfont
- strokewidth setlinewidth
- 1 setlinejoin
- newpath
- 0 0 moveto tmpstr false charpath stroke
- 0 0 moveto tmpstr show
- currentpoint setcharwidth
- end
- grestore
- } bind def
-
- currentdict
- end
- dup /CIDFontName get exch /CIDFont defineresource
-} bind def
-
-% <CIDFont-resource> <CIDFontName> findCIDFont <CIDFont-resource> <font>
-% CIDFont-resource is not modified.
-/findCIDFont {
- {
- dup /CIDFont resourcestatus {
- pop pop /CIDFont findresource
- exit
- } if
- .remove_font_name_prefix
- dup dup length string cvs
- (,Bold) tailmatch {
- exch pop
- cvn findCIDFont 0.03 makeboldfont
- exit
- } if
- (,Italic) tailmatch {
- exch pop
- cvn findCIDFont
- [ 1 0 0.3 1 0 0 ] makefont
- exit
- } if
- (,BoldItalic) tailmatch {
- exch pop
- cvn findCIDFont 0.03 makeboldfont
- [ 1 0 0.3 1 0 0 ] makefont
- exit
- } if
- pop
-
- 1 index /CIDSystemInfo oget begin Registry (-) Ordering end
- concatstrings concatstrings
- cvn
- QUIET not {
- (Substituting CID font resource) print dup ==only
- ( for ) print 1 index ==only (.\n) print
- } if
- exch pop
- /CIDFont findresource
- exit
- } loop
-} bdef
-
-/buildCIDType0 { % <CIDFontType0-font-resource> buildCIDType0 <font>
- dup /BaseFont get findCIDFont exch pop
-} bdef
-
-/buildCIDType2 { % <CIDFontType2-font-resource> buildCIDType2 <font>
- dup /BaseFont get findCIDFont exch pop
-} bdef
-
-/processCIDToGIDMap { % <fontres> <cidfont> processCIDToGIDMap <fontres> <cidfont>
- 1 index /CIDToGIDMap knownoget {
- PDFfile fileposition 4 1 roll
- dup /Identity eq {
- pop
- } {
- true resolvestream
- % Stack: filepos fontres font mapstream
- % Can't know the length of the decompressed stream, so allocate a big buffer...
- dup 65534 string readstring {
- % Length exceeded max string size, use an array of two strings
- 1 index 65534 string readstring pop % maybe a null string - not important.
- 2 array astore
- % Stack: filepos fontres font mapstream array
- dup 1 get length 65534 add
- } {
- dup length
- } ifelse
- 2 idiv
- % Stack: filepos fontres font mapstream array/string CIDCount
- 3 index exch /CIDCount exch put
- exch closefile exch
- dup /CIDMap 4 -1 roll put
- } ifelse
- 3 2 roll PDFfile exch setfileposition
- } if
-} bdef
-
-% Adjust a CIDFontType0 DW[2] in the font resource.
-/adjustCIDType0 { % <font-resource> <font> adjustfont <font'>
- addCIDmetrics
- dup /CIDFontName get exch /CIDFont defineresource
-} bind def
-
-% Adjust a CIDFontType2 DW[2] and CIDToGIDMap in the font resource.
-/adjustCIDType2 { % <font-resource> <font> adjustfont <font'>
- addCIDmetrics
- processCIDToGIDMap
- dup /CIDFontName get exch /CIDFont defineresource
-} bind def
-
-% ---------------- Other embedded fonts ---------------- %
-
-/fontloadprocs mark
- /Type1C /readType1C cvx
- /CIDFontType0C /readCIDFontType0C cvx
-.dicttomark readonly def
-
-% Read an embedded compressed font.
-/readType1C { % <font-resource> <stream-dict> readType1C <font>
- 1 index exch
- PDFfile fileposition 3 1 roll
- dup true resolvestream dup readfontfilter
- % Stack: pos resource streamdict stream filter
- 3 index /FontDescriptor oget /FontName oget
- 1 index FRD
- closefile closefile pop
- PDFfile 3 -1 roll setfileposition
- /FontDescriptor oget /FontName oget pdfaddcachedfont
- exch pop
-} bdef
-
-% Read an embedded CFF CIDFont.
-/readCIDFontType0C { % <font-resource> <stream-dict> readCIDFontType0C <font>
- PDFfile fileposition 3 1 roll
- dup true resolvestream dup readfontfilter
- % Stack: pos resource streamdict stream filter
- 3 index /FontDescriptor oget /FontName oget
- 1 index FRD
- closefile closefile pop
- PDFfile 3 -1 roll setfileposition
- % Some broken Adobe software produces PDF files in which
- % the FontName of the CFF font and the FontName in the
- % FontDescriptor don't match the BaseFont in the font.
- % Use the FontName, rather than the BaseFont, here.
- dup /FontDescriptor oget /FontName oget /CIDFont findresource
- addCIDmetrics dup /CIDFontName get exch /CIDFont defineresource
-} bdef
-
-% Read an embedded OpenType font.
-/readOTTOfont { % <font-resource> <stream-dict> readOTTOfont <font>
- 1 index exch
- PDFfile fileposition 3 1 roll
- dup true resolvestream dup readfontfilter
- % Stack: pos resource streamdict stream filter
- 3 index /FontDescriptor oget /FontName oget
- 1 index
- .init_otto_font_file //true ReadData
- closefile closefile pop
- PDFfile 3 -1 roll setfileposition
- /FontDescriptor oget /FontName oget pdfaddcachedfont
- exch pop
-} bdef
-
-% ---------------- Font lookup ---------------- %
-
-% Some PDF files mis-identify font type of the embedded font streams or
-% include raw PFB font streams. Length1, Length2, Length3 may be wrong or
-% missing. Adobe Acrobat corrects these errors transparently to the user.
-%
-% We ignore the font type keys and recognize the font type by the 1st 4 bytes
-% of the font stream. The PFB stream is recognized by the 1st 2 bytes.
-
-/fonttypeprocs mark % <font-resource> -proc- <font>
- /Type0 //buildType0
- /Type1 //buildType1
- /MMType1 //buildType1
- /Type3 //buildType3
- /TrueType //buildTrueType
- /CIDFontType0 //buildCIDType0
- /CIDFontType2 //buildCIDType2
-.dicttomark readonly def
-
-/adjustfonttypes mark
- /Type1 //adjustfont
- /MMType1 //adjustfont
- /TrueType //adjustfont
- /CIDFontType0 //adjustCIDType0
- /CIDFontType2 //adjustCIDType2
-.dicttomark readonly def
-
-% Bind a proc and define n names
-% /name ... /name {proc} n bndef -
-/bndef
- { exch bind exch
- { dup 3 1 roll def } repeat
- pop
- } bdef
-
-% Prototype for all procedures: <res> <desc> <stream> foo <font>
-/font_tag_dict 13 dict begin
-
- % When the font stream is absent or cannot be read we load the font by the name.
- /no_stream
- { pop pop
- dup /Subtype get % res res /subtype
- fonttypeprocs exch dup / eq {
- ( **** Warning: Font missing required Subtype, /Type1 assumed.\n)
- pdfformaterror
- pop /Type1
- } if
- get exec
- } bdef
-
- /bad_stream
- { ( **** Warning: Error reading font stream, loading font by the name\n)
- pdfformaterror
- //no_stream exec
- } bdef
-
- <8001> % PFB
- { dup /PFB //true put
- exch pop readtype1
- } bdef
-
- (%!PS) (%!Fo) % Type1
- { exch pop readtype1
- } 2 bndef
-
- <01000401> <01000402> <01000403> <01000404> % Type 1C
- <01000C02>
- { exch pop
- dup /Subtype get
- fontloadprocs exch get exec
- } 5 bndef
-
- <00010000> (true) (typ1) (ttcf) % TrueType OpenType
- { exch pop readtruetype
- } 4 bndef
-
- (OTTO)
- { exch pop
- readOTTOfont
- } bdef
-
-
-currentdict end readonly def
-currentdict /bndef undef
-
-/resourcefont % <font-resource> resourcefont <font>
-{ dup /PSFont .knownget {
- /FID knownoget { type /fonttype eq } { //false } ifelse
- } {
- //false
- } ifelse {
- /PSFont get
- } {
- dup dup /FontDescriptor knownoget {
- % font-res font-res font-desc
-
- dup /FontObject .knownget dup { % font-res font-res font-desc font? bool bool
- % Check that the cached FontObject has the right resource type
- % The same font descriptor can be reused in a CID and non-CID contexts. bug 689301
- 3 index /Subtype knownoget not { /Type1 } if
- dup /CIDFontType0 eq exch /CIDFontType2 eq or % font-res font-res font-desc font bool is_cid
- 2 index /CIDFontType known xor {
- pop pop //false % font-res font-res font-desc false
- } if
- } if {
- % res res desc obj
- 3 1 roll pop pop % res obj
- } {
- dup /FontFile knownoget not {
- dup /FontFile2 knownoget not {
- dup /FontFile3 knownoget not {
- //null
- } if
- } if
- } if
- % res res desc stream
- dup //null ne {
- PDFfile fileposition
- 1 index //true resolvestream dup
- 4 string readstring not { /bad_stream } if
- exch closefile
- PDFfile 3 -1 roll setfileposition
- dup length 4 lt { pop /bad_stream } if
- } {
- /no_stream
- } ifelse
- % res res desc stream tag
-
- //font_tag_dict 1 index known not {
- dup 0 2 getinterval <8001> eq {
- 0 2 getinterval % res res desc stream pfb_tag
- } {
- (12345678>\n) dup /ASCIIHexEncode filter dup 4 -1 roll writestring closefile
- ( **** Warning: unrecognized font file starts with <) exch concatstrings
- pdfformaterror
- /no_stream % res res desc stream unknown_tag
- } ifelse
- } if
-
- //font_tag_dict exch get exec
-
- 1 index /FontDescriptor oget % res font desc
- 1 index /FontObject exch put % Save pointer to the font
- } ifelse
- } {
- dup /Subtype get fonttypeprocs exch dup / eq {
- ( **** Warning: Font missing required Subtype, /Type1 assumed.\n)
- pdfformaterror
- pop /Type1
- } if
- get exec
- } ifelse
- % Stack: font-res font
- 1 index 3 1 roll
- 1 index /Subtype get
- //adjustfonttypes exch .knownget { exec } { exch pop } ifelse
- dup 3 1 roll /PSFont exch put
- } ifelse
- dup checkGlyphNames2Unicode
-} bdef
-
-currentdict /font_tag_dict undef
-
-drawopdict begin
- /d0 {
- .adjustcharwidth setcharwidth
- } bdef
- /d1 {
- 2 copy % ... llx lly urx ury | urx ury
- 0 ne exch 0 ne % ... llx lly urx ury | ury!=0 urx!=0
- 3 index 6 index eq and % ... llx lly urx ury | ury!=0 (urx!=0 && llx==urx)
- exch 2 index 5 index eq and or { % ... llx lly urx ury | (urx!=0 && llx==urx) || (ury!=0 && lly==ury)
- % The bounding box is empty and likely incorrect. Don't cache.
- pop pop pop pop .adjustcharwidth setcharwidth
- } {
- 6 -2 roll .adjustcharwidth 6 2 roll setcachedevice
- } ifelse
- } bdef
- /Tf {
- 1 index Page /Font rget {
- resourcefont exch Tf pop
- }
- { % Bug 689037
- ( **** Warning: Tf refers to an unknown resource name: ) pdfformaterror
- 1 index .namestring pdfformaterror
- ( Assuming it's a font name.\n) pdfformaterror
- Tf
- } ifelse
- } bdef
-end
-
-end % pdfdict
-end % GS_PDF_ProcSet
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/pdf_main.ps b/Master/tlpkg/tlgs/lib/pdf_main.ps deleted file mode 100644 index efe74533d2f..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf_main.ps +++ /dev/null @@ -1,1849 +0,0 @@ -% Copyright (C) 1994, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdf_main.ps 8486 2008-01-17 03:12:45Z alexcher $
-% pdf_main.ps
-% PDF file- and page-level operations.
-
-/.setlanguagelevel where { pop 2 .setlanguagelevel } if
-.currentglobal true .setglobal
-/pdfdict where { pop } { /pdfdict 100 dict def } ifelse
-pdfdict begin
-
-% Patch in an obsolete variable used by some third-party software.
-/#? false def
-
-% Test whether the current output device handles pdfmark.
-/.writepdfmarkdict 1 dict dup /pdfmark null put readonly def
-/.writepdfmarks { % - .writepdfmarks <bool>
- currentdevice //.writepdfmarkdict .getdeviceparams
- mark eq { false } { pop pop true } ifelse
- systemdict /DOPDFMARKS known or
-} bind def
-
-% For simplicity, we use a single interpretation dictionary for all
-% PDF graphics execution, even though this is too liberal.
-/pdfopdict mark
- objopdict { } forall
- drawopdict { } forall
- /endstream { exit } bind
- (%%EOF) cvn { exit } bind % for filters
- /obj { ( **** Warning: Content stream is not terminated by 'endstream'.\n)
- pdfformaterror pop pop exit
- } bind
- % PDF 1.1 operators
- /BX { /BXlevel BXlevel 1 add store } bind
- /EX { /BXlevel BXlevel 1 sub store } bind
- /PS { cvx exec } bind
- % PDF 1.2 operators
- /BMC { pop } bind
- /BDC { pop pop } bind
- /EMC { }
- /MP { pop } bind
- /DP { pop pop } bind
-.dicttomark readonly def
-
-% ======================== Main program ======================== %
-
-end % pdfdict
-userdict begin
-
-/defaultfontname /Times-Roman def
-
-% Make sure the registered encodings are loaded, so we don't run the risk
-% that some of the indices for their names will overflow the packed
-% representation. (Yes, this is a hack.)
-SymbolEncoding pop
-DingbatsEncoding pop
-
-% Redefine 'run' so it recognizes PDF files.
-systemdict begin
-/.runps /run load def
-/run {
- dup type /filetype ne { (r) file } if
- % skip leading whitespace characters (actually anything less than or equal to <sp>)
- { dup ( ) .peekstring not { false exit } if
- dup 0 get 32 le { pop dup read pop pop } { true exit } ifelse
- } loop
- exch pop
- {
- % Appletalk PAP sends short strings with %! header expecting a response.
- % 'gv' swallows the %!PS line, then sends DSC comments beginning with %%
- % and also waits for a response. The following avoids those hangs.
- dup 2 string .peekstring pop dup (%!) eq exch (%%) eq or {
- cvx .runps
- } {
- dup 1023 string .peekstring pop dup length 400 ge {
- % "1024 string" exceeds current %stdin buffer
- % Valid PDF file cannot be smaller than 400 bytes.
- (%PDF-1.) search {
- 3 1 roll pop pop
- dup (%!PS) search not {
- length 0 ne {
- 1 index exch readstring pop pop
- (%stderr) (w) file dup
- ( **** Warning: File has some garbage before %PDF-1. .\n)
- writestring flushfile
- } {
- pop
- } ifelse
- dup (%stdin) (r) file eq {
- % Copy PDF from stdin to temporary file then run it.
- null (w+) //systemdict /.tempfile get exec exch 3 1 roll
- % stack: tempname stdin tempfile
- 64000 string
- {
- % stack: tempname stdin tempfile string
- 2 index 1 index readstring
- exch 3 index exch writestring
- not { exit } if
- }
- loop
- pop exch closefile
- % stack: tempname tempfile
- dup 0 setfileposition
- dup runpdf
- closefile deletefile
- } {
- runpdf
- } ifelse
- } {
- pop pop pop pop cvx .runps % (%!PS) found first
- } ifelse
- } {
- pop cvx .runps % (%PDF-1.) not found
- } ifelse
- } {
- pop cvx .runps % too short for PDF
- } ifelse
- } ifelse
- } {
- closefile % file was empty
- } ifelse
-} bind odef
-currentdict /runpdfstring .undef
-
-
-/runpdfbegin { % <file> runpdfbegin -
- userdict begin
- % It turns out that the PDF interpreter uses memory more
- % effectively if it is run under at least one level of save.
- % This is counter-intuitive, and we don't understand why it happens,
- % but the improvement is significant.
- /PDFTopSave save def
- 0 setobjectformat
- /Page# null def
- /Page null def
- /DSCPageCount 0 def
- /PDFSave null def
- GS_PDF_ProcSet begin
- pdfdict begin
- pdfopen begin
-} bind def
-
-/runpdfpagerange { % - runpdfpagerange <firstpage#> <lastpage#>
- /FirstPage where
- { pop FirstPage dup pdfpagecount gt
- { (\nRequested FirstPage is greater than the number of pages in the file: ) print
- pdfpagecount = flush
- } if
- } {
- 1
- } ifelse
- /LastPage where { pop LastPage pdfpagecount .min } { pdfpagecount } ifelse
- 1 index 1 index gt
- { ( No pages will be processed \(FirstPage > LastPage\).) = flush }
- { QUIET not
- { (Processing pages ) print 1 index =only ( through ) print dup =only
- (.) = flush
- }
- if
- }
- ifelse
-} bind def
-
-/dopdfpages { % firstpage# lastpage# dopdfpages -
- << /PDFScanRules //true >> setuserparams % set scanning rules for PDF vs. PS
- 1 exch
- { dup /Page# exch store
- QUIET not { (Page ) print dup == flush } if
- pdfgetpage pdfshowpage
- } for
- << /PDFScanRules //null >> setuserparams % restore scanning rules for PS
-} bind def
-
-/runpdfend {
- Repaired { printrepaired } if
- currentdict pdfclose
- end % temporary dict
- end % pdfdict
- end % GS_PDF_ProcSet
- PDFTopSave restore
- end % userdict
- 2 vmreclaim % couldn't hurt
-} bind def
-
-% - pdf_collection_files [temp_files] show_container
-/pdf_collection_files {
- {} //true
- Trailer /Root oget /Collection knownoget {
- /D knownoget { % We have default document in the collection
- Trailer /Root oget /Names knownoget {
- /EmbeddedFiles knownoget {
- exch nameoget dup //null ne {
- /EF knownoget {
- /F knownoget {
- //true resolvestream % {} true strm
- //null (w) .tempfile % {} true strm (name) file
- 3 -1 roll % {} true (name) file strm
- 32768 string % {} true (name) file strm (buf)
- { 3 copy readstring % {} true (name) file strm (buf) file (data) bool
- 3 1 roll % {} true (name) file strm (buf) bool file (data)
- writestring % {} true (name) file strm (buf) bool
- not { exit } if
- } loop
- pop closefile % {} true (name) file
- closefile % {} true (name)
- 3 1 roll pop pop % (name)
- .currentglobal //true .setglobal
- exch dup length string copy 1 array astore
- exch .setglobal //false
- } if
- } if
- } {
- pop
- } ifelse
- } {
- pop
- } ifelse
- } {
- pop
- } ifelse
- } if
- } if
-} bind def
-
-/runpdf { % <file> runpdf -
- //runpdfbegin exec
- //pdf_collection_files exec {
- copy_trailer_attrs
- //runpdfpagerange exec
- //dopdfpages exec
- } if
- //runpdfend exec
- {
- dup (r) file
- //runpdfbegin exec
- copy_trailer_attrs
- //runpdfpagerange exec
- //dopdfpages exec
- //runpdfend exec
- deletefile
- } forall
-} bind def
-
-currentdict /runpdfpagerange .undef
-currentdict /pdf_collection_files .undef
-
-end % systemdict
-% Redefine the procedure that the C code uses for running piped input.
-% It is OK to use { (%stdin) run } here, because a startjob cannot occur.
-/.runstdin {
- { (%stdin) run } execute0
-} bind def
-
-end % userdict
-pdfdict begin
-
-% ======================== File parsing ======================== %
-
-% Read the cross-reference and trailer sections.
-
-/traileropdict mark
- (<<) cvn { /dictlevelcount dictlevelcount 1 add store mark } bind
- (>>) cvn { { .dicttomark } stopped {
- ( **** File has unbalanced >> in trailer.\n) pdfformaterror
- } if
- /dictlevelcount dictlevelcount 1 sub def
- dictlevelcount 0 eq { exit } if
- } bind
- ([) cvn { mark } bind % ditto
- (]) cvn dup load
-% /true true % see .pdfexectoken in pdf_base.ps
-% /false false % ibid.
-% /null null % ibid.
- /R { /resolveR cvx 3 packedarray cvx } bind % see Objects below
-.dicttomark readonly def
-
-% Because of EOL conversion, lines with fixed contents might be followed
-% by one or more blanks.
-/lineeq % <filestr> <conststr> lineeq <bool>
- { anchorsearch
- { pop { ( ) anchorsearch not { () eq exit } if pop } loop }
- { pop false }
- ifelse
- } bind def
-/linene { lineeq not } bind def
-
- % Read original version (pre PDF 1.5) of the xref table.
- % Note: The position is the location of 'xref'. The current PDFfile
- % position is just after the 'XREF'.
-/readorigxref % <pos> readorigxref <trailerdict>
- {
- pop % We do not need the position.
- 0 % Initialize xref table error counter
- { PDFfile token pop % first object # or trailer
- dup /trailer eq { pop exit } if
- PDFfile pdfstring readline pop
- token pop % entry count
- % remaining must be whitespace only (otherwise this xref Size was invalid.
- exch dup length 0 ne {
- false 1 index { 32 gt { pop true exit } if } forall {
- ( **** Warning: xref subsection header has extra characters.\n)
- pdfformaterror
- /setxrefentry cvx /syntaxerror signalerror
- } if
- } if
- pop % remove last
- % This section might be adding new objects:
- % ensure that Objects and Generations are big enough.
- % stack: <err count> <first obj> <entry count>
- 2 copy add growPDFobjects
- { % stack: <err count> <obj num>
- % Read xref line
- PDFfile 20 string readstring pop % always read 20 chars.
- token pop % object position
- exch token pop % generation #
- exch token pop % n or f
- exch % stack: <err count> <obj#> <loc> <gen#> <tag> <remainder of line>
- dup length 0 ne {
- % check to make sure trailing garbage is just white space
- dup { 32 gt { 5 -1 roll 1 add 5 1 roll } if } forall % bump error count on garbage
- } if
- pop % Stack: <err count> <obj#> <loc> <gen#> <tag>
- dup /n eq { % xref line tag is /n
- pop % pop dup of line tag
- 0 3 1 roll % Set ObjectStream object number = 0
- //false setxrefentry % Save xref entry, don't change existing entries
- 3 -1 roll pop % Remove ObjectStream object onumber
- }
- { % xref line tag was not /n
- /f ne % verify that the tag was /f
- { /setxrefentry cvx /syntaxerror signalerror
- } if
- } ifelse
- pop pop % pop <obj location> and <gen num>
- % stack: <err count> <obj num>
- 1 add % increment object number
- } repeat
- pop % pop <obj #>
- } loop
- 0 ne {
- ( **** Warning: length of some xref entries is not equal to 20 bytes.\n)
- pdfformaterror
- } if
- /dictlevelcount 0 def
- PDFfile traileropdict .pdfrun
- } bind def
-
- % This dicitonary is used to read the xref dictionary. It should work for
- % reading any dictionary. dictlevelcount must contain 0.
-/xrefopdict mark
- (<<) cvn { /dictlevelcount dictlevelcount 1 add def mark } bind
- (>>) cvn { .dicttomark /dictlevelcount dictlevelcount 1 sub def
- dictlevelcount 0 eq { exit} if } bind
- ([) cvn { mark } bind % ditto
- (]) cvn dup load
-% /true true % see .pdfexectoken in pdf_base.ps
-% /false false % ibid.
-% /null null % ibid.
- /R { /resolveR cvx 3 packedarray cvx } bind % see Objects below
-.dicttomark readonly def
-
-% Get a variable length positive integer value from a stream. A value
-% of zero is returned if the count is zero.
-/getintn { % <stream> <count> getintn int
- 0 exch { 256 mul 1 index read pop add } repeat
- exch pop % Discard stream
-} bind def
-
-% This array contains handlers for processing the different types of
-% entries in the XRef stream.
-% Stack: <Xrefdict> <xref stream> <Index array> <pair loc> <obj num>
-% <field 2> <field 3>
-% The handlers leave the stack unchanged.
-/xref15entryhandlers [
- { % XRef entry type 0 - free or f type xref entry
-% (free ) print
-% (obj num: ) print 2 index pdfstring cvs print ( ) print
-% (loc: ) print 1 index pdfstring cvs print ( ) print
-% (gen: ) print dup === flush
- } bind % Do nothing for free xref entries
- % XRef entry type 1 - normal or n type xref entry
- { % field 2 = obj loc, field 3 = gen num
-% (normal ) print
-% (obj num: ) print 2 index pdfstring cvs print ( ) print
-% (loc: ) print 1 index pdfstring cvs print ( ) print
-% (gen: ) print dup === flush
- 0 3 1 roll % set stream number = 0
- //false setxrefentry
- 3 -1 roll pop % remove stream number
- } bind
- % XRef entry type 2 - compressed object type xref entry
- { % field 2 = object stream num, field 3 = index into object stream
-% (Compressed objects: ) print
-% (obj num: ) print 2 index pdfstring cvs print ( ) print
-% (field 2: ) print 1 index pdfstring cvs print ( ) print
-% (field 3: ) print dup === flush
- 0 //false setxrefentry pop % set generation number = 0
- } bind
-] def
-
- % Read the PDF 1.5 version of the xref table.
- % Note: The position is the location of the start of the dictionary object
- % In PDF 1.5, the XRef dictionary also serves as the trailer dictionary
-/readpdf15xref % <pos> readpdf15xref <trailerdict>
- {
- PDFfile exch setfileposition % move to start of object
- % Get object number, revision, and 'obj' and discard
- PDFfile token pop pop
- PDFfile token pop pop
- PDFfile token pop pop
- % Get the XRef dicitionary
- /dictlevelcount 0 def PDFfile xrefopdict .pdfrun
- % Verify that we have an XRef dictionary
- dup /Type get /XRef ne {
- /readpdf15xref cvx /syntaxerror signalerror
- } if
- % Ensure that we we have room in the objects array, etc.
- dup /Size get growPDFobjects
- % Create a stream for the XRef data
- PDFfile token pop pop % Skip over 'stream'
- dup stream false resolvestream
- % Stack: <XRefdict> <xref stream>
- % The Index array defines the ranges of object numbers in the
- % XRef stream. Each value pair is consists of starting object
- % number and the count of consecutive objects.
- % Get the Index array, if present
- 1 index /Index .knownget not { % If no Index array ...
- [ 0 3 index /Size get ] % Default = [ 0 Size ]
- } if
- % Loop through the Index array
- 0 2 2 index length 1 sub {
- % Get start and end of object range
- 2 copy get % Start of the range
- dup 3 index 3 index 1 add get % Number of entries in range
- % Loop through the range of object numbers
- add 1 sub 1 exch { % Form end of range, set increment = 1
- % Stack: <Xrefdict> <xref stream> <Index array> <pair loc> <obj num>
- % Get xref parameters. Note: The number of bytes for each parameter
- % is defined by the entries in the W array.
- 4 index /W get aload pop % Get W array values
- % The first field indicates type of entry. Get first field value.
- % If the num. of bytes for field 1 is 0 then default field value is 1
- 3 -1 roll dup 0 eq { pop 1 } { 6 index exch getintn } ifelse
- % Get the handler for the xref entry type. We will execute the
- % handler after we get the other two field values.
- xref15entryhandlers exch get
- 3 -1 roll 6 index exch getintn % Get second field
- 3 -1 roll 6 index exch getintn % Get third field
- 3 -1 roll exec % Execute Xref entry handler
- pop pop pop % Remove field values and obj num
- } for % Loop through Xref entries
- pop % Remove Index array pair loc
- } for % Loop through Index array entries
- pop pop % Remove Index array and xref stream
- } bind def
-
-% Read the cross-reference table.
-% <pos> is the position either from the startxref statement or the /Prev
-% entry in the prior trailer dictionary.
-/readxref % <pos> readxref <trailerdict>
- {
- PDFoffset add PDFfile exch
- % Check that the given location is within the file.
- dup PDFfilelen gt {
- ( **** Warning: Specified xref location is beyond end of file.\n)
- pdfformaterror
- /readxref cvx /invalidaccess signalerror
- } if
- setfileposition
- % In some PDF files, this position actually points to
- % white space before the xref line. Skip over this here.
- {
- PDFfile fileposition PDFfile read pop 32 gt { exit } if pop
- } loop
- dup % Make copy of the file position (before last char was read).
- PDFfile exch setfileposition
- % The PDF specification says that the 'xref' must be on a line
- % by itself. The code here formerly used readline and linene to
- % check this. However, Acrobat Reader only requires the line to
- % begin with 'xref', and there are enough applications producing
- % non-compliant PDF files that we have to do this too.
- PDFfile pdfstring 0 4 getinterval readstring pop
- (xref) eq
- {
- readorigxref % 'xref' -> original xref table
- % if hybrid-reference PDF, also fetch the entries
- % found in the XRef stream pointed by /XRefStm
- dup /XRefStm knownoget {
- readpdf15xref pop
- } if
- }
- { readpdf15xref } % otherwise assume PDF 1.5 xref stream
- ifelse
- } bind def
-
-% Open a PDF file and read the header, trailer, and cross-reference.
-/pdfopen { % <file> pdfopen <dict>
- % Color space substitution in PDF is handled somewhat differently
- % than in PostScript. A given device color space will be substituted
- % if the corresponding "Default..." entry exists in the Page's
- % Resource dictionary (which might be inhereted); there is no
- % UseCIEColor to enable/disable color mapping.
- %
- % This behavior is achieved by always setting UseCIEColor to true
- % in the page device dictionary. If the value of this parameter was
- % originally false (i.e.: the output device does not perform color
- % space substitution by default), the instances DefaultGray,
- % DefaultRGB, and DefaultCMYK of the (local) ColorSpace category
- % are redefined to be DeviceGray, DeviceRGB, and DeviceCMYK,
- % respectively. This is not done if UseCIEColor is true by default,
- % as in that case color substitution is presumably desired even
- % if the file does not request it.
- currentpagedevice /UseCIEColor .knownget dup { pop } if not
- { .currentglobal false .setglobal
- /DefaultGray { /DeviceGray } cvlit /ColorSpace defineresource pop
- /DefaultRGB { /DeviceRGB } cvlit /ColorSpace defineresource pop
- /DefaultCMYK { /DeviceCMYK } cvlit /ColorSpace defineresource pop
- .setglobal
- }
- if
- pdfopenfile begin
- pdfopencache
- currentdict end
-} bind def
-
-/copy_trailer_attrs { % - copy_trailer_attrs -
- writeoutputintents
- .writepdfmarks {
- % Copy bookmarks (outline) to the output.
- Trailer /Root oget /Outlines knownoget {
- /First knownoget {
- { dup writeoutline /Next knownoget not { exit } if } loop
- } if
- } if
- } if % end .writepdfmarks
-} bind def
-
-% Verify that each entry in the xref table is pointing at an object with
-% the correct object number and generation number.
-/verify_xref % - verify_xref -
-{ PDFfilelen
- 1 1 Objects llength 1 sub % stack: filesize 1 1 <number of objects - 1>
- { % Check if the object is free (i.e. not used). The values in
- % Generations is the generation number plus 1. If the value in
- % Generations is zero then the object is free.
- % Stack: <filesize> <obj num>
- Generations 1 index lget % Get the genration number
- 0 ne { % Skip if object number is free
- ObjectStream 1 index lget % Check if object is in objectstream
- 0 eq { % We only check objects not in an objectstream
- { % Use stop context since we may get an error if object is invalid
- dup Objects exch lget % Get the object location
- PDFoffset add dup 3 index ge % Compare object location to file size
- { pop true } % Rebuild if location not in file
- { PDFfile exch setfileposition % Go to the object location
- true % Stack: <filesize> <obj num> <true>
- PDFfile token pop % Read object number from file
- 2 index eq { % Verify object number
- PDFfile token pop % Read generation number from file
- Generations 3 index % Get specified generaton number
- lget 1 sub % Gen numbs are stored with 1 added.
- eq { % Verify generation number
- PDFfile token pop
- /obj eq { % Verify 'obj' text
- pop false % We have valid object, do not rebuild
- } if
- } if
- } if
- } ifelse
- } .internalstopped
- { true } if % If we stop then we need to rebuild
- % Stack: <filesize> <obj num> <need rebuild flag>
- {
- ( **** Warning: File has an invalid xref entry: )
- pdfformaterror
- pdfstring cvs pdfformaterror
- (. Rebuilding xref table.\n) pdfformaterror
- search_objects
- exit
- } if % If the entry is invalid
- } {
- % The object is in an object stream. We currently do not rebuild
- % objects in an object stream. So If we find one, then abort the
- % verification of the xref table entries.
- pop exit % Pop object number and then exit loop
- } ifelse % If not in an object stream
- } if % If object entry is not free
- pop % Remove object number
- } for
- pop % Remove the size of the file
-} bind odef
-
-/pdfopencache { % - pdfopencache -
- % Create and initialize some caches.
- /PageCount pdfpagecount def
- /PageNumbers PageCount 65534 .min dict def
- /PageIndex PageCount 65534 .min array def
-} bind def
-
-/pdfopenfile { % <file> pdfopenfile <dict>
- pdfdict readonly pop % can't do it any earlier than this
- 15 dict begin
- /LocalResources 0 dict def
- /DefaultQstate //null def % establish binding
- /Printed where { pop } {
- % Guess whether the output device is a printer.
- /Printed currentpagedevice /OutputFile known def
- } ifelse
- /PSLevel1 where { pop } { /PSLevel1 false def } ifelse
- % NB: PDFfile is used outside of the PDF code to determine that a
- % PDF job is being processed; to not change or hide this key.
- cvlit /PDFfile exch def
- /PDFsource PDFfile def
- /Repaired false def
- currentglobal true .setglobal globaldict begin
- /UndefProcList 0 dict def
- end .setglobal
- PDFfile dup 0 setfileposition
- 0 () /SubFileDecode filter % to avoid file closure
- pdfstring readstring pop
- (%PDF-) search not {/pdfopen cvx /syntaxerror signalerror} if
- length /PDFoffset exch def pop
- % some badly formed PDF's (Visioneer) have something other than EOL
- % after the version number. If we get an error, shorten the string
- % and try again.
- false exch % error encountered
- { { cvr } stopped
- { exch pop true exch 0 1 index length 1 sub dup 0 eq
- { pop 0 exit } if % exit if string now empty
- getinterval % trim character from right end and retry
- }
- { exch {
- ( **** Warning: PDF version number not followed by EOL.\n)
- pdfformaterror
- }
- if exit
- }
- ifelse
- } loop
-
- /PDFversion exch def
- % Read the last cross-reference table.
- count /pdfemptycount exch def
- /Trailer << >> def % Initialize to an emptry dict.
- { initPDFobjects findxref readxref } .internalstopped {
- recover_xref_data % Read failed. Attempt to recover xref data.
- search_trailer % Search for the primary trailer
- } {
- /Trailer exch def % Save trailer dict after first xref table
- % Read any previous cross-reference tables. When we are done,
- % verify that the entries in the xref tables are valid if NoVerifyXref
- % is not defined.
- Trailer
- { /Prev knownoget not { % If no previous xref table then ...
- /NoVerifyXref where { pop } { verify_xref } ifelse exit
- } if
- { readxref } .internalstopped {
- recover_xref_data % Read failed. Attempt to recover xref data.
- exit % Exit loop since recover gets all obj data.
- } if % If readxref stopped
- % The PDF spec. says that each trailer dict should contain the required
- % entries. However we have seen a PDF file that only has a Prev entry in
- % the initial trailer dict. Acrobat complains but it accepts these files.
- % To work with these files, we are copying any entries which we find in
- % a previous trailer dict which are not present in the initial dict.
- dup {
- Trailer 2 index known {
- pop pop % discard if key already present
- } {
- Trailer 3 1 roll put % add key if not present
- } ifelse
- } forall
- } loop % Loop to previous trailer
- } ifelse % Ifelse readxref stopped
-
- % Scan numbers in the range 2147483648..4294967295 in Encrypt dictionary
- % as unsigned integers for compatibility with Acrobat Reader. Bug 689010.
- << /PDFScanUnsigned //true >> setuserparams
- { Trailer /Encrypt knownoget {
- pop
- pdf_process_Encrypt % signal error
- } if
- } stopped
- << /PDFScanUnsigned //false >> setuserparams
- { stop } if
-
- currentdict end
- } bind def
-
-% Look for [\r\n]%%EO from the current position of the file.
-% Return the position of %%EO if found or -1 .
-/findeof { % <file> find_eof <file> <position>
- -1 exch
- {
- dup bytesavailable 4 lt { exit } if
- dup 0 (%%EO) /SubFileDecode filter flushfile
- dup dup fileposition 5 sub setfileposition
- dup 5 string readstring not { pop exit } if
- dup (\r%%EO) eq exch (\n%%EO) eq or {
- dup fileposition 4 sub
- 3 1 roll exch pop
- } if
- } loop
- exch
-} bind def
-
-% Skip backward over the %%EOF at the end of the PDF file, and read
-% the preceding startxref line. The PDF specification unambiguously
-% requires that the %%EOF appear on a line by itself, and that the
-% startxref and the following position value appear on separate lines;
-% however, some applications truncate the %%EOF to %%EO, and/or put the
-% startxref and the following value on the same line.
-% There seems to be no limit on the amount of garbage that can be
-% appended to the PDF file. Current record (60K) belongs to
-% PDF-Out (v 2.0 - 35). We start the search for %%EO from the last 1024
-% bytes and continue from the beginning of the file.
-/findxref { % - findxref <xrefpos>
- PDFfile dup dup dup 0 setfileposition bytesavailable
- dup /PDFfilelen exch def
- % Find the last %%EOF string (within 1024 bytes)
- 1024 sub PDFoffset .max
- setfileposition findeof % search the last 1024 bytes
- dup 0 le {
- pop
- dup PDFoffset setfileposition findeof % search from the beginnibg
- dup 0 le {
- ( **** Error: Cannot find a %%EOF marker anywhere in the file.\n)
- pdfformaterror
- /findxref cvx /syntaxerror signalerror
- } if
- } if
- dup 3 1 roll setfileposition
- % Stack: eofpos
- % Check for whether this is, in fact, a valid PDF file.
- dup PDFfilelen exch sub dup dup 7 gt exch 5 lt or {
- pop true
- } {
- string PDFfile exch readstring pop
- dup (%%EOF\n) eq exch dup (%%EOF\r) eq
- exch dup (%%EOF\r\n) eq exch (%%EOF) eq or or or not
- } ifelse {
- ( **** Warning: File has a corrupted %%EOF marker, or garbage after %%EOF.\n)
- pdfformaterror
- } if
- PDFfile exch setfileposition
- % Now read the startxref and xref start position.
- prevline token not { null } if dup type /integertype eq {
- exch pop cvi % xref start position
- exch PDFfile exch setfileposition
- prevline dup (startxref) linene {
- % startxref not on a line by itself. We have found PDF from
- % www.verypdf.com in which the startxref was on the same line as
- % the end of trailer dictionary. Check for this. Note: This
- % violates the spec.
- dup (startxref) search {
- % found startxref - print warning
- pop pop pop % clear strings from search
- ( **** Warning: format of the startxref line in this file is invalid.\n)
- pdfformaterror
- } { % no startxref - we have a problem.
- /findxref cvx /syntaxerror signalerror
- } ifelse
- } if
- pop pop
- } { % else, this file has 'startxref #####' format
- (startxref) ne { /findxref cvx /syntaxerror signalerror } if
- cvi % xref start position
- ( **** Warning: format of the startxref line in this file is invalid.\n)
- pdfformaterror
- exch PDFfile exch setfileposition
- } ifelse
-} bind def
-/stderrfile (%stderr) (w) file def
-/stderrprint { % <string> stderrprint -
- //stderrfile dup 3 -1 roll writestring flushfile
-} bind def
-/pdfformaterror { % <string> pdfformaterror -
- stderrprint
- /Repaired true store
-} bind def
-
-/knownoget_safe
-{ 2 copy knownoget { 3 1 roll pop pop //true } { pop pop //false } ifelse
-} odef
-
-/printProducer {
- Trailer /Info { knownoget_safe } stopped { pop pop false } if {
- /Producer knownoget not { null } if
- } {
- null
- } ifelse
- dup null eq {
- pop
- } {
- ( **** The file was produced by: \n **** >>>> ) stderrprint
- % Handle a Unicode Producer.
- (\376\377) anchorsearch {
- pop dup length 2 idiv string 0 1 2 index length 1 sub {
- % Stack: origstr newstr i
- 1 index exch 3 index 1 index 2 mul 1 add get put
- } for exch pop
- } if
- stderrprint
- ( <<<<\n) stderrprint
- } ifelse
-} bind def
-% The UndefProcList collects noisy warnings.
-% This gets rid of many multiple warnings from pdf_font.ps
-/printCollectedWarnings {
- UndefProcList length 0 gt {
- (\n **** Embedded font uses undefined procedure\(s\): ) stderrprint
- UndefProcList {
- exch .namestring stderrprint ( ) stderrprint
- =string cvs stderrprint ( times, ) stderrprint
- } forall
- (\n) stderrprint
- } if
-} bind def
-/printrepaired {
- printCollectedWarnings
- (\n **** This file had errors that were repaired or ignored.\n)
- stderrprint
- printProducer
- ( **** Please notify the author of the software that produced this\n)
- stderrprint
- ( **** file that it does not conform to Adobe's published PDF\n)
- stderrprint
- ( **** specification.\n\n)
- stderrprint
-} bind def
-
-% Write the outline structure for a file. Uses linkdest (below).
-% omit links to pages that don't exist.
-/writeoutline % <outlinedict> writeoutline -
- { mark
- 0 2 index /First knownoget
- { { exch 1 add exch /Next knownoget not { exit } if } loop }
- if
- % stack: dict mark count
- dup 0 eq
- { pop 1 index }
- { 2 index /Count knownoget { 0 lt { neg } if } if
- /Count exch 3 index
- }
- ifelse
- {
- dup /A knownoget {
- dup /URI known {
- /A mark 3 2 roll % <<>> /A [ <<action>>
- { oforce } forall
- .dicttomark
- 3 2 roll
- } {
- dup /D knownoget {
- exch pop exch dup length dict copy dup /Dest 4 -1 roll put
- } {
- /N knownoget { % Assume /S /Named
- namedactions exch .knownget { exec } if
- } if
- } ifelse
- } ifelse
- } if
- linkdest
- } stopped
- {
- cleartomark % ignore this link
- ( **** Warning: Outline has invalid link that was discarded.\n)
- pdfformaterror
- } {
- /Title oget /Title exch /OUT pdfmark
- }
- ifelse
- /First knownoget
- { { dup writeoutline /Next knownoget not { exit } if } loop }
- if
- } bind def
-
-% Close a PDF file.
-/pdfclose % <dict> pdfclose -
- { begin
- PDFfile closefile
- end
- } bind def
-
-% ======================== Page accessing ======================== %
-
-% Get a (possibly inherited) attribute of a page.
-/pget % <pagedict> <key> pget <value> -true-
- % <pagedict> <key> pget -false-
- {
- 2 copy knownoget
- { exch pop exch pop true }
- { exch /Parent knownoget
- { exch pget }
- % finally see if the key is (misplaced) in the Root Catalog dict
- { dup Trailer /Root oget exch knownoget dup {
- 3 -1 roll ( **** Warning: The /) pdfformaterror 50 string cvs pdfformaterror
- ( key is missing from the Page tree.\n) pdfformaterror
- }
- { exch pop }
- ifelse
- }
- ifelse
- }
- ifelse
- } bind def
-
-% Get the value of a resource on a given page.
-/rget { % <resname> <pagedict> <restype> rget <value> -true-
- % <resname> <pagedict> <restype> rget -false-
- LocalResources 1 index knownoget {
- 3 index knownoget
- } {
- false
- } ifelse {
- exch pop exch pop exch pop true
- } {
- exch /Resources pget {
- exch knownoget { exch knownoget } { pop false } ifelse
- } {
- pop pop false
- } ifelse
- } ifelse
-} bind def
-
-% Get the total number of pages in the document.
-/pdfpagecount % - pdfpagecount <int>
- { Trailer /Root oget /Pages oget
- dup /Count knownoget {
- dup 0 le {
- pop ( **** Warning: Invalid Page count.\n) pdfformaterror
- % find the last page and use that as the Count
- 1 1 999999999 {
- dup pdffindpage?
- exch pop
- //null eq { exit } { pop } ifelse
- } for
- 1 sub % decrement to last page that we were able to find
- 2 copy /Count exch put
- } if
- exch pop
- } {
- dup /Type oget /Page eq {
- << exch 1 array astore /Kids exch /Count 1 /Type /Pages >>
- Trailer /Root oget /Pages 3 -1 roll put
- 1
- ( **** Warning: No /Pages node. The document root directly point a page.\n)
- pdfformaterror
- } {
- ( **** Warning: Page count not found; assuming 1.\n)
- pdfformaterror
- pop 1
- } ifelse
- } ifelse
- } bind def
-
-/pdffindpage? { % <int> pdffindpage? 1 null (page not found)
- % <int> pdffindpage? 1 noderef (page found)
- % <int> pdffindpage? 0 null (Error: page not found)
- Trailer /Root oget /Pages get
- { % We should be able to tell when we reach a leaf
- % by finding a Type unequal to /Pages. Unfortunately,
- % some files distributed by Adobe lack the Type key
- % in some of the Pages nodes! Instead, we check for Kids.
- dup oforce /Kids knownoget not { exit } if
- exch pop null
- 0 1 3 index length 1 sub {
- 2 index exch get
- dup oforce dup /Kids known { /Count oget } { pop 1 } ifelse
- % Stack: index kids null noderef count
- dup 5 index ge { pop exch pop exit } if
- 5 -1 roll exch sub 4 1 roll pop
- } for exch pop
- % Stack: index null|noderef
- dup null eq { pop pop 1 null exit } if
- } loop
-} bind def
-
-% Find the N'th page of the document by iterating through the Pages tree.
-% The first page is numbered 1.
-/pdffindpageref { % <int> pdffindpage <objref>
- dup pdffindpage?
- % Stack: index countleft noderef
- 1 index 1 ne { pop pop /pdffindpage cvx /rangecheck signalerror } if
- exch pop
- PageIndex 2 index 1 sub 65533 .min 2 index oforce put
- PageNumbers 1 index oforce 3 index dup 65534 le
- { put }
- { pop pop pop } % don't store more than 65534 pagenumbers
- ifelse
- exch pop
-} bind def
-/pdffindpage { % <int> pdffindpage <pagedict>
- pdffindpageref oforce
-} bind def
-
-% Find the N'th page of the document.
-% The first page is numbered 1.
-/pdfgetpage % <int> pdfgetpage <pagedict>
- { PageIndex 1 index 1 sub dup 65533 lt
- { get }
- { pop pop null }
- ifelse
- dup null ne
- { exch pop oforce }
- { pop pdffindpage }
- ifelse
- } bind def
-
-% Find the page number of a page object (inverse of pdfgetpage).
-/pdfpagenumber % <pagedict> pdfpagenumber <int>
- { % We use the simplest and stupidest of all possible algorithms....
- PageNumbers 1 index .knownget
- { exch pop
- }
- { 1 1 PageCount 1 add % will give a rangecheck if not found
- { dup pdfgetpage oforce 2 index eq { exit } if pop
- }
- for exch pop
- }
- ifelse
- } bind def
-
-% Arrange the four elements that define a rectangle into a 'normal' order.
-/normrect_elems % <x1> <y1> <x2> <y2> normrect_elems <llx> <lly> <urx> <ury>
-{
- exch 4 1 roll % <x2> <x1> <y1> <y2>
- 2 copy gt { exch } if % <x2> <x1> <lly> <ury>
- 4 2 roll 2 copy lt { exch } if % <lly> <ury> <urx> <llx>
- 4 1 roll exch % <llx> <lly> <urx> <ury>
-} bind def
-
-% Arrange a rectangle into a 'normal' order. I.e the lower left corner
-% followed by the upper right corner.
-/normrect % <rect> normrect <rect>
-{
- aload pop normrect_elems 4 array astore
-} bind def
-
-/fix_empty_rect_elems % </Name> <x1> <y1> <x2> <y2> fix_empty_rect_elems <x1> <y1> <x2'> <y2'>
-{ dup 3 index eq { //true } { 1 index 4 index eq } ifelse {
- pop pop pop pop
- ( **** Warning: File has an empty ) pdfformaterror pdfstring cvs pdfformaterror
- (. Using the current page size instead.\n) pdfformaterror
- 0 0 currentpagedevice /PageSize get aload pop
- } {
- 5 -1 roll pop
- } ifelse
-} bind def
-
-/boxrect % <llx> <lly> <urx> <ury> boxrect <x> <y> <w> <h>
- { exch 3 index sub exch 2 index sub
- } bind def
-/resolvedest { % <name|string|other> resolvedest <other|null>
- dup type /nametype eq {
- Trailer /Root oget /Dests knownoget {
- exch knownoget not { null } if
- } {
- pop null
- } ifelse
- } {
- dup type /stringtype eq {
- Trailer /Root oget /Names knownoget {
- /Dests knownoget {
- exch nameoget
- } {
- pop null
- } ifelse
- } {
- pop null
- } ifelse
- } if
- } ifelse
-} bind def
-
-% Procedures to do the necessary transformations of view destinations
-% <PDF2PS_matrix> <rot> <view> -- <view'>
-/viewdestprocs 8 dict dup begin
- /Fit { exch pop exch pop } bind def
- /FitH {
- aload pop
- 0 4 -1 roll 1 and 0 eq { exch } if
- 4 -1 roll transform exch pop
- 2 array astore
- } bind def
- /FitV {
- aload pop
- 0 4 -1 roll 1 and 0 ne { exch } if
- 4 -1 roll transform pop
- 2 array astore
- } bind def
- /FitB /Fit load def
- /FitBH /FitH load def
- /FitBV /FitV load def
- /XYZ {
- aload pop
- 3 1 roll
- 2 copy 7 -1 roll 1 and 0 ne { exch } if 4 2 roll % odd rotation switches x<->y
- 2 { dup null eq { pop 0 } if exch } repeat % replace nulls with 0
- 7 -1 roll transform % transform coordinates
- 2 { 3 -1 roll null eq { pop null } if exch } repeat % put the nulls back
- 3 -1 roll
- 4 array astore
- } bind def
- /FitR {
- exch pop
- aload pop
- 2 { 5 index transform 4 2 roll } repeat normrect_elems
- 5 array astore
- exch pop
- } bind def
-end readonly def
-
-/linkdest { % <link|outline> linkdest
- % ([/Page <n>] /View <view> | ) <link|outline>
- dup /Dest knownoget
- { resolvedest
- dup type /dicttype eq { /D knownoget not { null } if } if
- dup null eq
- { pop }
- { dup 0 oget
- false % don't have a page# and transformation matrix (yet)
- 1 index type /dicttype eq {
- 1 index /Type knownoget {
- /Page eq {
- pop % the "false" flag
- dup pdf_cached_PDF2PS_matrix exch
- dup /Rotate pget not { 0 } if 90 idiv exch
- pdfpagenumber
- true % now we have a page# and a transformation matrix
- } if
- } if
- } if
- % stack: <link|outline> <dest> ( <PDF2PS_matrix> <rot> <page#> true | <page> false )
- {
- /Page exch 6 2 roll
- % stack: [/Page <page#>] <link|outline> <dest> <PDF2PS_matrix> <rot>
- 3 -1 roll dup length 1 sub 1 exch getinterval /View 4 1 roll
- % stack: [/Page <page#>] <link|outline> /View <PDF2PS_matrix> <rot> <view>
- //viewdestprocs 1 index 0 get get exec
- 3 -1 roll
- } {
- pop
- dup length 1 sub 1 exch getinterval /View exch 3 -1 roll
- } ifelse
- }
- ifelse
- }
- if
-} bind def
-% <pagedict> mark ... -proc- <page#> <error>
-/namedactions 8 dict dup begin
- /FirstPage { 1 //false } def
- /LastPage { pdfpagecount //false } def
- /NextPage { counttomark 2 add index pdfpagenumber 1 add dup pdfpagecount gt } bind def
- /PrevPage { counttomark 2 add index pdfpagenumber 1 sub dup 1 lt } bind def
-end readonly def
-% <pagedict> <annotdict> -proc- -
-/annottypes 5 dict dup begin
- /Text {
- mark exch
- { /Rect /Open /Contents }
- { 2 copy knownoget { 3 -1 roll } { pop } ifelse }
- forall pop /ANN pdfmark
- } bind def
- /Link {
- mark exch
- dup /C knownoget { /Color exch 3 -1 roll } if
- { /Rect /Border }
- { 2 copy knownoget { 3 -1 roll } { pop } ifelse }
- forall dup /A knownoget {
- dup /URI known {
- /A mark 3 2 roll % <<>> /A [ <<action>>
- { oforce } forall
- .dicttomark
- 3 2 roll
- } {
- dup /D knownoget {
- exch pop exch dup length dict copy dup /Dest 4 -1 roll put
- } {
- /N knownoget { % Assume /S /Named
- namedactions exch .knownget {
- exec {
- pop
- ( **** Warning: Ignoring a named action pointing out of the document page range.\n)
- pdfformaterror
- } {
- /Page exch 3 -1 roll
- } ifelse
- } if
- } if
- } ifelse
- } ifelse
- } if
- linkdest pop /LNK pdfmark
- } bind def
-end readonly def
-
-% **** The following procedure should not be changed to allow clients
-% **** to directly interface with the constituent procedures. GSview
-% **** and some Artifex customers rely on the pdfshowpage_init,
-% **** pdfshowpage_setpage, pdfshowpage_finish so all logic should be
-% **** implemented in one of those three procedures.
-/pdfshowpage % <pagedict> pdfshowpage -
- { dup /Page exch store
- pdfshowpage_init
- pdfshowpage_setpage
- pdfshowpage_finish
- } bind def
-
-/pdfpagecontents % <pagedict> pdfpagecontents <contents>
- { } bind def
-
-/pdfshowpage_init % <pagedict> pdfshowpage_init <pagedict>
- { /DSCPageCount DSCPageCount 1 add store
- } bind def
-
-/get_media_box { % <pagedict> get_media_box <box>
- /MediaBox pget not {
- ( **** Page has no /MediaBox attribute. Using the current page size.\n)
- pdfformaterror
- [ 0 0 currentpagedevice /PageSize get aload pop ]
- } if
-} bind def
-
-% Compute the matrix that transforms the PDF->PS "default" user space
-/pdf_PDF2PS_matrix { % <pdfpagedict> -- matrix
- matrix currentmatrix matrix setmatrix exch
- % stack: savedCTM <pdfpagedict>
- dup /CropBox pget dup {exch pop} if //systemdict /UseCropBox known and {
- /CropBox 2 copy pget pop
- } {
- /MediaBox 1 index get_media_box
- } ifelse
- % stack: savedCTM <pdfpagedict> /Crop|MediaBox <Crop|Media Box>
- oforce_elems normrect_elems fix_empty_rect_elems 4 array astore
- //systemdict /PDFFitPage known {
- PDFDEBUG { (Fiting PDF to imageable area of the page.) = flush } if
- currentpagedevice /.HWMargins get aload pop
- currentpagedevice /PageSize get aload pop
- % Adjust PageSize and .HWMargins for the page portrait/landscape orientation
- 2 copy gt
- 7 index aload pop 3 -1 roll sub 3 1 roll exch sub exch
- 10 index /Rotate pget not { 0 } if 90 idiv 1 and 0 ne { exch } if
- gt
- ne {
- 2 copy ne {
- % rotate the .HWMargins
- 2 copy lt {
- 6 2 roll 4 -1 roll 6 -2 roll
- } {
- 6 2 roll 4 1 roll 6 -2 roll
- } ifelse
- % rotate the page dimensions
- exch
- } if
- } if
- 3 -1 roll sub 3 1 roll exch sub exch
- % stack: savedCTM <pdfpagedict> <Crop|Media Box> Xmin Ymin Xmax Ymax
- PDFDEBUG { ( Translate up by [ ) print 3 index =print (, ) print 2 index =print ( ]) = flush } if
- 3 index 3 index translate % move origin up to imageable area
- 2 index sub exch 3 index sub exch 4 2 roll pop pop
- % stack: savedCTM <pdfpagedict> [Box] XImageable YImageable
- 2 index aload pop 2 index sub exch 3 index sub exch 4 2 roll pop pop
- 5 index /Rotate pget not { 0 } if 90 idiv 1 and 0 ne { exch } if
- % stack: savedCTM <pdfpagedict> [Box] XImageable YImageable XBox YBox
- 3 -1 roll exch div 3 1 roll div .min
- PDFDEBUG { ( Scale by ) print dup = flush } if
- } {
- //systemdict /NoUserUnit .knownget not { false } if {
- 1
- } {
- 1 index /UserUnit knownoget {
- PDFDEBUG { (Scaling due to UserUnit by ) print dup = flush } if
- } {
- 1
- } ifelse
- } ifelse
- } ifelse
- % stack: savedCTM <pdfpagedict> [Box] scale
- dup scale
- % Rotate according to /Rotate
- aload pop boxrect
- {
- { pop pop }
- { -90 rotate pop neg 0 translate }
- { 180 rotate neg exch neg exch translate }
- { 90 rotate neg 0 exch translate pop }
- }
- 5 index /Rotate pget not { 0 } if
- PDFDEBUG { dup 0 ne { (Rotating by ) print dup =print ( degrees.) = flush } if } if
- 90 idiv 3 and get exec
- % Now translate to the origin given in the Crop|Media Box
- exch neg exch neg translate
- % stack: savedCTM <pdfpagedict>
- pop
- matrix currentmatrix exch setmatrix
-} bind def
-
-% Cache the matrix that transforms the PDF->PS "default" user space
-% into <pdfpagedict> under the key //PDF2PS_matrix_key, then return it
-/PDF2PS_matrix_key (PDF->PS matrix) cvn def
-/pdf_cached_PDF2PS_matrix { % <pdfpagedict> -- <PDF2PS_matrix>
- dup //PDF2PS_matrix_key .knownget {
- exch pop
- } {
- dup dup pdf_PDF2PS_matrix //PDF2PS_matrix_key exch put
- //PDF2PS_matrix_key get
- } ifelse
-} bind def
-currentdict /PDF2PS_matrix_key undef
-
-/.pdfshowpage_Install { % <pagedict> [<prevproc>] .pdfshowpage_Install -
- exch pdf_cached_PDF2PS_matrix concat
- 0 get exec
-} bind def
-
-/pdfshowpage_setpage { % <pagedict> pdfshowpage_setpage <pagedict>
- 5 dict begin % for setpagedevice
- % Stack: pdfpagedict
- % UseCIEColor is always true for PDF; see the comment in runpdf above
- /UseCIEColor true def
- /Orientation 0 def
- currentpagedevice
- % Stack: pdfpagedict currentpagedevicedict
- 1 index /CropBox pget dup {exch pop} if //systemdict /UseCropBox known and {
- /CropBox 2 index /CropBox pget % will use the CropBox
- } {
- /MediaBox 2 index get_media_box true % will use the MediaBox
- } ifelse
- {
- oforce_elems normrect_elems fix_empty_rect_elems boxrect 4 2 roll pop pop
- 3 index /Rotate pget not { 0 } if 90 idiv 1 and 0 ne { exch } if
- % stack: pdfpagedict currentpagedevicedict boxwidth boxheight
- //systemdict /PDFFitPage known {
- % Preserve page size,
- % but choose portrait/landscape depending on box width:height ratio
- % (if box width == height, select portrait orientation)
- gt
- 1 index /PageSize get aload pop
- 2 copy gt
- 4 -1 roll ne { exch } if
- } {
- % Set the page size.
- //systemdict /NoUserUnit .knownget not { false } if not {
- 3 index /UserUnit knownoget {
- dup 4 -1 roll mul 3 1 roll mul
- } if
- } if
- } ifelse
- 2 array astore /PageSize exch def
- } {
- pop % pops /Crop|MediaBox
- } ifelse
- % Determine the number of spot colors used on the page. Note: This searches
- % the pages resources. It may be high if a spot color is in a resource but
- % is not actually used on the page.
- << /PageSpotColors 3 index countspotcolors >> setpagedevice
-
- % Let the device know if we will be using PDF 1.4 transparency.
- % The clist logic may need to adjust the size of bands.
- 1 index pageusestransparency /PageUsesTransparency exch def
- dup /Install .knownget {
- % Don't let the Install procedure get more deeply
- % nested after every page.
- dup type dup /arraytype eq exch /packedarraytype eq or {
- dup length 4 eq {
- dup 2 get /.pdfshowpage_Install load eq {
- 1 get 0 get % previous procedure
- } if
- } if
- } if
- } {
- { }
- } ifelse 1 array astore
- 2 index exch /.pdfshowpage_Install load /exec load
- 4 packedarray cvx
- % Stack: pagedict currentpagedict installproc
- /Install exch def
- % Stack: pagedict currentpagedict
- pop currentdict end setpagedevice
-} bind def
-
-/.free_page_resources { % - .free_page_resources -
- Page /Resources pget {
- /Shading knownoget {
- { dup type /dicttype eq {
- dup /.shading_dict known {
- dup /.shading_dict undef
- } if
- } if
- pop pop
- } forall
- } if
- } if
-} bind def
-
-/pdfshowpage_finish { % <pagedict> pdfshowpage_finish -
- save /PDFSave exch store
- /PDFdictstackcount countdictstack store
- (before exec) VMDEBUG
-
- % set up color space substitution (this must be inside the page save)
- pdfshowpage_setcspacesub
-
- .writepdfmarks {
-
- % Copy the crop box.
- dup /CropBox pget {
- % .pdfshowpage_Install transforms the user space -
- % do same here with the CropBox.
- oforce_elems
- 2 { Page pdf_cached_PDF2PS_matrix transform 4 2 roll } repeat
- normrect_elems /CropBox 5 1 roll fix_empty_rect_elems 4 array astore
- mark /CropBox 3 -1 roll
- /PAGE pdfmark
- } if
-
- % Copy annotations and links.
- dup /Annots knownoget {
- 0 1 2 index length 1 sub
- { 1 index exch oget
- dup /Subtype oget annottypes exch .knownget { exec } { pop } ifelse
- }
- for pop
- } if
-
- } if % end .writepdfmarks
-
- % Display the actual page contents.
- 6 dict begin
- /BXlevel 0 def
- /BGDefault currentblackgeneration def
- /UCRDefault currentundercolorremoval def
- %****** DOESN'T HANDLE COLOR TRANSFER YET ******
- /TRDefault currenttransfer def
- matrix currentmatrix 2 dict
- 2 index /CropBox pget {
- oforce_elems normrect_elems boxrect
- 4 array astore 1 index /ClipRect 3 -1 roll put
- } if
- dictbeginpage setmatrix
- /DefaultQstate qstate store
-
- count 1 sub /pdfemptycount exch store
- % If the page uses any transparency features, show it within
- % a transparency group.
- dup pageusestransparency dup /PDFusingtransparency exch def {
- % Show the page within a PDF 1.4 device filter.
- 0 .pushpdf14devicefilter {
- /DefaultQstate qstate store % device has changed -- reset DefaultQstate
- % If the page has a Group, enclose contents in transparency group.
- % (Adobe Tech Note 5407, sec 9.2)
- dup /Group knownoget {
- 1 index /CropBox pget {
- /CropBox exch
- } {
- 1 index get_media_box /MediaBox exch
- } ifelse
- oforce_elems normrect_elems fix_empty_rect_elems 4 array astore .beginformgroup {
- showpagecontents
- } stopped {
- .discardtransparencygroup stop
- } if .endtransparencygroup
- } {
- showpagecontents
- } ifelse
- } stopped {
- % todo: discard
- .poppdf14devicefilter
- /DefaultQstate qstate store % device has changed -- reset DefaultQstate
- stop
- } if .poppdf14devicefilter
- /DefaultQstate qstate store % device has changed -- reset DefaultQstate
- } {
- showpagecontents
- } ifelse
- .free_page_resources
- % todo: mixing drawing ops outside the device filter could cause
- % problems, for example with the pnga device.
- endpage
- end % scratch dict
- % Indicate that the number of spot colors is unknown in case the next page
- % imaged is a PS file.
- << /PageSpotColors -1 >> setpagedevice
- % Some PDF files don't have matching q/Q (gsave/grestore) so we need
- % to clean up any left over dicts from the dictstack
- countdictstack PDFdictstackcount sub dup 0 ne {
- ( **** Warning: File has imbalanced q/Q operators \(too many q's\)\n)
- pdfformaterror
- { end } repeat
- } {
- pop
- } ifelse
- (after exec) VMDEBUG
- Repaired % pass Repaired state around the restore
- PDFSave restore
- /Repaired exch def
-} bind def
-
-% Display the contents of a page (including annotations).
-/showpagecontents { % <pagedict> showpagecontents -
- dup % Save the pagedict for the Annotations
- count 1 sub /pdfemptycount exch store
- gsave % preserve gstate for Annotations later
- /Contents knownoget not { 0 array } if
- dup type /arraytype ne { 1 array astore } if {
- oforce false resolvestream pdfopdict .pdfrun
- } forall
- % check for extra garbage on the ostack and clean it up
- count pdfemptycount sub dup 0 ne {
- ( **** File did not complete the page properly and may be damaged.\n)
- pdfformaterror
- { pop } repeat
- } {
- pop
- } ifelse
- grestore
- % Draw the annotations
- //systemdict /ShowAnnots .knownget not { //true } if {
- /Annots knownoget { { oforce drawannot } forall } if
- } if
- //systemdict /ShowAcroForm .knownget { //true eq } { //false } ifelse {
- Trailer /Root oget /AcroForm knownoget { draw_acro_form } if
- } if
-} bind def
-
-/processcolorspace { % - processcolorspace <colorspace>
- % The following is per the PLRM3.
- currentdevice 1 dict dup /ProcessColorModel dup put .getdeviceparams
- exch pop exch pop
- dup type /nametype ne { cvn } if
- dup { setcolorspace } .internalstopped { pop /DeviceRGB } if
-} bind def
-
-% ------ Transparency support ------ %
-
-% Define minimum PDF version for checking for transparency features.
-% Transparency is a 1.4 feature however we have seen files that claimed
-% to be PDF 1.2 with transparency features. Bug 689288.
-/PDFtransparencyversion 1.2 def
-
-% Determine whether a page might invoke any transparency features:
-% - Non-default BM, ca, CA, or SMask in an ExtGState
-% - Image XObject with SMask
-% Note: we deliberately don't check to see whether a Group is defined,
-% because Adobe Illustrator 10 (and possibly other applications) define
-% a page-level group whether transparency is actually used or not.
-% Ignoring the presence of Group is justified because, in the absence
-% of any other transparency features, they have no effect.
-/pageusestransparency { % <pagedict> pageusestransparency <bool>
- PDFversion PDFtransparencyversion lt NOTRANSPARENCY or {
- pop false
- } {
- dup false exch {
- 4 dict 1 index resourceusestransparency { pop not exit } if
- /Parent knownoget not { exit } if
- } loop
- % Also check for transparency in the annotation (if not in resources).
- { pop true } { annotsusetransparency } ifelse
- } ifelse
-} bind def
-
-% Check if transparency is specified in an ExtGState dict
-/extgstateusestransparency { % <gstate dict> extgstateusestransparency <bool>
- false exch % Assume no transparency
- { % establish loop context
- exch pop oforce
- dup /BM knownoget { dup /Normal ne exch /Compatible ne and
- { pop not exit } if
- } if
- dup /ca knownoget { 1 ne { pop not exit } if } if
- dup /CA knownoget { 1 ne { pop not exit } if } if
- dup /SMask knownoget { /None ne { pop not exit } if } if
- pop
- } forall
-} bind def
-
-% Check the Resources of a page or Form. Check for loops in the resource chain.
-/resourceusestransparency { % <dict> <dict> resourceusestransparency <bool>
- { % Use loop to provide an exitable context.
- /Resources knownoget not { 0 dict } if
- 2 copy .knownget {
- { % Some circular references may be missed because scanning stops
- % when the 1st transparency is found.
- ( **** File has circular references in resource dictionaries.\n)
- pdfformaterror
- } if
- pop //false exit
- } if
- 2 copy //true put % In the current chain.
- dup /ExtGState knownoget {
- extgstateusestransparency
- { pop //true exit } if
- } if
- dup /XObject knownoget {
- //false exch {
- exch pop oforce dup /Subtype get
- dup /Image eq { 1 index /SMask known { pop pop not exit } if } if
- /Form eq {
- 3 index exch resourceusestransparency { not exit } if
- } {
- pop
- } ifelse
- } forall { pop //true exit } if
- } if
- 2 copy //false put % Visited but not in the current chain.
- pop //false exit
- } loop
- exch pop
-} bind def
-
-% Check if the annotations on a page use transparency
-/annotsusetransparency { % <page dict> annotsusetransparency <bool>
- false exch % Assume no transparency
- /Annots knownoget { % Get Annots array
- { oforce /AP knownoget { % Get appearance dict for the annoation
- /N knownoget { % Get the /N (i.e. normal) appearance stream
- /Resources knownoget {
- /ExtGState knownoget {
- extgstateusestransparency { pop true exit} if
- } if % If ExtGState known
- } if % If Resources known
- } if % If annotation has a normal appearance
- } if % If AP dict known
- } forall % For all annots on the page
- } if
-} bind def
-
-% Add a color name to our spot color list. Ignore /All and /None
-/putspotcolor { % <name> <spotcolordict> putspotcolor -
- % The 'name' could be a string. If so then convert to a name.
- exch dup type /stringtype eq { cvn } if
- dup dup /None eq exch /All eq or { pop pop } { 0 put } ifelse
-} bind def
-
-% Determine which spot colors are used within a color space Note: This
-% dict will include all colors used in Separation or DeviceN color spaces.
-% Thus it may include Cyan, Magenta, Yellow, and Black.
-% <colorspace> <spotcolordict> colorspacespotcolors -
-/colorspacespotcolors {
- exch dup type /arraytype eq {
- % If we have an Indexed color space then get the base space.
- dup 0 oget dup /Indexed eq {
- pop 1 oget 2 copy colorspacespotcolors
- } {
- % Stack: <spotcolordict> <colorspace> <colorspacetype>
- dup /Separation eq exch /DeviceN eq or {
- dup 1 oget dup type /arraytype eq {
- { oforce 2 index putspotcolor } forall
- } {
- 2 index putspotcolor
- } ifelse
- } if
- } ifelse
- } if
- pop pop
-} bind def
-
-% Check the Resources of a page, form, or annotation. Determine which spot
-% colors are used within the resource Note: The spot color dict will include
-% all colors used in Separation or DeviceN color spaces. Thus it may include
-% Cyan, Magenta, Yellow, and Black. We also pass a dict that is used to check
-% for loops in the resource list.
-% <spotcolordict> <loopdict> <page/form/annot dict>
-% resourcespotcolors <spotcolordict> <loopdict>
-/resourcespotcolors {
- { % Use loop to provide an exitable context.
- % Exit if no Resources entry
- /Resources knownoget not { exit } if
- % Exit if we have already seen this dict
- 2 copy known { pop exit } if
-
- % Save the Resources dict into our loop checking dict.
- 2 copy 0 put
-
- % Scan resources that might contain a color space.
- dup /ColorSpace knownoget {
- { exch pop oforce 3 index colorspacespotcolors } forall
- } if
- dup /Pattern knownoget {
- { exch pop oforce 4 copy exch pop resourcespotcolors pop pop pop } forall
- } if
- dup /Shading knownoget {
- { exch pop oforce /ColorSpace oget 3 index colorspacespotcolors } forall
- } if
- /XObject knownoget {
- { exch pop oforce dup
- /Subtype get /Form eq { resourcespotcolors } { pop } ifelse
- } forall
- } if
- exit
- } loop
-} bind def
-
-% Determine which spot colors are used within the annotations. Note: This
-% dict will include all colors used in Separation or DeviceN color spaces.
-% Thus it may include Cyan, Magenta, Yellow, and Black.
-% <spotcolordict> <loopdict> <annotsarray>
-% annotsspotcolors <spotcolordict> <loopdict>
-/annotsspotcolors {
- { oforce /AP knownoget { % Get appearance dict for the annoation
- /N knownoget { % Get the /N (i.e. normal) appearance stream
- resourcespotcolors
- } if % If normal appearance streamknown
- } if % If AP dict known
- } forall
-} bind def
-
-% Determine spot colors are used within a page. We are creating a dict to
-% hold the spot color names as keys. Using a dict avoids having to worry
-% about duplicate entries. The keys in the dict contain the spot color
-% names. However the values have no meaning. Note: This dict will include
-% all colors used in Separation or DeviceN color spaces specified in the
-% page's resources. Thus it may include Cyan, Magenta, Yellow, and Black.
-% There is no attempt to verify that these color spaces are actually used
-% within the object streams for the page.
-/pagespotcolors { % <pagedict> pagespotcolors <spotcolordict>
- dup
- % Create a dict to hold spot color names.
- 0 dict exch
- % Create a dict to be used to check for reference loops.
- 4 dict exch
- % Check for color spaces in the Resources
- resourcespotcolors
- % Also check for color spaces in the annotations.
- 3 -1 roll
- /Annots knownoget { annotsspotcolors } if
- pop % Discard reference loop dict
-} bind def
-
-% Determine how many (if any) spot colors are used by a page.
-% Note: This count does not include Cyan, Magenta, Yellow, or Black
-/countspotcolors { % <pagedict> countspotcolors <count>
- pagespotcolors % Get dict with all spot colors
- dup length % spot color dict length
- % Remove CMYK from the spot color count.
- [ /Cyan /Magenta /Yellow /Black ]
- { 2 index exch known { 1 sub } if } forall
- exch pop % Remove spot color dict
-} bind def
-
-% ------ ColorSpace substitution support ------ %
-
-%
-% <pagedict> pdfshowpage_setcspacesub <pagedict>
-%
-% Set up color space substitution for a page. Invocations of this procedure
-% must be bracketed by the save/restore operation for the page, to avoid
-% unintended effects on other pages.
-%
-% If any color space substitution is used, and the current color space is a
-% device dependent color space, make sure the current color space is updated.
-% There is an optimization in the setcolorspace pseudo-operator that does
-% nothing if both the current and operand color spaces are the same. For
-% PostScript this optimization is disabled if the UseCIEColor page device
-% parameter is true. This is not the case for PDF, as performance suffers
-% significantly on some PDF files if color spaces are set repeatedly. Hence,
-% if color space substitution is to be used, and the current color space
-% is a device dependent color space, we must make sure to "transition" the
-% current color space.
-%
-/pdfshowpage_setcspacesub
- {
- false
- { /DefaultGray /DefaultRGB /DefaultCMYK }
- {
- dup 3 index /ColorSpace //rget exec
- { resolvecolorspace /ColorSpace defineresource pop }
- { pop }
- ifelse
- }
- forall
-
- % if using color space substitution, "transition" the current color space
- {
- currentcolorspace dup length 1 eq % always an array
- {
- 0 get
- dup /DeviceGray eq 1 index /DeviceRGB eq or 1 index /DeviceCMYK or
- { /Pattern setcolorspace setcolorspace }
- { pop }
- ifelse
- }
- { pop }
- if
- }
- if
- }
-bind def
-
-% Write OutputIntents to device if the device handles it
-/writeoutputintents {
- currentdevice 1 dict dup /OutputIntent null put readonly
- .getdeviceparams
- mark ne { pop pop
- % device supports OutputIntent parameter
- Trailer /Root oget /OutputIntents knownoget {
- { % process all output profiles present
- oforce
- dup length dict .copydict
- dup /DestOutputProfile knownoget {
- PDFfile fileposition exch
- mark exch { oforce } forall .dicttomark
- true resolvestream
- [ { counttomark 1 add index
- 64000 string readstring
- not { exit} if
- } loop
- ] exch closefile
- 0 1 index { length add } forall .bytestring
- 0 3 2 roll {
- 3 copy putinterval
- length add
- } forall pop
- exch PDFfile exch setfileposition
- 1 index /DestOutputProfile 3 2 roll put
- } if
- % Convert to string array because it's easier for the device
- [ 1 index /OutputCondition knownoget not { () } if
- 2 index /OutputConditionIdentifier knownoget not { () } if
- 3 index /RegistryName knownoget not { () } if
- 4 index /Info knownoget not { () } if
- 5 index /DestOutputProfile knownoget not { () } if
- ]
- [ /OutputIntent 3 2 roll .pdfputparams pop pop
- pop % done with this OutputIntent dictionary
- } forall
- } if % OutputIntents known
- % tell device there are no more OutputIntents
- [ /OutputIntent [ ] .pdfputparams pop pop
- } if
-} bind def
-
-end % pdfdict
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/pdf_ops.ps b/Master/tlpkg/tlgs/lib/pdf_ops.ps deleted file mode 100644 index 6f286041a98..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf_ops.ps +++ /dev/null @@ -1,847 +0,0 @@ -% Copyright (C) 1994, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdf_ops.ps 8554 2008-02-27 19:36:18Z leonardo $
-% Definitions for most of the PDF operators.
-
-.currentglobal true .setglobal
-
-% Define pdfmark. Don't allow it to be bound in.
-% Also don't define it in systemdict, because this leads some Adobe code
-% to think this interpreter is a distiller.
-% (If this interpreter really is a distiller, don't do this.)
-systemdict /pdfmark known not
- { userdict /pdfmark { cleartomark } bind put } if
-
-userdict /GS_PDF_ProcSet 127 dict dup begin
-
-% ---------------- Abbreviations ---------------- %
-
-/bdef { bind def } bind def
-
-% ---------------- Graphics state stack ---------------- %
-
-% PDF adds a number of parameters to the graphics state.
-% We implement this by pushing and popping a dictionary
-% each time we do a PDF gsave or grestore.
-% The keys in this dictionary are as follows:
-% self % identifies the dictionary as one of ours
-% ClipRect % (optional)
-% Show
-% TextSaveMatrix % matrix at time of BT (iff within BT/ET)
-% (The following correspond directly to PDF state parameters.)
-% AlphaIsShape
-% FillConstantAlpha
-% FillColor
-% FillColorSpace
-% FillOverprint
-% SoftMask
-% StrokeConstantAlpha
-% StrokeColor
-% StrokeColorSpace
-% StrokeOverprint
-% TextSpacing
-% TextHScaling
-% Leading
-% TextFont
-% TextLineMatrix
-% TextMatrix
-% TextRise
-% TextRenderingMode
-% WordSpacing
-% (The following is cached information derived from other graphics state params)
-% FontMatrixNonHV % TextFont.FontMatrix alters horz/vert glyph advance vector direction
-
-/nodict 1 dict def
-nodict /self { //nodict } executeonly put
-nodict readonly pop
-
-/dictbeginpage { % <initialdict> dictbeginpage -
- //nodict 20 dict .copydict begin { def } forall
- graphicsbeginpage textbeginpage
-} bdef
-/endpage { % - endpage -
- showpage end
-} bdef
-
-/graphicsbeginpage {
- initgraphics
- //true .setaccuratecurves
- currentdict /ClipRect knownoget { aload pop rectclip } if
- 0 g 0 G false op false OP 0 OPM
- 1 ca 1 CA null SMask false AIS /Compatible BM true TK
-} bdef
-
-/gput % <value> <key> gput -
- { exch currentdict //nodict eq { /self dup load end 5 dict begin def } if
- % If we're in a Level 1 system, we need to grow the
- % dictionary explicitly.
- currentdict length currentdict maxlength ge %eq
- { currentdict dup length 3 mul 2 idiv 1 add dict .copydict end begin
- }
- if def
- } bdef
-
-% Restore graphics state, but do not modify path. Paths are not part
-% of the PDF graphics state; see 4.4.1 of PDF reference 3rd ed.
-/grestore_nopath {
- % Collect the upath with an identity CTM
- matrix setmatrix .getpath
- % Save the CTM, set identity during the uappend, then set the CTM
- grestore matrix currentmatrix matrix setmatrix
- exch newpath { exec } forall setmatrix
-} bdef
-
-/q {
- gsave //nodict begin
-} bdef
-% Some PDF files have excess Q operators!
-/Q {
- currentdict /self .knownget {
- exec //nodict eq { end grestore_nopath false } { true } ifelse
- } {
- true % formaterror -- not a gsave dict
- } ifelse
- { (\n **** File has imbalanced q/Q operators \(too many Q's\) ****\n)
- pdfformaterror
- } if
-} bdef
-
-% Save PDF gstate
-/qstate { % - qstate <qstate>
- gstate
-} bdef
-
-% Set PDF gstate
-/setqstate { % <qstate> setqstate -
- { matrix setmatrix //false upath } stopped {
- pop setgstate newpath
- } {
- % Save the CTM, set identity during the uappend, then set the CTM
- exch setgstate matrix currentmatrix matrix setmatrix
- exch newpath uappend setmatrix
- } ifelse
-} bdef
-
-% ---------------- Color setting ---------------- %
-
-/fcput % <color> <colorspace> fcput -
- { /FillColorSpace gput /FillColor gput
- } bdef
-/scput % <color> <colorspace> scput -
- { /StrokeColorSpace gput /StrokeColor gput
- } bdef
-/csput % <colorspace> csput -
- { csset 2 copy fcput scput
- } bdef
-
-/csdevgray [/DeviceGray] readonly def
-/csdevrgb [/DeviceRGB] readonly def
-/csdevcmyk [/DeviceCMYK] readonly def
-/cspattern [/Pattern] readonly def
-/nullpattern1 mark
- /PatternType 1 /PaintType 1 /TilingType 3 /BBox [0 0 1 1]
- /XStep 1 /YStep 1 /PaintProc { pop } bind
-.dicttomark readonly def
-/nullpattern2 nullpattern1 dup length dict copy readonly def
-
-% Each entry in the color space dictionary is a procedure of the form
-% <cspace> -proc- <cspace> <initial-color>
-/CSdict mark
- /DeviceGray { pop //csdevgray 0 } bind
- /DeviceRGB { pop //csdevrgb [0 0 0] cvx } bind
- /DeviceCMYK { pop //csdevcmyk [0 0 0 1] cvx } bind
- /CIEBasedA { 0 } bind
- /CIEBasedABC { [0 0 0] cvx } bind
- /ICCBased { [ 1 index 1 oget /N get { 0 } repeat ] cvx } bind
- /Separation { 1 } bind
- /DeviceN { % What is the correct value??
- [ 1 index 1 get length { 1 } repeat ] cvx
- } bind
- /Indexed { 0 } bind
- /Pattern {
- dup type /nametype eq 1 index length 1 eq or {
- pop //cspattern //nullpattern1 matrix makepattern
- } {
- //nullpattern2 matrix makepattern 1 index 1 get csset
- % Stack: patternspace nullpattern basecolor basespace
- pop [ 3 1 roll dup type /arraytype eq { aload pop } if
- counttomark -1 roll ] cvx
- } ifelse
- } bind
-.dicttomark readonly def
-/csset % <cspace> csset <color> <cspace>
- { dup dup type /nametype ne { 0 get } if //CSdict exch get exec exch
- } bdef
-
-/g { //csdevgray fcput } bdef
-/G { //csdevgray scput } bdef
-/rg { 3 array astore cvx //csdevrgb fcput } bdef
-/RG { 3 array astore cvx //csdevrgb scput } bdef
-/k { 4 array astore cvx //csdevcmyk fcput } bdef
-/K { 4 array astore cvx //csdevcmyk scput } bdef
-/cs { csset fcput } bdef
-/CS { csset scput } bdef
-/ri { //.renderingintentdict exch .knownget { .setrenderingintent } if } bdef
-% We have to break up sc according to the number of operands.
-/sc1 { /FillColor gput } bdef
-/SC1 { /StrokeColor gput } bdef
-% We have to avoid storing into a color array associated with an outer
-% gsave level, so we do a kind of "copy on write".
-/sc* {
- currentdict /FillColor .knownget {
- astore pop
- } {
- /FillColor load
- % FillColor may contain either a single value or an array.
- dup type /arraytype eq { length }{ pop 1 } ifelse
- array astore cvx /FillColor gput
- } ifelse
-} bdef
-/SC* {
- currentdict /StrokeColor .knownget {
- astore pop
- } {
- /StrokeColor load
- % StrokeColor may contain either a single value or an array.
- dup type /arraytype eq { length }{ pop 1 } ifelse
- array astore cvx /StrokeColor gput
- } ifelse
-} bdef
-
-% ---------------- Overprint/transparency setting ---------------- %
-
-/op { /FillOverprint gput } bdef
-/OP { /StrokeOverprint gput } bdef
-/OPM {
- /.setoverprintmode where { pop .setoverprintmode } { pop } ifelse
-} bdef
-/ca { /FillConstantAlpha gput } bdef
-/CA { /StrokeConstantAlpha gput } bdef
-/SMask { /SoftMask gput } bdef
-/AIS { /AlphaIsShape gput } bdef
-/BM {
- /.setblendmode where {
- pop [ exch dup type /nametype ne { aload pop } if /Normal ] {
- { .setblendmode } .internalstopped not { exit } if pop
- } forall
- } {
- pop
- } ifelse
-} bdef
-/TK {
- /.settextknockout where { pop .settextknockout } { pop } ifelse
-} bdef
-
-% ---------------- Color installation ---------------- %
-
-% Establish a given color (and color space) as current.
-/.settransparencyparams { % <alpha> <smask> .settransparencyparams -
- PDFusingtransparency {
- /.begintransparencygroup where {
- pop AlphaIsShape {
- 1 .setopacityalpha exch .setshapealpha 1
- } {
- 1 .setshapealpha exch .setopacityalpha 0
- } ifelse
- % Set the soft mask by rendering the XObject. Doing this every time
- % is obviously very inefficient; we'll improve it later.
- .settransparencymask
- } {
- pop pop
- } ifelse
- } {
- pop pop
- } ifelse
-} bdef
-/.settransparencymask { % <paramdict> <masknum> .settransparencymask -
- exch dup null eq {
- PDFusingtransparency {
- pop pop
- } {
- dup /Draw get exec
- } ifelse
- } {
- dup /Draw get exec
- } ifelse
-} bdef
-% (Non-mask) images must execute setfillblend.
-/setfillblend {
- FillOverprint setoverprint
- FillConstantAlpha SoftMask .settransparencyparams
-} def
-/setfillstate {
- FillColor FillColorSpace setgcolor setfillblend
-} def
-/setstrokestate {
- StrokeColor StrokeColorSpace setgcolor StrokeOverprint setoverprint
- StrokeConstantAlpha SoftMask .settransparencyparams
-} def
-/Cdict 15 dict dup begin % <color...> <colorspace> -proc- -
- /DeviceGray { pop setgray } bdef
- /DeviceRGB { pop setrgbcolor } bdef
- /DeviceCMYK { pop setcmykcolor } bdef
- /CIEBasedA { setgcolorspace setcolor } bdef
- /CIEBasedABC /CIEBasedA load def
- /CIEBasedDEF /CIEBasedA load def
- /CIEBasedDEFG /CIEBasedA load def
- /ICCBased /CIEBasedA load def
- /Separation /CIEBasedA load def
- /DeviceN /CIEBasedA load def
- /Indexed /CIEBasedA load def
- /Pattern
- { setgcolorspace
-
- % Since multiple patterns may share
- % same data stream, we need to ensure
- % that the stream is at 0 position.
- % Making this consistently with resolveshading,
- % which applies ReusableStreamDecode filter
- % to the PS stream, which represents the
- % PDF stream in dynamics.
-
- dup /Shading knownoget {
- dup /ShadingType oget 4 ge {
- /DataSource knownoget {
- dup type /filetype eq {
- 0 setfileposition
- } {
- pop
- } ifelse
- } if
- } {
- pop
- } ifelse
- } if
-
- dup /Matrix knownoget not { matrix } if
- gsave DefaultQstate setqstate makepattern grestore setcolor
- } bdef
-end def
-/setgcolor % (null | <color...>) <colorspace> setgcolor -
- { 1 index null eq
- { pop pop }
- { dup 0 get //Cdict exch get exec }
- ifelse
- } bdef
-% Compare the old and new color spaces in an attempt to avoid expensive
-% reloads of CIEBased color spaces.
-/PCSdict 15 dict dup begin % <colorspace> -proc- <colorspace|pdfcspace>
- /CIEBasedA { dup 1 get /PDFColorSpace .knownget { exch pop } if } bdef
- /CIEBasedABC /CIEBasedA load def
- /CIEBasedDEF /CIEBasedA load def
- /CIEBasedDEFG /CIEBasedA load def
- /Indexed {
- dup 1 get dup pdfcolorspace 2 copy ne { 3 1 roll } if pop pop
- } bdef
-end def
-/pdfcolorspace { % <colorspace> pdfcolorspace <colorspace|pdfcspace>
- dup type /arraytype eq {
- //PCSdict 1 index 0 get .knownget { exec } if
- } if
-} bdef
-/setgcolorspace { % <colorspace> setgcolorspace -
- dup pdfcolorspace currentcolorspace pdfcolorspace eq {
- pop
- } {
- setcolorspace
- } ifelse
-} bdef
-/fsexec % <fillop|strokeop> fsexec -
- { % Preserve the current point, if any.
- { currentpoint } stopped
- { $error /newerror false put cvx exec }
- { 3 -1 roll cvx exec moveto }
- ifelse
- } bdef
-
-% ---------------- Path painting and clipping ---------------- %
-
-/S { setstrokestate /stroke fsexec } bdef
-/f { setfillstate /fill fsexec } bdef
-/f* { setfillstate /eofill fsexec } bdef
-/n { newpath } bdef % don't allow n to get bound in
-/s { closepath S } bdef
-/B { gsave setfillstate fill grestore S } bdef
-/b { closepath B } bdef
-/B* { gsave setfillstate eofill grestore S } bdef
-/b* { closepath B* } bdef
-
-% Clipping:
-
-/Wdict 4 dict dup begin
-/S { gsave setstrokestate stroke grestore n } bdef
-/f { gsave setfillstate fill grestore n } bdef
-/f* { gsave setfillstate eofill grestore n } bdef
-/n { end clip newpath } bdef
-end readonly def
-/W { //Wdict begin } bdef
-/W*dict 4 dict dup begin
-Wdict { def } forall
-/n { end eoclip newpath } bdef
-end readonly def
-/W* { //W*dict begin } bdef
-
-% ---------------- Text control ---------------- %
-
-/textbeginpage
- { /TextSpacing 0 def % 0 Tc
- /TextLeading 0 def % 0 TL
- /TextRenderingMode 0 def % 0 Tr
- /TextRise 0 def % 0 Ts
- /WordSpacing 0 def % 0 Tw
- /TextHScaling 1.0 def % 100 Tz
- /TextFont null def
- /FontMatrixNonHV //false def
- /Show { showfirst } def
- } bdef
-
-% Contrary to the statement in the PDF manual, BT and ET *can* be nested,
-% if the CharProc for a Type 3 font does a BT/ET itself.
-% Since we always call the CharProc inside a q/Q, we simply ensure that
-% the text state is saved and restored like the rest of the extended
-% graphics state.
-
-/settextmatrix {
- TextMatrix concat
- TextHScaling 1 ne { TextHScaling 1 scale } if
- TextRise 0 ne { 0 TextRise translate } if
- TextFont dup null eq { pop } { setfont } ifelse
-} bdef
-/settextstate {
- % The text state can be set even outside BT/ET.
- currentdict /TextSaveMatrix known {
- TextSaveMatrix setmatrix settextmatrix
- } if
-} bdef
-/settextposition {
- % Update the TextMatrix translation.
- gsave TextSaveMatrix setmatrix
- currentpoint TextRise sub TextMatrix 4 2 getinterval astore pop
- % We would like to do "grestore currentpoint translate"
- % here, but some PDF files set a singular text matrix
- % (0 0 0 0 <x> <y> Tm), so we can't do this.
- TextTempMatrix identmatrix setmatrix currentpoint
- grestore
- TextTempMatrix currentmatrix 4 2 getinterval astore pop
- TextTempMatrix setmatrix
-} bdef
-
-/BT {
- currentdict /TextLineMatrix .knownget
- { identmatrix pop TextMatrix identmatrix pop }
- { matrix /TextLineMatrix gput matrix /TextMatrix gput }
- ifelse
- { showfirst } /Show gput
- currentdict /TextSaveMatrix .knownget not {
- matrix dup /TextSaveMatrix gput
- } if currentmatrix pop settextmatrix
- matrix /TextTempMatrix gput % see settextposition
-} bdef
-/ET {
- TextRenderingMode 4 ge { clip newpath } if
- TextSaveMatrix setmatrix
- currentdict /TextSaveMatrix undef
-} bdef
-/Tc { /TextSpacing gput { showfirst } /Show gput } bdef
-/TL { /TextLeading gput } bdef
-/Tr { dup .settextrenderingmode /TextRenderingMode gput { showfirst } /Show gput } bdef
-/Ts { /TextRise gput settextstate } bdef
-/Tw { /WordSpacing gput { showfirst } /Show gput } bdef
-/Tz { 100 div /TextHScaling gput settextstate} bdef
-
-% ---------------- Font control ---------------- %
-
-% Test if the FontMatrix could transform a horizontal/vertical (depending
-% on writing mode) advance vector in glyph space into one with a different
-% direction in text space.
-% - if FontMatrix = [a b c d tx ty], this condition translates to:
-% b != 0 for horizontal writing mode
-% c != 0 for vertical writing mode
-% - when false, we automatically have wy/x == 0 in text space whenever wy/x == 0
-% in glyph space, and can avoid the slow method that is otherwise necessary
-% to implement zeroing wy/x cf PDF Ref 5.3.3 "Text space details"
- % Worker procedure for testing a single font matrix
-/?FontMatrixNonHV { % ?horz <<fontdict>> -- ?horz ?nonhv
- /FontMatrix .knownget {
- 1 index { 1 } { 2 } ifelse get 0 ne
- } {
- //false
- } ifelse
-} bdef
- % Worker procedure for recursive checking of font matrices
-/?FontMatrixNonHV { % {self} ?horz <<font>> -- {self} ?horz ?nonhv
- 2 copy //?FontMatrixNonHV exec { % check the font's own FontMatrix
- pop pop //true
- } {
- % look for descendents/ components
- pop % {self} ?horz <<font>>
- dup /FontType get
- dup 0 eq { % Type 0: look into FDepVector
- pop /FDepVector get 2 index % {self} ?horz [fonts..] {testproc}
- } {
- 9 eq { % Type 9 (CIDFontType 0): check FDArray
- /FDArray get //?FontMatrixNonHV
- } { % all others: nothing more to check
- pop {} {}
- } ifelse
- } ifelse
- %stack: {self} ?horz [fonts..] {testproc}
- //false 5 2 roll { % {testproc} false {self} ?horz <<subfont>>
- 4 index exec {
- 4 -1 roll pop //true 4 1 roll
- exit
- } if
- } forall
- %stack: {testproc} ?nonhv {self} ?horz
- 4 2 roll exch pop
- } ifelse
-} bdef
- % Main procedure
-/?FontMatrixNonHV { % <<rootfont>> -- ?nonhv
- //?FontMatrixNonHV exch
- % determine WMode
- dup /WMode .knownget { 0 eq } { //true } ifelse % {proc} <<rootfont>> ?horz
- exch
- % call the worker procedure
- //?FontMatrixNonHV exec
- exch pop exch pop
-} bdef
-
-/Tf { % <font> <scale> Tf -
- dup 0 eq {
- (\n **** Warning: Invalid 0.0 font scale given for Tf ****\n)
- pdfformaterror
- pop 0.00000001 % handle invalid scale by using a really small value
- } if
- 1 index type /dicttype ne {
- selectfont currentfont
- } {
- dup 1 eq { pop } { scalefont } ifelse
- }
- ifelse
- dup ?FontMatrixNonHV dup FontMatrixNonHV ne {
- /FontMatrixNonHV gput
- { showfirst } /Show gput
- } {
- pop
- } ifelse
- /TextFont gput settextstate
-} bdef
-
-% Read a CFF font.
-/FRD % <resname> <file> FRD -
- { /FontSetInit /ProcSet findresource begin //true ReadData
- } bdef
-
-% Copy a font, removing its FID. If changed is true, also remove
-% the UniqueID and XUID, if any. If the original dictionary doesn't have
-% the keys being removed, don't copy it.
-/.copyfontdict % <font> <changed> .copyfontdict <dict>
- { 1 index /FID known
- 1 index { 2 index /UniqueID known or 2 index /XUID known or } if
- { % We add 1 to the length just in case the original
- % didn't have a FID.
- exch dup length 1 add dict exch
- { % Stack: changed newfont key value
- 1 index /FID eq 4 index
- { 2 index /UniqueID eq or 2 index /XUID eq or }
- if not { 3 copy put } if pop pop
- }
- forall exch
- }
- if pop
- } bdef
-
-% Insert a new Encoding or Metrics into a font if necessary.
-% Return a possibly updated font, and a flag to indicate whether
-% the font was actually copied.
-/.updatefontmetrics { % <font> <Metrics|null> .updatefontmetrics
- % <font'> <copied>
- dup //null ne {
- exch //true .copyfontdict dup /Metrics 4 -1 roll put //true
- } {
- pop //false
- } ifelse
-} bdef
-
-/.updatefontencoding { % <font> <Encoding|null> .updatefontencoding
- % <font'> <copied>
- dup //null ne { dup 2 index /Encoding get ne } { //false } ifelse {
- exch //false .copyfontdict dup /Encoding 4 -1 roll put //true
- } {
- pop //false
- } ifelse
-} bdef
-
-% Duplicate keys in CharString dictionary according to GlyphMap: <</new_glyph /old_glyph>>
-% We have to do this because PDF fonts can associate multiple widths with the same glyph
-% but Metrics dictionary works by the glyph name.
-/.update_charstring { % <font> <GlyphMap> .update_charstring <font'> <copied>
- dup //null ne {
- exch //true .copyfontdict % map font
- dup dup /CharStrings get % map font font cstr
- dup length % map font font cstr len
- 4 index length add % map font font cstr len+map_len
- dict copy dup begin % map font font cstr'
- /CharStrings exch put % map font
- exch { % font /new /old
- currentdict exch .knownget {
- def
- } {
- currentdict /.notdef .knownget {
- def
- } {
- pop
- % The font has no .notdef.
- % Could not resolve the conflict,
- % but either the font is invalid or the glyph name is never used.
- } ifelse
- } ifelse
- } forall
- end //true
- } {
- pop //false
- } ifelse
-} bdef
-
-/.updatefont { % <font> <Encoding|null> <Metrics|null> <GlyphMap|null>
- % .updatefont <font'> <copied>
- 4 2 roll % <Metrics|null> <GlyphMap> <font> <Encoding|null>
- .updatefontencoding % <Metrics|null> <GlyphMap> <font> bool
- 4 1 roll exch % bool <Metrics|null> <font> <GlyphMap>
- .update_charstring % bool <Metrics|null> <font> bool
- 3 1 roll exch % bool bool <font> <Metrics|null>
- .updatefontmetrics % bool bool <font> bool
- 4 2 roll or or % <font> is_copied
-} bdef
-
-% ---------------- Text positioning ---------------- %
-
-/Td {
- TextLineMatrix transform TextLineMatrix 4 2 getinterval astore pop
- TextLineMatrix TextMatrix copy pop settextstate
-} bdef
-/TD { dup neg /TextLeading gput Td } bdef
-/T* { 0 TextLeading neg Td } bdef
-/Tm {
- TextLineMatrix astore TextMatrix copy pop settextstate
-} bdef
-
-% ---------------- Text painting ---------------- %
-
-/Vexch {
- rootfont /WMode knownoget { 1 eq { exch } if } if
-} bind def
-
-/textrenderingprocs [ % (0 is handled specially)
- % Painting-only modes
- { tf } { tS } { tB } { tn }
- % Clipping modes
- { gsave tf grestore tW }
- { gsave tS grestore tW }
- { gsave tB grestore tW }
- { tW }
-] readonly def
-
-/pdfwrite_textrenderingprocs [
- { setfillstate show } bind
- { setstrokestate show } bind
- { gsave 0 .settextrenderingmode
- setfillstate dup show currentpoint 3 -1 roll
- grestore gsave setstrokestate false charpath stroke
- grestore moveto
- } bind
- { setfillstate show } bind
- { gsave 0 .settextrenderingmode
- setfillstate dup show grestore true charpath } bind
- { gsave 1 .settextrenderingmode
- setstrokestate dup show grestore
- true charpath } bind
- { gsave 0 .settextrenderingmode
- setfillstate dup show grestore gsave dup
- setstrokestate false charpath stroke grestore
- true charpath } bind
- { true charpath } bind
-] readonly def
-
-/setshowstate
- { WordSpacing 0 eq TextSpacing 0 eq and FontMatrixNonHV not and
- {
- currentdevice .devicename /pdfwrite eq
- {
- pdfwrite_textrenderingprocs TextRenderingMode get
- }
- {
- TextRenderingMode 0 eq {
- { setfillstate show }
- } {
- TextRenderingMode 3 eq {
- % Some PDF files execute 'tm' with a singular matrix,
- % and then use the text rendering mode 3.
- % The graphics library currently cannot handle text
- % operations when the CTM is singular.
- % Work around this here.
- {
- matrix currentmatrix dup dup
- dup 0 get 0 eq 1 index 1 get 0 eq and {
- dup dup 2 get 0 eq { 0 }{ 1 } ifelse 1 put
- } if
- dup 2 get 0 eq 1 index 3 get 0 eq and {
- dup dup 1 get 0 eq { 3 }{ 2 } ifelse 1 put
- } if
- setmatrix
- 2 index setfillstate show % Tr was set to graphic state.
- setmatrix
- % now set the currentpoint using the original matrix
- gsave nulldevice
- setmatrix
- false charpath currentpoint newpath
- grestore
- moveto
- }
- } {
- { false charpath textrenderingprocs TextRenderingMode get exec }
- } ifelse
- } ifelse
- } ifelse
- }
- { TextRenderingMode 0 eq TextRenderingMode 3 eq or
- % Tr was set to graphic state.
- { FontMatrixNonHV {
- {
- setfillstate
- [ TextSpacing WordSpacing 3 index
- { % str [... weach wword c undef|ythis xthis|undef
- exch % will be removed, unless FontMatrix.xx/yy == 0 (FontMatrixNonHV already true)
- Vexch pop % str [... weach wword c wthis
- 3 index add exch 32 eq {1 index add} if % str [... weach wword w
- 3 1 roll % str [... w weach wword
- }
- % for the "exch" removed or not below, see comment in pdf_font.ps::getfontmetrics
- currentfont /FontMatrix get 0 3 Vexch pop get 0 ne {
- 1 1 index length 1 sub getinterval cvx
- } if
- cshow pop pop ]
- { xshow } { yshow } Vexch pop exec
- }
- } {
- WordSpacing 0 eq
- { { setfillstate TextSpacing 0 Vexch 3 -1 roll ashow } }
- { TextSpacing 0 eq
- { { setfillstate WordSpacing 0 Vexch 32 4 -1 roll widthshow } }
- { { setfillstate WordSpacing 0 Vexch 32
- TextSpacing 0 Vexch 6 -1 roll awidthshow } }
- ifelse
- }
- ifelse
- } ifelse
- }
- { { WordSpacing TextSpacing
- % Implement the combination of t3 and false charpath.
- % Note that we must use cshow for this, because we
- % can't parse multi-byte strings any other way.
- % Stack: string wword wchar
- {
- exch % will be removed, unless FontMatrixNonHV && FontMatrix.xx/yy == 0
- % Stack: str wword wchar ccode xthis ythis
- Vexch pop currentpoint 6 3 roll
- % Stack: str wthis xorig yorig wword wchar ccode
- (x) dup 0 3 index put //false charpath
- 3 copy 32 eq { add } { exch pop } ifelse
- % Stack: str wthis xorig yorig wword wchar ccode wextra
- 7 -3 roll moveto add
- 0 Vexch rmoveto pop
- }
- % for the "exch" removed or not below, see comment in pdf_font.ps::getfontmetrics
- FontMatrixNonHV dup not exch {
- currentfont /FontMatrix get 0 3 Vexch pop get 0 ne
- } if {
- 1 1 index length 1 sub getinterval cvx
- } if
- 4 -1 roll cshow pop pop
- textrenderingprocs TextRenderingMode get exec
- }
- }
- ifelse
- }
- ifelse /Show gput
- } bdef
-/showfirst { setshowstate Show } def
-
-/Tj {
- 0 0 moveto Show settextposition
-} bdef
-/' { T* Tj } bdef
-/" { exch Tc exch Tw T* Tj } bdef
-/TJ {
- 0 0 moveto {
- dup type /stringtype eq {
- Show
- } { -1000 div
- currentfont /ScaleMatrix .knownget { 0 get mul } if
- 0 Vexch rmoveto
- } ifelse
- } forall settextposition
-} bdef
-
-/tf { setfillstate currentpoint fill moveto } bdef
-/tn { currentpoint newpath moveto } bdef % Obsolete, never used.
-% For stroking characters, temporarily restore the graphics CTM so that
-% the line width will be transformed properly.
-/Tmatrix matrix def
-/tS
- { setstrokestate
- currentpoint //Tmatrix currentmatrix TextSaveMatrix setmatrix stroke
- setmatrix moveto
- } bdef
-/tB { gsave tf grestore tS } bdef
-% This does the wrong thing if there have been multiple text operations
-% within a single BT/ET pair, but it's a start.
-/tW { } bdef
-
-% Text formatting and painting for the AcroForm field without appearance streams.
-/Tform { % <MaxLen> (V) <Ff> <Q> Tform -
- clippath pathbbox 4 2 roll pop pop % MaxLen (V) Ff Q dx dy
- currentfont /ScaleMatrix .knownget { 3 get } { 1 } ifelse % MaxLen (V) Ff Q dx dy yy
- currentfont /FontBBox get dup 1 get neg exch 3 get % MaxLen (V) Ff Q dx dy yy desc asc
- dup 0 ne { div } { pop pop 0 } ifelse % MaxLen (V) Ff Q dx dy yy desc/asc
- 1 index mul % MaxLen (V) Ff Q dx dy yy desc/asc*yy
-
- 4 index 16#1000 and 0 ne { % multiline
- 8 { pop } repeat (Multiline form fields are not yet implemented.) =
- } {
- 4 index 16#1000000 and 0 ne { % comb
- 8 { pop } repeat (Combed form fields are not yet implemented.) =
- } { % plain text
- 3 1 roll sub add 2 div % MaxLen (V) Ff Q dx (dy-yy+desc)/2
- 0 exch moveto % MaxLen (V) Ff Q dx
- 1 index 0 ne {
- 3 index stringwidth pop % MaxLen (V) Ff Q dx w
- sub exch 1 eq { 2 div } { 2 sub } ifelse % MaxLen (V) Ff (dx-w)/2
- 0 rmoveto % MaxLen (V) Ff
- pop % MaxLen (V)
- } {
- pop pop pop % MaxLen (V)
- 2 0 rmoveto
- } ifelse
- exch pop Show % -
- } ifelse
- } ifelse
-} bdef
-
-end readonly put % GS_PDF_ProcSet
-
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/pdf_rbld.ps b/Master/tlpkg/tlgs/lib/pdf_rbld.ps deleted file mode 100644 index d21b93c876d..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf_rbld.ps +++ /dev/null @@ -1,332 +0,0 @@ -% Copyright (C) 2002 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdf_rbld.ps 8472 2008-01-01 14:28:30Z alexcher $
-% pdf_rbld.ps - Rebuilding of broken PDF files (xref errors)
-
-% This module contains routines that are used if we detect an error
-% while reading the xref tables. These routines will scan the file and
-% build an xref table by finding the objects. We also need to find the
-% appropriate trailer dictionary. Note: One procedure is also used
-% even if we do not need to rebuild a PDF file.
-%
-% This module cannot rebuild a PDF file which has had errors created inside
-% of objects or binary data streams. It often succeeds with files that
-% have had its end of lines converted between unix and dos versions.
-
-% if true --> we have an object with duplicate object and generation numbers.
-/dup_obj_gen_num false def
-
-% Note: This procedure is also used by non-rebuild code.
-% Store a line in the xref array (Actually Objects and Generations arrays)
-% <obj num> (strm num> <obj loc> <gen num> <rebuild>
-% setxrefentry <obj num> strm num> <obj loc> <gen num>
-/setxrefentry
-{
- 5 1 roll
- dup 65535 or 65535 ne {
- ( **** Warning: Generation number out of 0..65535 range, assuming 0.\n)
- pdfformaterror
- pop 0
- } if
- % We store generation numbers as value + 1
- % We reserve 0 to indicate an free xref entry
- 1 add % increment generation number
- % To save space, generations numbers are stored in a lstring unless we
- % find a generation number greater than 255. If so then transfer to
- % an larray.
- dup 255 gt {
- Generations ltype /stringtype eq { % Convert Generations to an larray.
- larray Generations llength lgrowto dup % Create new larray
- 0 1 2 index llength 1 sub { % Copy from old lstring to new larray
- Generations 1 index lget lput dup
- } for
- pop
- /Generations exch store % Save new Generations larray
- } if
- } if
- % Verify that the new values are for a new object. If the current
- % entry is null then we have a new entry.
- Objects 4 index lget null eq {
- ObjectStream 4 index 4 index cvx lput % Save ObjectStream object number
- Objects 4 index 3 index cvx lput % Save object location
- Generations 4 index 2 index lput % Save geenration number
- } {
- % Verify that the new entry has at least as high a generaton number
- % We accept equal entry number because we have found PDF files in
- % which there are multiple objects with the same object and entry
- % numbers. The normal xref logic only accepts the first such
- % entry that it finds. However the 'rebuild PDF' logic can find
- % both such entries. The correct one is usually the last one.
- Generations 4 index lget 1 index le {
- ObjectStream 4 index 4 index cvx lput % Save ObjectStream object number
- Objects 4 index 3 index cvx lput % Save object location
- Generations 4 index 2 index lput % Save geenration number
- } if
- % Set error flag if we have equal object and generation numbers
- Generations 4 index lget 1 index eq { /dup_obj_gen_num true def } if
- } 8 -1 roll { ifelse } { pop if } ifelse % Run 'else' only when rebuilding.
-} bind def
-
-% Print the contents of the xref array. This actually consists of three
-% arrays (Objects, Generations, and ObjectStream). All three are larrays.
-% larrays are a special Ghostscript object which can be arrays with more
-% than 64k elements.
-/print_xref % - print_xref -
-{ 0 1 Objects llength 1 sub % stack: 0 1 <number of objects - 1>
- { dup =only % print object number
- ( ) print
- dup Generations exch lget 1 sub =only % print Generation number
- ( ) print
- dup ObjectStream exch lget ==only % print ObjectStream object number
- ( ) print
- Objects exch lget === % print object location
- } for
- flush
-} bind def
-
-% Get token from string and check its type
-% <string> <type> typed_token <false> % no token or not match
-% <string> <type> typed_token <obj> <last> <true> % matching token type
-% Where last is the string remainder
-/typed_token
-{ exch
- token_nofail % get token
- {
- dup type % stack: type last token type
- 4 -1 roll eq { % stack: last token bool
- exch true % desired object found - set exit status
- } {
- pop pop false % not type - clear stack, set exit status
- } ifelse
- } {
- pop false % no token - pop type, set exit status
- } ifelse % check if we got token
-} bind def
-
-% Allocate space for post_eof_count to be bound into procedures below.
-/post_eof_count 0 def
-
-% We want the location of the trailer dictionary at the start of file.
-% First we will find the xref. Then we will skip over the xref entries
-% to the trailer.
-/search_start_trailer % - search_start_trailer <trailer loc>
-{ % Read the first 300 bytes and check for xref
- PDFfile 0 setfileposition
- PDFfile bytesavailable post_eof_count sub % location of end of data
- 300 .min % block size to read
- dup string 0 1 4 -1 roll 1 sub
- { 2 copy PDFfile read pop put pop } for
- (xref) search {
- % found 'xref'
- exch pop exch pop length 4 add PDFfile exch setfileposition
- PDFfile token pop % get starting entry - or 'trailer'
- (trailer) ne { % if we do not already have 'trailer'
- PDFfile token pop % get number of entries
- PDFfile token pop pop % this moves us into the middle of the first entry
- 25 string exch % define working string for readline
- { PDFfile 1 index readline pop pop
- } repeat % skip entries
- pop % pop working string
- PDFfile token pop pop % get 'trailer'
- PDFfile fileposition % get file position
- } if
- } {
- pop search_end_trailer % no xref, should not happen, search end of file
- } ifelse
-} bind def
-
-% We want the location of the trailer dictionary at the end of file.
-% We will read the last block of data and search for the final occurance
-% of the word 'trailer'
-/search_end_trailer % - search_end_trailer <trailer loc>
-{ % Position to read block of data from the end of the file. Note: We ignore
- % anything past the last %%EOF since this is not PDF data.
- PDFfile 0 setfileposition
- PDFfile bytesavailable post_eof_count sub % location of end of data
- dup 65535 .min % block size to read
- % stack: <file end pos> <block size>
- % move file position to the start of the block
- 2 copy sub PDFfile exch setfileposition
- % read block of data
- dup string 0 1 4 -1 roll 1 sub { 2 copy PDFfile read pop put pop } for
- % search for last occurance of 'trailer'
- (trailer) { search not { exit } if pop } loop
- % determine where the trailer is in the file
- % trailer loc = end loc - remaing string length
- length sub
-} bind def
-
-% We want to find the trailer dictionary. There is a trailer dictionary
-% for each xref object list. We only want the trailer dictionary associated
-% with the first xref object list. In theory this can be anywhere in the
-% file. However since we are trying to repair a broken file, we cannot simply
-% follow the xref links. So we are falling back to a simple strategy. We
-% find the specified location of the first xref list. If its location is in
-% the first half of the file then we search for the first trailer dictionary
-% at the start of the file. Otherwise we search for the last trailer at the
-% end of the file.
-/search_trailer % - search_trailer -
-{ % Find the 'startxref' and associated position at the end of the file.
- % Position to read block of data from the end of the file. Note: We
- % actually end at the end of the last %%EOF since this is the end of the
- % useful PDF data. (Some files contain trailing garbage.)
- PDFfile 0 setfileposition
- PDFfile bytesavailable % size of file
- post_eof_count sub dup % location of end of last %%EOF
- dup 4096 .min % block size to read
- % stack: <useful file size> <useful file size file> <block size>
- % move file position to the start of the block
- 2 copy sub PDFfile exch setfileposition
- % read block of data
- dup string 0 1 4 -1 roll 1 sub { 2 copy PDFfile read pop put pop } for
- % search for last occurance of 'startxref'
- false % Assume that startxref not present
- exch (startxref) {
- search not { exit } if % Exit loop when no more startxref's
- pop 3 -1 roll pop true 3 1 roll % Idicate that we have found starxref
- } loop
- exch % Exch last string and 'found' flag
- {
- % determine where the startxref is in the file
- % 'startxref' loc = end loc - remaing string length - 9 bytes
- length sub 9 sub
- % move the file to this position and read startxref and position
- PDFfile exch setfileposition PDFfile token
- pop pop PDFfile token pop
- } {
- % startxref not found. We will search the end of the file for trailer.
- pop pop PDFfilelen
- } ifelse
- % compare xref position to 1/2 the length of the file and search for trailer
- exch 2 div lt { search_start_trailer } { search_end_trailer } ifelse
- % get the trailer
- PDFfile exch setfileposition % set to the specified trailer location
- /dictlevelcount 0 def
- PDFfile traileropdict .pdfrun % read trailer info
- /Trailer exch def
-} bind def
-
-% This routine will determine if there is stuff after the %%EOF. There is
-% supposed to be only a line termination. However many real life files
-% contain some garbage. This routine checks how much. We then ignore this
-% stuff when we are scanning for objects.
-/determine_post_eof_count % - determine_post_eof_count <count>
-{ % Position to read block of data from the end of the file.
- PDFfilelen % size of file
- dup 4096 .min % block size to read
- % stack: <file size> <file size> <block size>
- % move file position to the start of the block
- 2 copy sub PDFfile exch setfileposition
- % read block of data
- dup string 0 1 4 -1 roll 1 sub { 2 copy PDFfile read pop put pop } for
- % search for last occurance of '%%EOF'
- (%%EOF) { search not { exit } if pop } loop
- % how much is left = remaining string length
- length exch pop % pop /%%EOF
-} bind def
-
-% This routine will scan a file searaching for object locations to build
-% an alternate version of the data in the xref tables.
-% Its purpose is to provide a basis for an xref fixing facility.
-/search_objects % - search_objects -
-{ % Initialize the Objects, Generations, etc. larrays
- initPDFobjects
- % reset duplicate object and generation numbers error flag
- /dup_obj_gen_num false def
- % Determine how many bytes are in the file after the final %%EOF
- /post_eof_count determine_post_eof_count def
- % Start at the beginning of the file
- PDFfile 0 setfileposition
- % Create a working string (and also store its length on stack). We are
- % using a maximum size string size the logic below wants a recovered object
- % to fit into our working string.
- 65535 dup string
- { % Now loop through the entire file lloking for objects
- PDFfile fileposition % save current file position
- % When we get near the end of the file, we use a smaller interval of
- % our working string to prevent reading past the end. (See comments on
- % EOF testing below.)
- PDFfile bytesavailable post_eof_count sub 10 sub dup 4 index lt {
- 2 index 0 3 -1 roll getinterval % near EOF, use interval of string
- } { pop 1 index % not near end, use full working string
- }ifelse
- % Read a line from file. If the line does not fit into our working string,
- % or any other error, then we will discard it.
- PDFfile exch { readline } .internalstopped
- { pop pop false } if % indicate no string if we stopped
- { % stack: <length> <working_str> <loc> <string>
- % Now that we have line, get obj num, ref num, and 'obj'. Verify that each
- % of these is correct type.
- /integertype typed_token { % get obj number
- /integertype typed_token { % get ref number
- /nametype typed_token { % get 'obj' text
- pop % pop remaining string
- /obj eq { % verify name is 'obj'
- % make sure we have room in the arrays. We work in increments
- % of 20 each time we increase the size.
- 1 index 20 add 20 idiv 20 mul
- growPDFobjects
- % save xref parameters into ObjectStream, Objects and Generations
- 1 index 0 % rearrange parms for setxrefentry
- 4 index PDFoffset sub 3 index
- //true setxrefentry % save parameters
- pop pop pop pop % clear parameters
- } if % check if name is 'obj'
- } if % check if we got 'obj" string
- pop % remove ref number
- } if % check if we got ref number
- pop % remove obj number
- } if % check if we got object number
- } if % check if got a string from readline
- pop % remove location
- % Check if we are approaching the end of the file. We do not want to
- % read past the end of the file since that closes it. We actually stop
- % 10-20 bytes early since there cannot be an object that close to the end.
- % (There is a Trailer dictionary, etc. at the end of the file.)
- PDFfile bytesavailable post_eof_count sub 20 lt { exit } if
- } loop % loop through the entire file
- pop pop % remove working string and its length
- % Output warning if we have two objects with the same object and generation
- % numbers.
- dup_obj_gen_num {
- ( **** Warning: There are objects with matching object and generation\n)
- pdfformaterror
- ( **** numbers. The accuracy of the resulting image is unknown.\n)
- pdfformaterror
- } if
-} bind def
-
-% Print warning message because we found a problem while reading the xref
-% tables
-/print_xref_warning
-{ ( **** Warning: An error occurred while reading an XREF table.\n)
- pdfformaterror
- ( **** The file has been damaged. This may have been caused\n)
- pdfformaterror
- ( **** by a problem while converting or transfering the file.\n)
- pdfformaterror
- ( **** Ghostscript will attempt to recover the data.\n)
- pdfformaterror
-} bind def
-
-% Attempt to recover the XRef data. This is called if we have a failure
-% while reading the normal XRef tables. This routine usually works
-% only for pre PDF1.5 versions of PDF files.
-/recover_xref_data % - recover_xref_data -
-{ print_xref_warning % Print warning message
- count pdfemptycount sub { pop } repeat % remove anything left by readxref
- search_objects % Search for objects
-} bind def
diff --git a/Master/tlpkg/tlgs/lib/pdf_sec.ps b/Master/tlpkg/tlgs/lib/pdf_sec.ps deleted file mode 100644 index f6258f2e461..00000000000 --- a/Master/tlpkg/tlgs/lib/pdf_sec.ps +++ /dev/null @@ -1,469 +0,0 @@ -% Copyright (C) 1996-1998 Geoffrey Keating.
-% Copyright (C) 2001 Artifex Software, Inc.
-% This file may be freely distributed with or without modifications,
-% so long as modified versions are marked as such and copyright notices are
-% not removed.
-
-% $Id: pdf_sec.ps 8329 2007-10-28 17:17:47Z alexcher $
-% Implementation of security hooks for PDF reader.
-
-% This file contains the procedures that have to take encryption into
-% account when reading a PDF file. It replaces the stub version of this
-% file that is shipped with GhostScript. It requires GhostScript 7.01
-% or later.
-
-% Documentation for using this file is available at
-% http://www.ozemail.com.au/%7Egeoffk/pdfencrypt/
-
-% Modified by Alex Cherepanov to work with GS 6.60 and higher.
-% New versions of GS require explicit checks for /true , /false, and /null
-% in .decpdfrun . This fix is backward-compatible.
-
-% Modified by Raph Levien and Ralph Giles to use the new C
-% implementations of md5 and arcfour in ghostscript 7.01, and to
-% be compatible with PDF 1.4 128-bit encryption.
-
-/.setlanguagelevel where { pop 2 .setlanguagelevel } if
-.currentglobal true .setglobal
-/pdfdict where { pop } { /pdfdict 100 dict def } ifelse
-pdfdict begin
-
-% Older ghostscript versions do not have .pdftoken, so we use 'token' instead.
-/.pdftoken where { pop } { /.pdftoken /token load def } ifelse
-
-% take a stream and arc4 decrypt it.
-% <stream> <key> arc4decodefilter <stream>
-/arc4decodefilter {
- 1 dict begin
- /Key exch def
- currentdict end /ArcfourDecode filter
-} bind def
-
-% <ciphertext> <key> arc4decode <plaintext>
-/arc4decode {
- %(key: ) print dup == (ct: ) print 1 index ==
- 1 index length 0 eq {
- pop
- } {
- 1 index length string 3 1 roll arc4decodefilter exch readstring pop
- } ifelse
-} bind def
-
-/md5 {
- 16 string dup /MD5Encode filter dup 4 3 roll writestring closefile
-} bind def
-
-/md5_trunk {
- md5 0 pdf_key_length getinterval
-} bind def
-
-
-/pdf_padding_string
- <28bf4e5e4e758a41 64004e56fffa0108
- 2e2e00b6d0683e80 2f0ca9fe6453697a>
-def
-
-% Pad a key out to 32 bytes.
-/pdf_pad_key { % <key> pdf_pad_key <padded key>
- dup length 32 gt { 0 32 getinterval } if
- pdf_padding_string
- 0 32 3 index length sub getinterval
- concatstrings
-} bind def
-
-/pdf_xorbytes { % <iter-num> <key> pdf_xorbytes <xored-key>
- dup length dup string
- exch 1 sub 0 1 3 2 roll {
- % <iter-num> <key> <new-key> <byte-num>
- dup 3 index exch get 4 index xor
- % <iter-num> <key> <new-key> <byte-num> <byte>
- 3 copy put pop pop
- } for
- 3 1 roll pop pop
-} bind def
-
-% Get length of encryption key in bytes
-/pdf_key_length { % pdf_key_length <key_length>
- Trailer /Encrypt oget
- dup /V knownoget not { 0 } if 1 eq
- { pop 5 } % If V == 1 then always use 40 bits
- { /Length knownoget { -3 bitshift } { 5 } ifelse }
- ifelse
-} bind def
-
-% Algorithm 3.2
-/pdf_compute_encryption_key { % <password> pdf_compute_encryption_key <key>
- % Step 1.
- pdf_pad_key
-
- % Step 2, 3.
- Trailer /Encrypt oget dup /O oget
- % <padded-key> <encrypt> <O>
-
- % Step 4.
- exch /P oget 4 string exch
- 2 copy 255 and 0 exch put
- 2 copy -8 bitshift 255 and 1 exch put
- 2 copy -16 bitshift 255 and 2 exch put
- 2 copy -24 bitshift 255 and 3 exch put pop
- % <padded-key> <O> <P>
-
- % Step 5.
- Trailer /ID knownoget { 0 oget } {
- ()
- ( **** ID key in the trailer is required for encrypted files.\n) pdfformaterror
- } ifelse
- 3 { concatstrings } repeat
- % We will finish step 5 after possibly including step 6.
-
- % The following only executed for /R equal to 3 or more
- Trailer /Encrypt oget dup /R oget dup 3 ge {
-
- % Step 6. If EncryptMetadata is false, pass 0xFFFFFFFF to md5 function
- % The PDF 1.5 Spec says that EncryptMetadata is an undocumented
- % feature of PDF 1.4. That implies that this piece of logic should
- % be executed if R >= 3. However testing with Acrobat 5.0 and 6.0 shows
- % that this step is not executed if R equal to 3. Thus we have a test for
- % R being >= 4.
- 4 ge {
- /EncryptMetadata knownoget % Get EncryptMetadata (if present)
- not { true } if % Default is true
- not { % If EncryptMetadata is false
- <ff ff ff ff> concatstrings % Add 0xFFFFFFFF to working string
- } if
- } {
- pop % Remove Encrypt dict
- } ifelse
- md5_trunk % Finish step 5 and 6.
-
- % Step 7. Executed as part of step 6
- % Step 8. (This step is defintely a part of PDF 1.4.)
- 50 { md5_trunk } repeat
- } {
- pop pop md5_trunk % Remove R, Encrypt dict, finish step 5
- } ifelse
-
- % Step 9 - Done in md5_trunk.
-} bind def
-
-% Algorithm 3.4
-/pdf_gen_user_password_R2 { % <filekey> pdf_gen_user_password_R2 <U>
-
- % Step 2.
- pdf_padding_string exch arc4decode
-} bind def
-
-% Algorithm 3.5
-/pdf_gen_user_password_R3 { % <filekey> pdf_gen_user_password_R3 <U>
-
- % Step 2.
- pdf_padding_string
-
- % Step 3.
- Trailer /ID knownoget { 0 oget } {
- ()
- ( **** ID key in the trailer is required for encrypted files.\n) pdfformaterror
- } ifelse
- concatstrings md5
-
- % Step 4.
- 1 index arc4decode
-
- % Step 5.
- 1 1 19 {
- 2 index pdf_xorbytes arc4decode
- } for
- exch pop
-
-} bind def
-
-/pdf_gen_user_password { % <password> pdf_gen_user_password <filekey> <U>
- % common Step 1 of Algorithms 3.4 and 3.5.
- pdf_compute_encryption_key dup
-
- Trailer /Encrypt oget
-
- /R oget dup 2 eq {
- pop pdf_gen_user_password_R2
- } {
- dup 3 eq {
- pop pdf_gen_user_password_R3
- } {
- dup 4 eq { % 4 uses the algorithm as 3
- pop pdf_gen_user_password_R3
- } {
- ( **** This file uses an unknown standard security handler revision: )
- exch =string cvs concatstrings pdfformaterror printProducer
- /pdf_check_user_password cvx /undefined signalerror
- } ifelse
- } ifelse
- } ifelse
-} bind def
-
-% Algorithm 3.6
-/pdf_check_user_password { % <password> pdf_check_user_password <filekey> true
- % <password> pdf_check_user_password false
- pdf_gen_user_password
-
- Trailer /Encrypt oget /U oget
-
- 0 2 index length getinterval eq {
- true
- } {
- pop false
- } ifelse
-} bind def
-
-% Compute an owner key, ie the result of step 4 of Algorithm 3.3
-/pdf_owner_key % <password> pdf_owner_key <owner-key>
-{
- % Step 1.
- pdf_pad_key
-
- % Step 2.
- md5_trunk
-
- % 3.3 Step 3. Only executed for /R equal to 3 or more
- Trailer /Encrypt oget /R oget 3 ge {
- 50 { md5_trunk } repeat
- } if
-
- % Step 4 - Done in md5_trunk.
-} bind def
-
-% Algorithm 3.7
-/pdf_check_owner_password { % <password> pdf_check_owner_password <filekey> true
- % <password> pdf_check_owner_password false
- % Step 1.
- pdf_owner_key
-
- % Step 2.
- Trailer /Encrypt oget dup /O oget 2 index arc4decode
- % <encryption-key> <encrypt-dict> <decrypted-O>
-
- % Step 3. Only executed for /R equal to 3 or more
- exch /R oget 3 ge {
- 1 1 19 {
- 2 index pdf_xorbytes arc4decode
- } for
- } if
- exch pop
- % <result-of-step-3>
-
- pdf_check_user_password
-} bind def
-
-% Process the encryption information in the Trailer.
-/pdf_process_Encrypt {
- Trailer /Encrypt oget
- /Filter oget /Standard eq not {
- ( **** This file uses an unknown security handler.\n) pdfformaterror
- printProducer
- /pdf_process_Encrypt cvx /undefined signalerror
- } if
- () pdf_check_user_password
- {
- /FileKey exch def
- } {
- /PDFPassword where {
- pop PDFPassword pdf_check_user_password
- {
- /FileKey exch def
- } {
- PDFPassword pdf_check_owner_password
- {
- /FileKey exch def
- } {
- ( **** Password did not work.\n) pdfformaterror
- printProducer
- /pdf_process_Encrypt cvx /invalidfileaccess signalerror
- } ifelse
- } ifelse
- } {
- ( **** This file requires a password for access.\n) pdfformaterror
- printProducer
- /pdf_process_Encrypt cvx /invalidfileaccess signalerror
- } ifelse
- } ifelse
-
-% Trailer /Encrypt oget /P oget 4 and 0 eq #? and
-% { ( ****This owner of this file has requested you do not print it.\n)
-% pdfformaterror printProducer
-% /pdf_process_Encrypt cvx /invalidfileaccess signalerror
-% }
-% if
-} bind def
-
-% Calculate the key used to decrypt an object (to pass to .decpdfrun or
-% put into a stream dictionary).
-/computeobjkey % <object#> <generation#> computeobjkey <keystring>
-{
- exch
- FileKey length 5 add string
- dup 0 FileKey putinterval
- exch
- % stack: gen# string obj#
- 2 copy 255 and FileKey length exch put
- 2 copy -8 bitshift 255 and FileKey length 1 add exch put
- 2 copy -16 bitshift 255 and FileKey length 2 add exch put
- pop exch
- 2 copy 255 and FileKey length 3 add exch put
- 2 copy -8 bitshift 255 and FileKey length 4 add exch put
- pop md5 0 FileKey length 5 add 2 index length .min getinterval
-} bind def
-
-% As .pdfrun, but decrypt strings with key <key>.
-/PDFScanRules_true << /PDFScanRules true >> def
-/PDFScanRules_null << /PDFScanRules null >> def
-/.decpdfrun % <file> <keystring> <opdict> .decpdfrun -
- { % Construct a procedure with the file, opdict and key bound into it.
- 2 index cvlit mark
- /PDFScanRules .getuserparam //null eq {
- //PDFScanRules_true { setuserparams } 0 get % force PDF scanning mode
- mark 7 4 roll
- } {
- mark 5 2 roll
- } ifelse
- { .pdftoken not { (%%EOF) cvn cvx } if
- dup xcheck
- { PDFDEBUG { dup == flush } if
- 3 -1 roll pop
- 2 copy .knownget
- { exch pop exch pop exec
- }
- { exch pop
- dup /true eq
- { pop //true
- }
- { dup /false eq
- { pop //false
- }
- { dup /null eq
- { pop //null
- }
- { ( **** Unknown operator: )
- exch =string cvs concatstrings (\n) concatstrings
- pdfformaterror
- }
- ifelse
- }
- ifelse
- }
- ifelse
- }
- ifelse
- }
- { exch pop PDFDEBUG { dup ==only ( ) print flush } if
- dup type /stringtype eq
- {
- % Check if we have encrypted strings R=4 allows for
- % selection of encryption on streams and strings
- Trailer /Encrypt oget % Get encryption dictionary
- dup /R oget 4 lt % only 4 has selectable
- { % R < 4 --> encrypted strings
- pop 1 index arc4decode % Decrypt string
- PDFDEBUG { (%Decrypted: ) print dup == flush } if
- } { % Else R = 4
- /StrF knownoget % Get StrF (if present)
- { % If StrF is present ...
- /Identity eq not % Check if StrF != Identity
- { 1 index arc4decode % Decrypt string
- PDFDEBUG { (%Decrypted: ) print dup == flush } if
- }
- if % If StrF != identity
- }
- if % If StrF is known
- }
- ifelse % Ifelse R < 4
- }
- if % If = stringtype
- exch pop
- }
- ifelse
- }
- aload pop .packtomark cvx
- { loop } 0 get 2 packedarray cvx
- { stopped } 0 get
- /PDFScanRules .getuserparam //null eq {
- //PDFScanRules_null { setuserparams } 0 get % reset PDF scannig mode if it was off
- } if
- /PDFsource PDFsource
- { store { stop } if } aload pop .packtomark cvx
- /PDFsource 3 -1 roll store exec
- } bind def
-currentdict /PDFScanRules_true undef
-currentdict /PDFScanRules_null undef
-
-% Run the code to resolve an object reference.
-/pdf_run_resolve
-{ /FileKey where % Check if the file is encrypted
- { pop % File is encrypted
- 2 copy computeobjkey dup 4 1 roll
- PDFfile exch resolveopdict .decpdfrun
- dup dup dup 5 2 roll
- % stack: object object key object object
- { % Use loop to provide an exitable context.
- xcheck exch type /dicttype eq and % Check if executable dictionary
- not { % If object is not ...
- pop pop % ignore object
- exit % Exit 'loop' context
- } if % If not possible stream
- % Starting with PDF 1.4 (R = 3), there are some extra features
- % which control encryption of streams. The EncryptMetadata entry
- % in the Encrypt dict controls the encryption of metadata streams.
- Trailer /Encrypt oget % Get encryption dictionary
- dup /R oget dup 3 lt % Only PDF 1.4 and higher has options
- { % R < 3 --> all streams encrypted
- pop pop /StreamKey exch put % Insert StreamKey in dictionary
- exit % Exit 'loop' context
- } if
- % Check EncryptMeta. stack: object object key Encrypt R
- exch dup /EncryptMetadata knownoget % Get EncryptMetadata (if present)
- not { true } if % If not present default = true
- not % Check if EncryptMetadata = false
- { % if false we need to check the stream type
- 3 index /Type knownoget % Get stream type (if present)
- not { //null } if % If type not present use fake name
- /Metadata eq % Check if the type is Metadata
- { pop pop pop pop % Type == Metadata --> no encryption
- exit % Exit 'loop' context
- } if
- } if
- % PDF 1.5 encryption (R == 4) has selectable encryption handlers. If
- % this is not PDF 1.5 encryption (R < 4) then we are done checking and
- % we need to decrypt the stream. stack: object object key R Encrypt
- exch 4 lt % Check for less than PDF 1.5
- { pop /StreamKey exch put % Insert StreamKey in dictionary
- exit % Exit 'loop' context
- } if
- % Check if the stream encryption handler (StmF) == Identity.
- /StmF knownoget % Get StmF (if present)
- not { /Identity } if % If StmF not present default = Identity
- /Identity eq % Check if StmF == Identity
- { pop pop % Identity --> no encryption
- exit % Exit 'loop' context
- } if
- % If we get here then we need to decrypt the stream.
- /StreamKey exch put % Insert StreamKey into dictionary
- exit % Exit 'loop' context, never loop
- } loop % End of loop exitable context
- } { % Else file is not encrypted
- PDFfile resolveopdict .pdfrun
- } ifelse % Ifelse encrypted
-} bind def
-
-% Prefix a decryption filter to a stream if needed.
-% Stack: readdata? dict parms file/string filternames
-% (both before and after).
-/pdf_decrypt_stream
- { 3 index /StreamKey known % Check if the file is encrypted
- {
- exch
- % Stack: readdata? dict parms filternames file/string
- 3 index /StreamKey get arc4decodefilter
- exch
- } if
- } bind def
-
-end % pdfdict
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/pdfopt.ps b/Master/tlpkg/tlgs/lib/pdfopt.ps deleted file mode 100644 index bd2cbe6630a..00000000000 --- a/Master/tlpkg/tlgs/lib/pdfopt.ps +++ /dev/null @@ -1,1271 +0,0 @@ -% Copyright (C) 2000, 2001 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdfopt.ps 8251 2007-09-26 04:37:20Z alexcher $
-% PDF linearizer ("optimizer").
-
-.currentglobal true .setglobal
-/pdfoptdict 200 dict def
-pdfoptdict begin
-
-% This linearizer is designed for simplicity, not for performance.
-% See the main program (the last procedure in the file) for comments
-% describing the main processing sequence.
-
-% ---------------- Utilities ---------------- %
-
-% ------ Data structures ------ %
-
-% Distinguish dictionaries, arrays, and everything else.
-/ifdaelse { % <obj> <dictproc> <arrayproc> <otherproc> ifdaelse -
- 3 index type dup /dicttype eq {
- pop pop pop
- } {
- dup /arraytype ne exch /packedarraytype ne and {
- exch
- } if pop exch pop
- } ifelse exec
-} bind def
-
-% Implement dynamically growable arrays using a dictionary.
-/darray { % <size> darray <darray>
- dict
-} bind def
-/dadd { % <darray> <value> dadd -
- 1 index length exch put
-} bind def
-/daforall { % <darray> <proc> daforall -
- /exch cvx /get cvx 3 -1 roll /exec cvx 5 packedarray cvx
- 0 1 2 index 0 get length 1 sub 4 -1 roll for
-} bind def
-/dacontents { % <darray> dacontents <array>
- [ exch { } daforall ]
-} bind def
-/dacontstring { % <darray> dacontstring <string>
- 0 1 index { exch pop length add } forall string
- dup /NullEncode filter
- % Stack: darray str filter
- 3 -1 roll { 1 index exch writestring } daforall
- closefile
-} bind def
-
-% Force an object, mapping it if it is a reference.
-/omforcenew { % <obj> omforce <obj'> <notseen>
- dup oforce 2 copy eq { pop true } { exch 0 get omapnew exch pop } ifelse
-} bind def
-/omforce { % <obj> omforce <obj'>
- omforcenew pop
-} bind def
-/omget { % <dict|array> <key> omget <obj>
- get omforce
-} bind def
-% Visit an entire tree.
-/omvisit { % <obj> omvisit -
- omforcenew {
- { { omvisit omvisit } forall }
- { { omvisit } forall }
- { pop }
- ifdaelse
- } {
- pop
- } ifelse
-} bind def
-% Visit a tree, stopping at references to Page objects.
-% (This is only needed for the OpenAction in the Catalog.)
-/omvisitnopage { % <obj> omvisitnopage -
- dup oforce dup type /dicttype eq {
- /Type .knownget { /Page eq } { false } ifelse
- } {
- pop false
- } ifelse {
- pop % Page reference
- } {
- omforcenew {
- { { omvisitnopage omvisitnopage } forall }
- { { omvisitnopage } forall }
- { pop }
- ifdaelse
- } {
- pop
- } ifelse
- } ifelse
-} bind def
-
-% Collect the list of currently mapped object numbers, in order.
-/omapped { % - omapped <obj#s>
- RMap ld_length larray exch lgrowto
- RMap {
- 2 index 3 1 roll 1 sub exch lput
- } ld_forall
-} bind def
-
-% Collect the list of object numbers passed to omap by a procedure.
-/visited { % <proc> visited <obj#s>
- false currentomap 2 .execn
- omapped exch setomap
-} bind def
-
-% ------ Output ------ %
-
-% Provide a framework for closure-based streams.
-.currentglobal false .setglobal
-userdict /clostreams 20 dict put % stream -> [data endproc]
-.setglobal
-% Create a closure-based stream.
-/clostream { % <data> <proc> <endproc> clostream <stream>
- 2 index 3 -1 roll /exec load 3 packedarray cvx
- /NullEncode filter
- % Stack: data endproc stream
- clostreams 1 index 5 -2 roll 2 array astore put
-} bind def
-% Close a closure-based stream.
-/closend { % <stream> closend <result>
- dup closefile clostreams exch
- 2 copy get 3 1 roll undef aload pop exec
-} bind def
-
-% Implement in-memory output streams.
-/msproc { % <data> <more> <accum> msproc <scratch>
- 3 -1 roll dadd { 100 string } { () } ifelse
-} bind def
-/mstream { % - mstream <mstream>
- 10 darray {msproc} {dacontstring} clostream
-} bind def
-/mcontents { % <mstream> mcontents <string>
- closend
-} bind def
-
-% Implement a stream that only keeps track of its position.
-% (All streams should do this, but the PLRM doesn't require it.)
-/posbuf 100 string def
-/posproc { % <data> <more> <accum> posproc <scratch>
- 0 2 copy get 5 -1 roll length add put
- pop //posbuf
-} bind def
-/postream { % - postream <postream>
- [0] {posproc} {0 get} clostream
-} bind def
-/poslength { % <postream> poslength <pos>
- closend
-} bind def
-
-% Implement streams with variable-bit-width data.
-% Note that these are dictionary objects, not stream objects.
-/bitstream { % <stream> bitstream <bstream>
- 4 dict begin /S exch def /N 8 def /B 0 def
- currentdict end
-} bind def
-/bitwrite { % <bstream> <value> <width> bitwrite -
- PDFOPTDEBUG { ( ) print 1 index =only (:) print dup = } if
- 3 -1 roll begin
- N exch sub dup 0 ge {
- /N exch def N bitshift B add
- } {
- 2 copy bitshift B add S exch write
- % Stack: value -left
- { 8 add dup 0 ge { exit } if
- 2 copy bitshift 255 and S exch write
- } loop
- /N 1 index def bitshift 255 and
- } ifelse /B exch def
- end
-} bind def
-/bitflush { % <bstream> bitflush -
- begin N 8 ne { S B write /B 0 def /N 8 def } if end
-} bind def
-
-/bwn { % <value> <width> bwn -
- 2 copy % v w v w
- 2 exch exp ge { % v w v>=2**w
- /bwn cvx /rangecheck signalerror
- } if
- bits 3 1 roll bitwrite
-} def
-
-% Capture OFile output on the temporary file, in memory, or just as a length.
-/totemp { % <proc> totemp <start> <end>
- TFile fileposition OFile
- /OFile TFile def 3 .execn
- /OFile exch def
- TFile fileposition
-} bind def
-/tomemory { % <proc> tomemory <string>
- OFile /OFile mstream def 2 .execn
- OFile mcontents exch /OFile exch def
-} bind def
-/tolength { % <proc> tolength <string>
- OFile /OFile postream def 2 .execn
- OFile poslength exch /OFile exch def
-} bind def
-
-% Copy a range of bytes from TFile to OFile.
-/copyrange { % <start> <end> copybytes -
- TFile 2 index setfileposition
- exch sub 1024 string exch {
- % Stack: buf left
- 2 copy 1 index length .min 0 exch getinterval
- TFile exch readstring pop OFile exch writestring
- 1 index length sub dup 0 le { exit } if
- } loop pop pop
-} bind def
-
-% Pad with blanks to a specified position.
-/padto { % <pos> padto -
- OFile fileposition sub
- dup 0 lt {
- (ERROR: file position incorrect by ) print =
- /padto cvx /rangecheck signalerror
- } {
- { ( ) ows } repeat
- } ifelse
-} bind def
-
-% ---------------- Read objects into memory ---------------- %
-
-/touch { % <object> touch -
- {
- { touch touch } forall
- } {
- dup xcheck {
- % Executable array, must be an indirect object.
- dup 0 get resolved? { pop pop } { oforce touch } ifelse
- } {
- { touch } forall
- } ifelse
- } {
- pop
- } ifdaelse
-} bind def
-
-% ---------------- Replace references with referents ---------------- %
-
-/replaceable? { % <value> replaceable? <bool>
- dup type /integertype eq exch xcheck not and
-} bind def
-/replacement { % <obj|ref> replacement <obj'>
- dup oforce dup replaceable? { exch } if pop
-} bind def
-
-/replacerefs { % <object> replacerefs <object>
- {
- dup {
- 2 index 2 index undef
- exch replacement exch replacement
- 2 index 3 1 roll put
- } forall
- } {
- 0 1 2 index length 1 sub {
- 1 index exch 2 copy get replacement put
- } for
- } {
- } ifdaelse
-} bind def
-
-/replaceReferences { % - replaceReferences -
- Objects { replacerefs pop } lforall
- % Delete replaced objects.
- 0 1 Objects llength 1 sub {
- Objects 1 index lget replaceable? {
- PDFOPTDEBUG { (Deleting ) print dup = } if
- Generations 1 index 0 lput
- } if pop
- } for
-} bind def
-
-% ---------------- Create new objects ---------------- %
-
-/createObjects { % [<obj>...] createObjects <firstobj#>
- Objects llength dup
- dup 3 index length add growPDFobjects
- % Stack: objects objn objn
- 3 1 roll exch {
- Objects 2 index 3 -1 roll lput
- Generations 1 index 1 lput
- 1 add
- } forall pop
-} bind def
-
-% ---------------- Propagate attributes ---------------- %
-
-/nopropattrs <<
- % Never propagate these.
- /Type dup /Kids dup /Count dup /Parent dup
- % Handle Resources specially.
- /Resources dup
->> def
-
-% Merge Resources.
-/mergeres { % <fromdict> <todict> mergeres -
- % Values in todict take priority over fromdict.
- 1 index /Resources .knownget {
- 1 index /Resources .knownget {
- % Stack: fromdict todict fromres tores
- exch oforce exch oforce
- % todict's Resources may be shared, so make a copy.
- dup length dict .copydict
- exch {
- % Stack: fromdict todict tores' fromkey fromvalue
- 2 index 2 index knownoget {
- % Stack: fromdict todict tores' fromkey fromvalue tovalue
- exch oforce exch
- % ProcSet is an array, other types are dictionaries.
- dup type /dicttype eq {
- % Dictionary, not ProcSet.
- exch dup length 2 index length add dict .copydict .copydict
- } {
- % Array or packed array, ProcSet.
- % Use dictionaries to do the merge.
- dup length 2 index length add dict begin
- exch { dup def } forall { dup def } forall
- mark currentdict end { pop } forall .packtomark
- } ifelse
- } if
- 2 index 3 1 roll put
- } forall
- } if /Resources exch put pop
- } {
- pop pop
- } ifelse
-} bind def
-
-% Merge attributes other than Resources.
-/mergeattrs { % <fromdict> <todict> mergeattrs <fromdict> <todict>
- % Values in todict take priority over fromdict.
- 1 index {
- % Stack: fromdict todict fromkey fromvalue
- //nopropattrs 2 index known {
- pop pop
- } {
- 2 index 2 index known { pop pop } { 2 index 3 1 roll put } ifelse
- } ifelse
- } forall
-} bind def
-
-% Propagate attributes to a subtree.
-/proppage { % <attrs> <subtree> proppage -
- % We should be able to tell when we reach a leaf
- % by finding a Type unequal to /Pages. Unfortunately,
- % some files distributed by Adobe lack the Type key
- % in some of the Pages nodes! Instead, we check for Kids.
- dup /Kids knownoget {
- % Accumulate inherited values.
- 3 1 roll
- % Stack: kids attrs pagesnode
- dup length dict .copydict mergeattrs
- dup 3 1 roll mergeres
- exch { oforce 1 index exch proppage } forall pop
- } {
- % Merge inherited values into the leaf.
- mergeattrs mergeres
- } ifelse
-} bind def
-
-% Propagate attributes to all pages.
-/propagateAttributes { % - propagateAttributes -
- 0 dict Trailer /Root oget /Pages oget proppage
-} bind def
-
-% ---------------- Identify document-level objects ---------------- %
-
-/identifyDocumentObjects { % - identifyDocumentObjects <obj#s>
- {
- Trailer /Root omget
- dup /PageMode .knownget { omvisit } if
- % Don't allow omvisit to trace references to Page objects.
- dup /OpenAction .knownget { omvisitnopage } if
- Trailer /Encrypt .knownget { omvisit } if
- dup /Threads .knownget {
- omforce dup //null ne { { omvisit } forall } { pop } ifelse
- } if
- dup /AcroForm .knownget { omvisitnopage } if
- pop
- } visited
-} bind def
-
-% ---------------- Identify the objects of each page ---------------- %
-
-/identifyfont { % <fontref> identifyfont -
- omforce {
- exch /FontDescriptor eq {
- omforce dup /Flags .knownget { 32 and 0 ne } { false } ifelse
- exch {
- exch dup dup /FontFile eq exch /FontFile2 eq or
- exch /FontFile3 eq or 2 index and {
- fontfiles exch dadd
- } {
- omvisit
- } ifelse
- } forall pop
- } {
- omvisit
- } ifelse
- } forall
-} bind def
-
-% Collect all the objects referenced from a page. The first object number
-% (which may not be the smallest one) is that of the page object itself.
-/identifyPageObjects { % <extra> <page#> identifyPageObjects <obj#s>
- PDFOPTDEBUG {
- (%Objects for page: ) print dup =
- } if
- pdffindpageref
- dup 0 get 3 1 roll
- 4 dict begin
- /filter_params 10 darray def
- /images 10 darray def
- /fontfiles 10 darray def
- {
- omforce
- % Stack: pageobj# extra page
- % Visit any extra objects if applicable.
- exch omvisit
- % Visit Annots, if any.
- % We don't try to defer the drawing information.
- dup /Annots .knownget { omvisitnopage } if
- % Visit beads.
- dup /B .knownget { omvisit } if
- % Visit resources dictionaries.
- dup /Resources .knownget {
- omforce dup {
- % Visit the first-level Resource dictionaries.
- omforce pop pop
- } forall {
- % Visit the resources themselves.
- % Skip Image XObjects, and FontFile streams if the
- % FontDescriptor Flags have bit 6 set.
- % We don't try to visit the resources in the order in which
- % the Contents stream(s) reference(s) them.
- exch dup /XObject eq {
- pop oforce {
- dup oforce /Subtype get /Image eq {
- dup oforce /DecodeParms .knownget {
- oforce {
- exch /JBIG2Globals eq {
- filter_params exch dadd
- } {
- pop
- } ifelse
- } forall
- } if
- images exch dadd
- } {
- omvisit
- } ifelse pop
- } forall
- } {
- /Font eq {
- oforce { identifyfont pop } forall
- } {
- oforce omvisit
- } ifelse
- } ifelse
- } forall
- } if
- % Visit the Contents stream(s).
- dup /Contents .knownget { omvisit } if
- % Visit Image XObjects. We don't try to visit them in
- % reference order.
- filter_params { omvisit } daforall
- images { omvisit } daforall
- % Visit FontFile streams. We don't try to visit them in
- % reference order.
- fontfiles { omvisit } daforall
- pop
- } visited end
- % Stack: pageobj# obj#s_larray
- [ 3 1 roll {
- 2 copy eq { pop } { exch } ifelse
- } lforall counttomark 1 roll ]
- PDFOPTDEBUG {
- (%Objects = ) print dup === flush
- } if
-} bind def
-
-% Identify the objects of the first page.
-/identifyFirstPageObjects { % - identifyFirstPageObjects <obj#s>
- Trailer /Root oget null
- 1 index /PageMode knownoget {
- /UseOutlines eq {
- 1 index /Outlines knownoget { exch pop } if
- } if
- } if exch pop
- 1 identifyPageObjects
-} bind def
-
-% Identify the non-shared objects of the other pages, and the shared objects.
-% Note that the page objects themselves may appear to be shared, because of
-% references from Dest entries in annotations, but they must be treated as
-% non-shared. Note also that some objects referenced on the first page may
-% also be referenced from other pages.
-/identifyOtherPageObjects { % - identifyOtherPageObjects [<pageobj#s> ...]
- % <sharedobj#s>
- 4 dict begin
- /marks lstring Objects llength lgrowto def
- % Collect objects of other pages and identify sharing.
- [ 2 1 pdfpagecount { null exch identifyPageObjects } for ]
- dup {
- { marks exch 2 copy lget 1 add 254 .min lput } forall
- } forall
- % Mark document-level and first page objects.
- CatalogNs { marks exch 255 lput } lforall
- FirstPageNs { marks exch 255 lput } forall
- % Mark the page objects themselves as non-shared.
- dup {
- 0 get marks exch 1 lput
- } forall
- % Collect the non-shared objects of each page.
- dup
- [ exch {
- [ exch {
- marks 1 index lget 1 ne { pop } if
- } forall ]
- } forall ]
- % Collect the shared objects of each page.
- exch
- [ exch {
- [ exch {
- marks 1 index lget dup 1 le exch 255 eq or { pop } if
- } forall ]
- } forall ]
-
- % Collect the shared objects.
- [ 1 1 marks llength 1 sub {
- marks 1 index lget dup 1 le exch 255 eq or { pop } if
- } for ]
-
- end
-} bind def
-
-% Identify objects not associated with any page.
-/identifyNonPageObjects { % - identifyNonPageObjects <obj#s>
- 4 dict begin
- /marks lstring Objects llength lgrowto def
-
- LPDictN marks exch 1 lput
- PHSN marks exch 1 lput
- CatalogNs { marks exch 1 lput } lforall
- FirstPageNs { marks exch 1 lput } forall
- SharedNs { marks exch 1 lput } forall
- OtherPageNs { { marks exch 1 lput } forall } forall
-
- %****** PUT THESE IN A REASONABLE ORDER ******
- /npobj larray
- 0
- 1 1 Objects llength 1 sub {
- marks 1 index lget 0 eq {
- Generations exch lget 0 ne { 1 add } if
- } {
- pop
- } ifelse
- } for
- lgrowto def
-
- 0
- 1 1 Objects llength 1 sub {
- marks 1 index lget 0 eq {
- % i
- Generations 1 index lget 0 ne {
- % i
- npobj 2 index % i nobj 0
- 3 -1 roll % nobj 0 i
- lput 1 add
- } {
- pop
- } ifelse
- } {
- pop
- } ifelse
- } for
- pop
-
- npobj
- end
-} bind def
-
-% ---------------- Assign object numbers ---------------- %
-
-% Assign object numbers to all objects that will be copied.
-% Return the first (translated) object number in the First Page xref table.
-/assignObjectNumbers { % - assignObjectNumbers -
- OtherPageNs { { omap pop } forall } forall
- SharedNs { omap pop } forall
- NonPageNs { omap pop } lforall
- % Assign object numbers for the First Page xref table last.
- LPDictN omap % don't pop, this is the return value
- CatalogNs { omap pop } lforall
- FirstPageNs { omap pop } forall
- PHSN omap pop
-} bind def
-
-% ---------------- Create the LPDict ---------------- %
-
-% Create the contents of the LPDict.
-/createLPDict { % <phsstart> <phsend> <firstpageend>
- % <xref0start> <filelength> createLPDict -
- LPDict
- dup /Linearized 1 put
- dup /L 4 -1 roll put % filelength
- dup /T 4 -1 roll put % xref0start
- dup /E 4 -1 roll put % firstpageend
- dup /H 5 -2 roll 1 index sub 2 array astore put % phsstart, end-start
- dup /O 1 pdffindpageref 0 get omap put
- /N pdfpagecount put
-} bind def
-
-% ---------------- Adjust object positions ---------------- %
-
-/adjustObjectPositions { % <boundary> <deltabelow> <deltaabove>
- % adjustObjectPositions -
- % Objects fall into 4 categories: LPDict, PHS, Catalog, and others.
- % We handle the first two as special cases.
- XRef {
- % Stack: bdy below above key loc
- dup 5 index ge { 2 } { 3 } ifelse index add
- XRef 3 1 roll ld_put
- } ld_forall pop pop pop
- XRef LPDictN omap HeaderLength ld_put
- XRef PHSN omap PHSStart ld_put
-} bind def
-
-% ---------------- Write the output file ---------------- %
-
-% Write objects identified by object number.
-/writeobjn { % <obj#> writeobjn -
- Generations 1 index lget pdfwriteobj
-} bind def
-/writeobjns { % <obj#s> writeobjns -
- { writeobjn } forall
-} bind def
-/lwriteobjns { % <obj#s> writeobjns -
- { writeobjn } lforall
-} bind def
-
-% Write a part of the output file.
-/writePart { % <proc> <label> writePart -
- PDFOPTDEBUG {
- dup print ( count=) print count =only ( start=) print
- OFile { .fileposition } stopped { pop (???) } if =
- 2 .execn
- print ( end=) print
- OFile { .fileposition } stopped { pop (???) } if =
- } {
- pop exec
- } ifelse
-} bind def
-
-% Write the header.
-/writePart1 { % - writePart1 -
- {
- pdfwriteheader
- } (part1) writePart
-} bind def
-
-% Write the linearization parameters dictionary.
-/writePart2 { % - writePart2 -
- {
- LPDictN writeobjn
- } (part2) writePart
-} bind def
-
-% Write the First Page xref table and trailer.
-% Free variables: FirstPageXN.
-/writePart3 { % <xrefstart> writePart3 -
- {
- FirstPageXN NObjects 1 add 1 index sub pdfwritexref
- Trailer dup length 1 add dict copy
- dup /Size NObjects 1 add put
- dup /Prev 4 -1 roll put
- pdfwritetrailer
- 0 pdfwritestartxref
- } (part3) writePart
-} bind def
-
-% Write the Catalog and other required document-level objects.
-% Free variables: CatalogNs.
-/writePart4 { % - writePart4 -
- {
- CatalogNs lwriteobjns
- } (part4) writePart
-} bind def
-
-% Write the Primary Hint Stream.
-/writePart5 { % - writePart5 -
- {
- PHSN writeobjn
- } (part5) writePart
-} bind def
-
-% Write the First Page's objects.
-% Free variables: FirstPageNs.
-/writePart6 { % - writePart6 -
- {
- FirstPageNs writeobjns
- } (part6) writePart
-} bind def
-
-% Write the objects of other pages (Page + non-shared objects).
-% Free variables: OtherPageNs.
-/writePart7 { % - writePart7 <lengths>
- {
- [ OtherPageNs {
- OFile fileposition exch
- writeobjns OFile fileposition exch sub
- } forall ]
- } (part7) writePart
-} bind def
-
-% Write the shared objects of other pages.
-% Free variables: SharedNs.
-/writePart8 { % - writePart8 -
- {
- SharedNs writeobjns
- } (part8) writePart
-} bind def
-
-% Write the other objects not associated with pages.
-% Free variables: NonPageNs.
-/writePart9 { % - writePart9 -
- {
- NonPageNs { writeobjn } lforall
- } (part9) writePart
-} bind def
-
-% Write the main xref table and trailer.
-% Free variables: FirstPageXN.
-/writePart11xref { % writePart11 -
- {
- 0 FirstPageXN pdfwritexref
- } (part11xref) writePart
-} bind def
-/writePart11rest { % <part3start> writePart11rest -
- {
- << /Size FirstPageXN >> pdfwritetrailer
- pdfwritestartxref
- } (part11rest) writePart
-} bind def
-
-% ---------------- Write hint tables ---------------- %
-
-/bitsneeded { % <maxvalue> bitsneeded <#bits>
- 0 exch { dup 0 eq { pop exit } if exch 1 add exch 2 idiv } loop
-} bind def
-
-% Find the start and end of objects in the output.
-/omstart { % <obj#> omstart <pos>
- PDFOPTDEBUG { (start\() print dup =only } if
- omap
- PDFOPTDEBUG { (=>) print dup =only } if
- XRef exch ld_get
- PDFOPTDEBUG { (\) = ) print dup = } if
-} bind def
-/omend { % <obj#> omend <pos>
- % The end of an object is the start of the next object.
- % The caller must be sure that this object is not the last one
- % in part 9.
- PDFOPTDEBUG { (end\() print dup =only } if
- omap
- PDFOPTDEBUG { (=>) print dup =only } if
- 1 add
- % Check that the requested object wasn't the last one in part 6:
- % the next object in the output file is the first in part 7.
- PHSN omap 1 index eq { pop 1 } if
- XRef exch ld_get
- PDFOPTDEBUG { (\) = ) print dup = } if
-} bind def
-/omlength { % <obj#> omlength <length>
- dup omend exch omstart sub
-} bind def
-
-% Find the Contents of a page.
-/contentsobjects { % <pagedict> contentsobjects <firstobj#> <lastobj#> true
- % <pagedict> contentsobjects false
- /Contents .knownget {
- dup oforce % ref []
- dup type /dicttype eq {
- pop 0 get dup true % ref ref
- } {
- exch pop % []
- dup length 0 ne {
- dup 0 get 0 get % [] 1st
- exch dup % 1st [] []
- length 1 sub get 0 get % 1st last
- true
- } {
- pop false
- } ifelse
- } ifelse
- } {
- false
- } ifelse
-} bind def
-
-/contentsstart { % <pagedict> contentsstart <pos> true
- % <pagedict> contentsstart false
- contentsobjects { pop omstart true } { false } ifelse
-} bind def
-
-/contentslength { % <pagedict> contentslength <length>
- contentsobjects { omend exch omstart sub } { 0 } ifelse
-} bind def
-
-
-/writePageOffsetHints {
- PDFOPTDEBUG { /writePageOffsetHints == } if
- 20 dict begin
- /bits OFile bitstream def
-
- % Calculate least length of a page.
- FirstPageLength OtherPageLengths { .min } forall
- /minpl exch def
-
- % Calculate least contents length.
- FirstPageNs 0 get Objects exch lget contentslength
- OtherPageNs { 0 get Objects exch lget contentslength .min } forall
- /mincl exch def
-
- % The Adobe documentation says that all versions of Acrobat
- % require item 8 (mincl) to be zero. Patch this here.
- /mincl 0 def
-
- % Calculate bits needed to represent greatest page length.
- FirstPageLength OtherPageLengths { .max } forall
- minpl sub bitsneeded /maxplbits exch def
- % Calculate bits needed to represent the greatest Contents length.
- FirstPageNs 0 get Objects exch lget contentslength
- OtherPageNs { 0 get Objects exch lget contentslength .max } forall
- mincl sub bitsneeded /maxclbits exch def
-
- % Per Adobe documentation, Acrobat requires that item 5 (maxplbits)
- % be equal to item 9 (maxclbits). Set both to the max of the two.
- maxplbits maxclbits .max /maxplbits 1 index def /maxclbits exch def
-
- % Mapping from object number to shared object reference
- /shared_id_dict FirstPageNs length SharedNs length add dict begin
- 0 FirstPageNs { 1 index def 1 add } forall
- SharedNs { 1 index def 1 add } forall
- pop
- currentdict end def
-
- % Table F.3 Page offset hint table, header section
-
- % 1: Least number of objects in a page:
- FirstPageNs length OtherPageNs { length .min } forall
- /minnop 1 index def 32 bwn
- % 2: Location of first page's Page object:
- FirstPageNs 0 get omap XRef exch ld_get 32 bwn
- % 3: Bits needed to represent greatest # of objects in a page:
- FirstPageNs length OtherPageNs { length .max } forall
- minnop sub bitsneeded /maxnopbits 1 index def 16 bwn
- % 4: Least length of a page:
- minpl 32 bwn
- % 5: Bits needed to represent the greatest page length:
- maxplbits 16 bwn
- % 6: Least start of Contents offset:
- 0 % (Acrobat requires that this be 0.)
- /minsco 1 index def 32 bwn
- % 7: Bits needed to represent the greatest start of Contents
- % offset:
- 0 % (Acrobat ignores this.)
- /maxscobits 1 index def 16 bwn
- % 8: Least contents length:
- mincl 32 bwn
- % 9: Bits needed to represent the greatest Contents length:
- maxclbits 16 bwn
- % 10: Bits needed to represent the greatest number of Shared
- % Object references:
- FirstPageNs length SharedPageNs { length .max } forall bitsneeded
- /maxsorbits 1 index def 16 bwn
- % 11: Bits needed to identify a Shared Object:
- FirstPageNs length SharedNs length add bitsneeded
- /sobits 1 index def 16 bwn
- % 12: Bits needed to represent numerator of fraction:
- 2
- /numfbits 1 index def 16 bwn
- % 13: Denominator of fraction:
- 1
- /denf 1 index def 16 bwn
-
- % Table F.4 Page offset hint table, per-page entry
-
- % 1: Number of objects in pages:
- FirstPageNs length minnop sub maxnopbits bwn
- OtherPageNs {
- length minnop sub maxnopbits bwn
- } forall
- bits bitflush
-
- % 2: Total length of pages in bytes;
- FirstPageLength minpl sub maxplbits bwn
- OtherPageLengths {
- minpl sub maxplbits bwn
- } forall
- bits bitflush
-
- % 3: Number of shared objects referenced from page:
- FirstPageNs length maxsorbits bwn
- SharedPageNs { length maxsorbits bwn } forall
- bits bitflush
- % 4: A shared object identifier:
- FirstPageNs { shared_id_dict exch get sobits bwn } forall
- SharedPageNs {
- { shared_id_dict exch get sobits bwn
- } forall
- } forall
- bits bitflush
-
- % 5: Numerator of fractional position for each shared object:
- FirstPageNs { pop 0 numfbits bwn } forall
- SharedPageNs {
- { pop 0 numfbits bwn
- } forall
- } forall
- bits bitflush
-
- % 6: Contents offsets:
- % Following Implementation Note 133 section 6 is empty.
- maxscobits 0 gt {
- [FirstPageNs OtherPageNs aload pop] {
- 0 get Objects exch lget contentsstart { minsco sub } { 0 } ifelse
- maxscobits bwn
- } forall
- bits bitflush
- } if
-
- % 7: Contents lengths:
- [FirstPageNs OtherPageNs aload pop] {
- 0 get Objects exch lget contentslength mincl sub maxclbits bwn
- } forall
- bits bitflush
-
- end
-
-} bind def
-
-/writeSharedObjectHints {
- PDFOPTDEBUG { /writeSharedObjectHints == } if
- 20 dict begin
- /bits OFile bitstream def
- /obj_count SharedNs length FirstPageNs length add def
-
- % Table F.5 Shared object hint table, header section
-
- % 1: Object number of first object in Shared Objects section
- 0 32 bwn
- % 2: Location of first object in Shared Objects section:
- % If there are no shared objects,
- % Acrobat sets this to the location of linearization
- % parameters object (the very first object).
- { pdfwriteheader } tomemory length 32 bwn
- % 3: Number of Shared Object entries for first page:
- FirstPageNs length 32 bwn
- % 4: Number of Shared Object entries for Shared Objects
- % section
- obj_count 32 bwn
- % 5: Bits needed to represent the greatest number of objects
- % in a shared object group (always 0, because all groups
- % have only 1 object):
- 0 16 bwn
- % 6: Least length of a Shared Object Group in bytes:
- 16#7fffffff FirstPageNs { omlength .min } forall
- SharedNs { omlength .min } forall
- /minsol 1 index def 32 bwn
- % 7: Bits needed to represent the greatest length of a
- % Shared Object Group:
- 0 FirstPageNs { omlength .max } forall
- SharedNs { omlength .max } forall
- minsol sub bitsneeded
- /maxsolbits 1 index def 16 bwn
-
- % Table F.6 Shared object hint table, shared object group entry
-
- % 1: Lengths of shared object groups:
- FirstPageNs { omlength minsol sub maxsolbits bwn } forall
- SharedNs { omlength minsol sub maxsolbits bwn } forall
- bits bitflush
- % 2: MD5 flag:
- obj_count { 0 1 bwn } repeat
- bits bitflush
- % 3: No MD5 shared object signatures.
-
- % 4: No number_number_of_objects_in_the_group - 1
- end
-} bind def
-
-% ---------------- Main program ---------------- %
-
-/pdfOptimize { % <infile> <outfile> pdfOptimize -
- realtime 3 1 roll
- exch pdfdict begin pdfopenfile dup begin
- 40 dict begin
- /IDict exch def
- /OFile exch def
- /starttime exch def
- /ToWrite 100 dict def
- /now {
- QUIET { pop } { print (, t = ) print realtime starttime sub = flush } ifelse
- } def
- omapinit
-
- % Create and open a temporary file.
- % Because of .setsafe, we have to open it as read-write, rather than
- % opening for writing, then closing it and reopening it for reading.
-
- null (w+) .tempfile /TFile exch def /TFileName exch def
- .setsafe
-
- % Read all objects into memory.
-
- Trailer touch
- (Read objects) now
-
- % Encrypted files are not yet supported.
- Trailer /Encrypt known {
- (ERROR: Encrypted files are not yet supported.) = flush
- /pdfOptimize cvx /limitcheck signalerror
- } if
-
- % Replace indirect references to numbers. This is needed
- % for the Length of streams, and doesn't hurt anything else.
-
- replaceReferences
- (Replaced references) now
-
- % Create the two new objects: the linearization parameter
- % dictionary, and the Primary Hint Stream.
-
- /LPDict 10 dict def
- /PHS 10 dict cvx def % executable = stream
- [LPDict PHS] createObjects
- /LPDictN 1 index def 1 add
- /PHSN exch def
- PDFOPTDEBUG { << /LPDictN LPDictN /PHSN PHSN >> === } if
-
- % Count the number of objects in the output.
-
- 0 0 1 Objects llength 1 sub {
- Generations exch lget 0 ne { 1 add } if
- } for
- /NObjects exch def
- QUIET not { NObjects =only ( objects total) = flush } if
-
- % Propagate inherited attributes down the page tree.
-
- propagateAttributes
- (Propagated attributes) now
-
- % Identify the document-level objects (part 4).
-
- identifyDocumentObjects /CatalogNs exch def
- QUIET not { CatalogNs === flush } if
- (Identified Catalog) now
-
- % Identify the first page's objects (part 6),
- % including the Outlines tree if appropriate.
-
- pdfopencache
- /FirstPageNs identifyFirstPageObjects def
- QUIET not { FirstPageNs === flush } if
- (Identified first page) now
-
- % Identify shared vs. non-shared objects for remaining pages
- % (parts 7 and 8).
-
- identifyOtherPageObjects
- /SharedNs exch def
- /SharedPageNs exch def
- /OtherPageNs exch def
- QUIET not { OtherPageNs === flush SharedNs === flush } if
- (Identified other pages) now
-
- % Identify objects not associated with any page (part 9).
-
- /NonPageNs identifyNonPageObjects def
- QUIET not { NonPageNs { === } forall flush } if
- (Identified non-pages) now
-
- % Assign final object numbers to all the objects.
- % (The omap is currently empty.)
-
- /FirstPageXN assignObjectNumbers def
- (Assigned objects #s) now
-
- % Write the document-level objects (part 4).
-
- { writePart4 } totemp
- /CatalogTempEnd exch def /CatalogTempStart exch def
- (Wrote Catalog) now
-
- % Write the first page's objects (part 6).
-
- { writePart6 } totemp
- /FirstPageTempEnd exch def /FirstPageTempStart exch def
- (Wrote first page) now
-
- % Write the non-shared objects for other pages (part 7).
-
- { writePart7 /OtherPageLengths exch def } totemp
- /OtherPageTempEnd exch def /OtherPageTempStart exch def
- (Wrote other pages) now
-
- % Write the shared objects for other pages (part 8).
-
- { writePart8 } totemp
- /SharedTempEnd exch def /SharedTempStart exch def
- (Wrote shared objects) now
-
- % Write the objects not associated with pages (part 9).
-
- { writePart9 } totemp
- /NonPageTempEnd exch def /NonPageTempStart exch def
-
- % Compute conservative lengths of parts 2,3,5,11 of the output.
- % It's OK for these to be too large, but not too small.
-
- % Make dummy XRef entres for LPDict and PHS.
- XRef LPDictN omap 0 ld_put
- XRef PHSN omap 0 ld_put
-
- /HeaderLength { % this is exact
- writePart1 % part 1
- } tolength def
- /CatalogLength % this is exact
- CatalogTempEnd CatalogTempStart sub def % part 4
- /FirstPageLength % this is exact
- FirstPageTempEnd FirstPageTempStart sub def % part 6
- /OtherObjectsLength % this is exact
- NonPageTempEnd OtherPageTempStart sub def % parts 7,8,9
- /ObjectsLength % this is exact
- CatalogLength FirstPageLength add OtherObjectsLength add def
- /XrefLength { % part 11
- % The LPDict must end within the first 1024 bytes,
- % so the start of the FirstPage xref table can't exceed 1024.
- writePart11xref 1024 writePart11rest
- } tolength def
- /NominalFileLength % Make a generous allowance for parts 2,3,5.
- HeaderLength ObjectsLength 3 mul add 10000 add 99999 .max def
- /FirstPageXrefLength { % part 3
- NominalFileLength writePart3
- } tolength def
- /LPDictLength { % part 2
- NominalFileLength dup 2 mul 2 copy add 1 index dup createLPDict writePart2
- } tolength def
-
- % Compute a few additional values from the above.
-
- /XrefBeginLength {
- (xref\n0 ) ows
- OFile FirstPageXN write=
- } tolength def
- HeaderLength LPDictLength add
- /FirstPageXrefStart 1 index def
- FirstPageXrefLength add
- /CatalogStart 1 index def
- CatalogLength add % phsstart
- /PHSStart exch def
-
- % Adjust the object positions ignoring PHS.
- % (Writing the PHS needs these.)
-
- 0 0 CatalogStart CatalogTempStart sub adjustObjectPositions
- % Make a temporary XRef entry for the PHS, for the benefit of omend.
- XRef PHSN omap CatalogStart ld_put
- (Adjusted positions) now
-
- % Construct the hint tables (part 5).
-
- { writePageOffsetHints } totemp
- pop /PHSTempStart exch def
- { writeSharedObjectHints } totemp
- exch PHSTempStart sub PHS /S 3 -1 roll put
- PHSTempStart sub /PHSTempLength exch def
- (Wrote hints) now
-
- % Prepare to read TFile.
-% TFile closefile
-% /TFile TFileName (r) file def
-
- PHS
- dup /File TFile put
- dup /FilePosition PHSTempStart put
- dup /Length PHSTempLength put
- pop
- /PHSLength { writePart5 } tolength def
-
- % Construct the linearization parameter dictionary (part 2).
-
- PHSStart
- dup PHSLength add % phsend
- /FirstPageStart 1 index def
- dup FirstPageLength add % firstpageend
- dup OtherObjectsLength add
- /XrefStart 1 index def
- XrefBeginLength add % xref0start
- dup XrefBeginLength sub XrefLength add % fileend
- % Because of a bug, Acrobat Reader doesn't recognize any file
- % shorter than 1K as linearized. Patch this here.
- 1024 .max
- /FileLength 1 index def
- createLPDict
-
- % Adjust the object positions again, taking the PHS into account.
-
- PHSStart 0 PHSLength adjustObjectPositions
- (Readjusted positions) now
-
- % Finally, write the output file.
-
- writePart1
- writePart2
- FirstPageXrefStart padto
- XrefStart writePart3
- CatalogStart padto
- CatalogTempStart CatalogTempEnd copyrange % part 4
- writePart5
- FirstPageStart padto
- FirstPageTempStart NonPageTempEnd copyrange % parts 6,7,8,9
- % No Overflow Hint Stream (part 10).
- XrefStart padto
- writePart11xref
- { FirstPageXrefStart writePart11rest } tomemory
- FileLength 1 index length sub padto ows
- (Wrote output file) now
-
- % Wrap up.
-
- TFile closefile TFileName deletefile
- end % temporary dict
- end % IDict
-} bind def
-
-end % pdfoptdict
-.setglobal
-
-% Check for command line arguments.
-[ shellarguments {
- ] dup length 2 eq {
- % Load the pdfwrite utilities if necessary.
- /omapinit where { pop } { (pdfwrite.ps) runlibfile } ifelse
- save exch
- aload pop exch (r) file exch (w) file
- 3000000 setvmthreshold
- 0 setobjectformat
- pdfoptdict begin pdfOptimize end
- restore
- } {
- (Usage: gs -dNODISPLAY -- pdfopt.ps input.pdf output.pdf) = flush quit
- } ifelse
-} {
- pop
-} ifelse
diff --git a/Master/tlpkg/tlgs/lib/pdfwrite.ps b/Master/tlpkg/tlgs/lib/pdfwrite.ps deleted file mode 100644 index f1b380adbfc..00000000000 --- a/Master/tlpkg/tlgs/lib/pdfwrite.ps +++ /dev/null @@ -1,384 +0,0 @@ -% Copyright (C) 1999, 2000, 2001 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pdfwrite.ps 8120 2007-07-13 01:10:56Z alexcher $
-% Writer for transmuting PDF files.
-
-% NOTES:
-% We do editing by replacing objects (in the cache) and then doing a
-% simple recursive walk with object renumbering.
-% Free variables:
-% RMap [per input file] (dict): input_obj# => output_obj#
-% PDFfile (file): current input file
-% OFile (file): current output file
-% XRef (dict): output_obj# => output_file_pos
-% ToWrite: 0..N-1 => [obj# gen#]
-
-/.setlanguagelevel where { pop 2 .setlanguagelevel } if
-.currentglobal true .setglobal
-
-/PDFWRDEBUG where { pop } { /PDFWRDEBUG false def } ifelse
-
-% ======== Long dictionary support =============== %
-
-% The key must be a non-negative iteger.
-
-/ld_dict { % <len> ld_dict <ldict>
- pop << 0 <<>> >>
-} bind def
-
-/ld_length { % <ldict> ld_length <length>
- 0 exch { exch pop length add } forall
-} bind def
-
-/ld_get { % <ldict> <key> ld_get <any>
- dup 3 1 roll -15 bitshift get exch get
-} bind def
-
-/ld_put { % <ldict> <key> <any> ld_put -
- 3 1 roll dup % any ldict key key
- 4 1 roll -15 bitshift % key any ldict key>>15
- 2 copy known {
- get % key any subdict
- 3 1 roll put % -
- } {
- 64 dict dup 6 1 roll % <<>> key any ldict key>>15 <<>>
- put put
- } ifelse % -
-} bind def
-
-/ld_known { % <ldict> <key> ld_known <bool>
- dup 3 1 roll -15 bitshift % key <<>> key<<15
- 2 copy known {
- get exch known
- } {
- pop pop pop //false
- } ifelse
-} bind def
-
-/ld_knownget { % <ldict> <key> ld_known false | <any> true
- dup 3 1 roll -15 bitshift % key <<>> key<<15
- 2 copy known {
- get exch .knownget
- } {
- pop pop pop //false
- } ifelse
-} bind def
-
-/ld_def { % <key> <any> ld_def -
- currentdict 3 1 roll ld_put
-} bind def
-
-/ld_forall { % <ldict> <proc} ld_forall -
- { forall exch pop } aload pop
- 4 2 roll 4 packedarray cvx forall
-} bind def
-
-/ld_clone { % <ldict> ld_clone <ldict copy>
- << exch { dup length dict copy } forall >>
-} bind def
-
-% ================ Object mapping ================ %
-
-% Initialize the object number and location map.
-/omapinit { % - omapinit -
- /RMap 100 ld_dict def
- /XRef 100 ld_dict def
- PDFWRDEBUG { (omapinit) = } if
-} bind def
-
-% Map an object number.
-/omapnew { % <oldobj#> omap <newobj#> <isnew>
- RMap 1 index ld_knownget {
- exch pop //false
- } {
- PDFWRDEBUG { (omap\() print dup =only } if
- RMap dup ld_length 1 add % old# <<>> len+1
- 2 index exch dup % old# <<>> old# len+1 len+1
- 5 1 roll % len+1 old# <<>> old# len+1
- ld_put pop //true % len+1 true
- PDFWRDEBUG { (\) = ) print 1 index = } if
- } ifelse
-} bind def
-/omap { % <oldobj#> omap <newobj#>
- omapnew pop
-} bind def
-
-% Save and restore the object map.
-% Note that currentomap either returns a copy or calls omapinit.
-/currentomap { % <copy> currentomap <omap>
- {
- [RMap ld_clone XRef ld_clone]
- } {
- [RMap XRef] omapinit
- } ifelse
-} bind def
-/setomap { % <omap> setomap -
- aload pop /XRef exch def /RMap exch def
- PDFWRDEBUG {
- (setomap: #Xref = ) print XRef ld_length =only
- (, #RMap = ) print RMap ld_length =
- } if
-} bind def
-
-% ================ Writing ================ %
-
-% ---------------- Low-level output ---------------- %
-
-% Write a string on the output file.
-/ows { % <string> ows -
- OFile exch writestring
-} bind def
-
-% ---------------- Scalars ---------------- %
-
-% Note that the '#' character isn't legal in a name unless it is a prefix
-% for a hex encoded character (for PDF 1.2 and later). The following assumes
-% that the names are already valid PDF 1.2+ names so that we can treat the
-% '#' as a legal character. The next two hex characters are already in the
-% set of valid name characters. PDF 1.1 and earlier allowed spaces in names
-% which probably wouldn't make it past the tokenizer anyway.
-/pdfnamechars
- (!"#$&'*+,-.0123456789:;=?@ABCDEFGHIJKLMNOPQRSTUVWXYZ\\^_`abcdefghijklmnopqrstuvwxyz|~)
-readonly def
-/pdfwritename { % <name> pdfwritename -
- (/) ows .namestring {
- ( ) dup 0 4 -1 roll put
- //pdfnamechars 1 index search {
- pop pop pop
- } {
- pop 0 get 256 add 16 =string cvrs
- dup 0 (#) 0 get put
- } ifelse ows
- } forall
-} bind def
-
-% ---------------- Composite objects ---------------- %
-
-/pdfwriteprocs mark
- /resolveR { pdfwriteref }
- /O { pdfwritenewref }
-.dicttomark readonly def
-/pdfwritearray { % <array> pdfwritearray -
- dup xcheck {
- aload pop //pdfwriteprocs exch get exec
- } {
- % Because of a bug in Acrobat's parser for linearization parameters,
- % we have to include some whitespace after the opening [ (!).
- ([ ) ows { pdfwritevalue (\n) ows } forall (]) ows
- } ifelse
-} bind def
-
-/pdfwritedict { % <dict> pdfwritedict -
- dup xcheck {
- pdfwritestream
- } {
- (<<) ows {
- exch pdfwritevalue ( ) ows pdfwritevalue (\n) ows
- } forall (>>) ows
- } ifelse
-} bind def
-
-% ---------------- References ---------------- %
-
-/pdfwritenewref { % <newobj#> pdfwritenewref -
- OFile exch write=only ( 0 R) ows
-} bind def
-
-/pdfwriteref { % <obj#> <gen#> pdfwriteref -
- 1 index omapnew {
- ToWrite dup length 5 -2 roll 2 packedarray put
- } {
- exch pop exch pop
- } ifelse
- pdfwritenewref
-} bind def
-
-/pdfcopystring 200 string def
-/pdfwritestream { % <streamdict> pdfwritestream -
- % Remove File, FilePosition, and StreamKey;
- % optimize by replacing an indirect Length.
- dup dup length dict copy
- % Stack: origdict dict
- dup /File undef dup /FilePosition undef dup /StreamKey undef
- dup /Length known {
- dup /Length get dup oforce ne {
- dup /Length 2 copy oget put
- } if
- } {
- 1 index /File get dup
- 3 index /FilePosition get setfileposition
- dup 0 (endstream) /SubFileDecode filter flushfile
- .fileposition 9 sub
- 2 index /FilePosition get sub
- 1 index exch /Length exch put
- } ifelse
- exch dup /File get dup 3 -1 roll /FilePosition get setfileposition
- pdfcopystream
-} bind def
-
-% We put copying the stream contents in separate procedures so that we
-% can replace this function if desired.
-/pdfcopybytes { % <fromfile> <tofile> <length> pdfcopybytes -
- {
- dup 0 eq { exit } if
- //pdfcopystring 0 2 index 2 index length .min getinterval
- 3 index exch readstring 3 1 roll
- 3 index 1 index writestring length sub exch not { exit } if
- } loop pop pop pop
-} bind def
-/pdfcopystream { % <newstreamdict> <file> pdfcopystream -
- % (file has been positioned)
- 1 index pdfwritevalue (stream\n) ows
- exch /Length get OFile exch pdfcopybytes
- (endstream) ows
-} bind def
-
-% ---------------- General values/objects ---------------- %
-
-/pdfwritetypes mark
- % Scalars
- /nulltype { pop (null) ows } bind
- /integertype { =string cvs ows } bind
- /booleantype 1 index
- /realtype {
- =string cvs
- (e) search { % PDF has no exponential format
- exch pop % exp pre
- exch cvi exch
- (-) anchorsearch { ows } if
- (.) search {
- exch pop % exp (frac) (int)
- 1 index length % exp (frac) (int) len
- 3 1 roll % exp len (frac) (int)
- exch concatstrings % exp len (int_frac)
- 3 1 roll sub % (int_frac) exp-len
- exch % exp-len (int_frac)
- } if % exp (mant)
- 1 index 0 ge {
- ows { (0) ows } repeat (.) ows
- } {
- dup length % exp (mant) len
- 3 -1 roll add % (mant) exp+len
- dup 0 le {
- (0.) ows neg { (0) ows } repeat ows
- } {
- 2 copy 0 exch getinterval ows
- (.) ows
- 1 index length 1 index sub getinterval ows
- } ifelse
- } ifelse
- } {
- ows
- } ifelse
- } bind
- /stringtype { OFile exch write===only } bind
- /nametype { pdfwritename } bind
- % Composite/reference objects
- /arraytype { pdfwritearray } bind
- /packedarraytype 1 index
- /dicttype { pdfwritedict } bind
-.dicttomark readonly def
-
-/pdfwritevalue { % <obj> pdfwritevalue -
- PDFWRDEBUG { (****Writing: ) print dup === flush } if
- //pdfwritetypes 1 index type get exec
-} bind def
-
-% We make pdfwriteobjdef a separate procedure for external use.
-/pdfwriteobjheader { % <newobj#> pdfwriteobjheader -
- XRef 1 index OFile .fileposition ld_put
- PDFWRDEBUG { (XRef\() print dup =only (\) = ) print XRef 1 index ld_get = } if
- OFile exch write=only ( 0 obj\n) ows
-} bind def
-/pdfwriteobjdef { % <newobj#> <value> pdfwriteobjdef -
- exch pdfwriteobjheader
- pdfwritevalue (\nendobj\n) ows
-} bind def
-/pdfwriteobj { % <obj#> <gen#> pdfwriteobj -
- 1 index exch resolveR exch omap exch pdfwriteobjdef
-} bind def
-
-% ---------------- File-level entities ---------------- %
-
-% Write a PDF file header.
-% Free variables: OFile, PDFversion.
-/pdfwriteheader { % - pdfwriteheader -
- (%PDF-) ows OFile PDFversion write=
- (%\347\363\317\323\n) ows
-} bind def
-
-% Write a cross-reference table and trailer.
-/pdfwritexref { % <firstobj#> <#objs> pdfwritexref -
- (xref\n) ows
- OFile 2 index write=only ( ) ows OFile 1 index write=
- 1 index add 1 sub 1 exch {
- dup 0 eq {
- pop (0000000000 65535 f \n) ows
- } {
- XRef exch ld_get 1000000000 add =string cvs
- dup 0 (0) 0 get put
- ows ( 00000 n \n) ows
- } ifelse
- } for
-} bind def
-/pdfwritetrailer { % <trailer> pdfwritetrailer -
- (trailer\n) ows pdfwritevalue (\n) ows
-} bind def
-/pdfwritestartxref { % <startpos> pdfwritestartxref -
- (startxref\n) ows OFile exch write=
- (%%EOF\n) ows
-} bind def
-
-% ================ Top-level control ================ %
-
-/pdfwrite { % <file> <trailer> pdfwrite -
- 10 dict begin
- /trailer exch def
- /OFile exch def
- /ToWrite 100 dict def
- omapinit
-
- % Write the PDF file header.
-
- pdfwriteheader
-
- % Write the objects.
-
- trailer {
- exch pop dup xcheck { % The only executable objects are references.
- aload pop pop pdfwriteobj
- } {
- pop
- } ifelse
- } forall
- % Walk the object graph.
- {
- ToWrite dup length dup 0 eq { pop pop exit } if
- 1 sub 2 copy get 3 1 roll undef aload pop pdfwriteobj
- } loop
-
- % Write the xref table and trailer.
-
- /xref OFile fileposition def
- 0 XRef ld_length 1 add pdfwritexref
- trailer dup length 1 add dict copy
- dup /Size XRef ld_length 1 add put pdfwritetrailer
- xref pdfwritestartxref
-
- end
-} bind def
-
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/pf2afm.ps b/Master/tlpkg/tlgs/lib/pf2afm.ps deleted file mode 100644 index 0d1f5fe6ac5..00000000000 --- a/Master/tlpkg/tlgs/lib/pf2afm.ps +++ /dev/null @@ -1,515 +0,0 @@ -%!
-% This is a PostScript program for making an AFM file from
-% PFB / PFA and (optionally) PFM files.
-%
-% Written in BOP s.c., Gda\'nsk, Poland
-% e-mail contact: B.Jackowski@GUST.ORG.PL
-% version 0.5 (18 XII 1997)
-% version 0.55 (11 III 1998) -- unlimited number of chars in a font
-% version 1.00 (27 III 1998) -- scanning PFM subdirectory added,
-% code improved; version sent to LPD
-% version 1.01 (1 II 2000) -- message changed
-
-% Usage:
-% gs [-dNODISPLAY] -- pf2afm.ps disk_font_name
-%
-% The result is written to the file disk_font_name.afm, provided such
-% a file does not exist; otherwise program quits.
-%
-% The font can be either *.pfa or *.pfb; if no extension is supplied,
-% first disk_font_name.pfb is examined, then disk_font_name.pfa.
-% Moreover, if there is a *.pfm file in the same directory or in the
-% subdirectory PFM, i.e., disk_font_name.pfm or PFM/disk_font_name.pfm,
-% kern pairs from it are extracted, as well as additional font
-% parameters, usually absent from Type 1 fonts.
-
-% Tribute:
-% $Id: pf2afm.ps 6300 2005-12-28 19:56:24Z giles $
-% The program is based on James Clark's <jjc@jclark.uucp> printafm.ps
-% (with alterations by d.love@dl.ac.uk and L. Peter Deutsch) from
-% Ghostscript 5.10 distribution.
-
-/onechar 1 string def
-/edef {exch def} def
-/WinAnsiEncoding dup /Encoding findresource def
-
-% charnumber print-charname -
-% prints the name of the encoded character
-/print-charname {
- PFMCharSet 0 eq {
- WinAnsiEncoding
- } {
- PFBencoding
- } ifelse
- exch get =string cvs dup
- (.notdef) eq {
- /was.notdef true def
- } if
- print.to.ofi ( ) print.to.ofi
-} def
-
-/printquit {print flush quit} def
-
-% redirecting GS output to ``ofi'' file
-/eolch (\r\n) def
-/=only.to.ofi {ofi exch write=only} def % replaces GS's `=only'
-/print.to.ofi {ofi exch writestring} def % replaces `print'
-/=to.ofi { =only.to.ofi eolch print.to.ofi } def % replaces `='
-
-% read and skip: byte, short, word, double and long
-/readb-p {currPFMfile read not {(Unexpected EOF\n) printquit} if} def
-/readw-p {readb-p readb-p 256 mul add} def
-/reads-p {readw-p dup 32768 ge {65536 sub} if} def
-/readd-p {readb-p readb-p readb-p readb-p 256 mul add 256 mul add 256 mul add} def
-/readl-p /readd-p load def % double word is, in fact, long integer in GS
-/skipb-p {readb-p pop} def
-/skipw-p {skipb-p skipb-p} def
-/skips-p /skipw-p load def
-/skipd-p {skipb-p skipb-p skipb-p skipb-p} def
-/skipl-p /skipd-p load def
-/skipa-p { {skipb-p} repeat} def
-
-% PFMfile readPFMheader -
-% defines currPFMfile, PFMExtMetricOffset, PFMPairKernTableOffset
-
-/readPFMheader {
- currPFMfile bytesavailable
- % ---------------
- % PFM MAIN HEADER
- % ---------------
- skipw-p % PFM: version
- readd-p % PFM: size (size is dword, not word as the documentation says)
- ne {(Wrong file size\n) printquit} if
- 60 skipa-p % PFM: copyright
- skipw-p % PFM: Type
- skipw-p % PFM: Points
- skipw-p % PFM: VertRes
- skipw-p % PFM: HorizRes
- skipw-p % PFM: Ascent
- skipw-p % PFM: InternalLeading
- skipw-p % PFM: ExternalLeading
- skipb-p % PFM: Italic
- skipb-p % PFM: Underline
- skipb-p % PFM: Stikeout
- skipw-p % PFM: Weight
- readb-p % PFM: CharSet
- /PFMCharSet edef
- skipw-p % PFM: PixWidth
- skipw-p % PFM: PixHeight
- skipb-p % PFM: PitchAndFamily
- skipw-p % PFM: AvgWidth
- skipw-p % PFM: MaxWidth
- skipb-p % PFM: FirstChar
- skipb-p % PFM: LastChar
- skipb-p % PFM: DefaultChar
- skipb-p % PFM: BreakChar
- skipw-p % PFM: WidthBytes
- skipd-p % PFM: Device
- skipd-p % PFM: Face
- skipd-p % PFM: BitsPointer
- skipd-p % PFM: BitsOffset
- % here we assume that it is a PostScript font, i.e., it always uses
- % the extended width table, therefore the normal width table is empty
- % -------------
- % PFM EXTENSION
- % -------------
- skipw-p % PFMEX: SizeFields
- readd-p % PFMEX: ExtMetricOffset
- /PFMExtMetricOffset edef
- skipd-p % PFMEX: ExtentTable
- skipd-p % PFMEX: OriginTable
- readd-p % PFMEX: PairKernTable
- /PFMPairKernTableOffset edef
- skipd-p % PFMEX: TrackKernTable
- skipd-p % PFMEX: DriverInfo
- skipd-p % PFMEX: Reserved
-} def
-
-% requires that currPFMfile, PFMExtMetricOffset are defined
-% readPFMExtMetric -
-% defines PFMNumberofKernPairs
-
-/readPFMExtMetric {
- currPFMfile PFMExtMetricOffset setfileposition
- skips-p % EXTT: Size
- skips-p % EXTT: PointSize
- skips-p % EXTT: Orientation
- skips-p % EXTT: MasterHeight
- skips-p % EXTT: MinScale
- skips-p % EXTT: MaxScale
- skips-p % EXTT: MasterUnit
- reads-p % EXTT: CapHeight
- /PFMCapHeight edef
- reads-p % EXTT: XHeight
- /PFMXHeight edef
- reads-p % EXTT: LowerCaseAscent
- /PFMLowerCaseAscent edef
- reads-p % EXTT: LowerCaseDescent
- neg /PFMLowerCaseDescent edef
- skips-p % EXTT: Slant
- skips-p % EXTT: SuperScript
- skips-p % EXTT: SubScript
- skips-p % EXTT: SuperScriptSize
- skips-p % EXTT: SubScriptSize
- skips-p % EXTT: UnderlineOffset
- skips-p % EXTT: UnderlineWidth
- skips-p % EXTT: DoubleUpperUnderlineOffset
- skips-p % EXTT: DoubleLowerUnderlineOffset
- skips-p % EXTT: DoubleUpperUnderlineWidth
- skips-p % EXTT: DoubleLowerUnderlineWidth
- skips-p % EXTT: StrikeOutOffset
- skips-p % EXTT: StrikeOutWidth
- readw-p % EXTT: KernPairs
- /PFMNumberofKernPairs edef
- skipw-p % EXTT: KernTracks
-} def
-
-% requires that currPFMfile, PFMPairKernTableOffset, PFMNumberofKernPairs are defined
-% readPFMExtMetric -
-% prints kern pairs table in the AFM format
-
-/readPFMKernPairs {
- currPFMfile () ne {
- PFMdict begin
- PFMPairKernTableOffset 0 ne {
- currPFMfile PFMPairKernTableOffset setfileposition
- readw-p % undocumented kern count (although all remaining structures are
- % explicitly preceded by their sizes); if it were a stable
- % feature, EXTTEXTMETRICS could be skipped
- PFMNumberofKernPairs
-% 2 copy = =
- ne {
- (Inconsistent number of kern pairs\n) printquit
- } if
- (StartKernData) =to.ofi
- (StartKernPairs ) print.to.ofi
- PFMNumberofKernPairs =to.ofi
- % ---------
- % MAIN LOOP
- % ---------
- /was.notdef false def
- PFMNumberofKernPairs {
- (KPX ) print.to.ofi
- readb-p % first char
- print-charname
- readb-p % second char
- print-charname
- reads-p % kern amount
- =to.ofi
- } repeat
- was.notdef {
- (.notdef character ocurred among kern pairs) =
- (you'd better check the resulting AFM file.) =
- } if
- (EndKernPairs) =to.ofi
- (EndKernData) =to.ofi
- } if
- end
- } if
-} def
-
-% alias (for ``compatibility'' with J. Clark):
-/printkernpairs /readPFMKernPairs load def
-
-% printcharmetrics -
-
-/printcharmetrics {
- (StartCharMetrics ) print.to.ofi
- /PFBencoding currfont /Encoding get dup length array copy def
- /PFBcharstrings currfont /CharStrings get def
- PFBcharstrings length
- PFBcharstrings /.notdef known { 1 sub } if =to.ofi
- currfont 1000 scalefont setfont
- % checking Encoding array and CharStrings dictionary for
- % the consistency of names
- /was.inconsitent false def
- 0 1 255 {
- dup PFBencoding exch get
- PFBcharstrings exch known {
- pop
- }{
-% dup PFBencoding exch get =
- PFBencoding exch /.notdef put % fix Encoding array
- /was.inconsitent true def
- } ifelse
- } for
- was.inconsitent {
- (Encoding array contains name(s) absent from CharStrings dictionary) =
- } if
- % print metric data for each character in PFB encoding vector
- 0 1 255 {
- dup PFBencoding exch get
- dup /.notdef ne {
- exch dup printmetric
- }{
- pop pop
- } ifelse
- } for
- % xPFBencoding contains an entry for each name in the original
- % encoding vector
- /xPFBencoding PFBcharstrings length dict def
- PFBencoding {
- xPFBencoding exch true put
- } forall
-
- /fontiter 0 def
- /TMPFontTemplate (TMP_FONT#000) def
- {
- % NewPFBencoding is the new encoding vector
- /NewPFBencoding 256 array def
- 0 1 255 {
- NewPFBencoding exch /.notdef put
- } for
- % fill up NewPFBencoding with names from CharStrings dictionary that
- % are not encoded so far
- /i 0 def
- PFBcharstrings {
- pop
- i 255 le {
- dup xPFBencoding exch known not {
- dup xPFBencoding exch true put
- NewPFBencoding i 3 -1 roll put
- /i i 1 add def
- }{
- pop
- } ifelse
- }{
- pop exit
- } ifelse
- } forall
- i 0 eq {exit} if
- % define a new font with NewPFBencoding as its encoding vector
- currfont maxlength dict /NewTMPfont edef
- currfont {
- exch dup dup /FID ne exch /Encoding ne and {
- exch NewTMPfont 3 1 roll put
- }{
- pop pop
- } ifelse
- } forall
- % compute a unique name for a font to be registered
- /fontiter fontiter 1 add def
- TMPFontTemplate fontiter (000) cvs
- dup length TMPFontTemplate length exch sub exch putinterval
- /TMPFontName TMPFontTemplate cvn def
- NewTMPfont /FontName TMPFontName put
- NewTMPfont /Encoding NewPFBencoding put
- % make this new font the current font
- TMPFontName NewTMPfont definefont 1000 scalefont setfont
- % print metric data for each character in the newly created encoding vector
- 0 1 255 {
- dup NewPFBencoding exch get
- dup /.notdef ne {
- exch -1 printmetric
- }{
- pop pop exit
- } ifelse
- } for
- i 255 lt {exit} if
- } loop
- (EndCharMetrics) =to.ofi
-} def
-
-% name actual_code normal_code printmetric -
-
-/printmetric {
- (C ) print.to.ofi =only.to.ofi
- ( ; WX ) print.to.ofi
- onechar 0 3 -1 roll put
- onechar stringwidth pop round cvi =only.to.ofi
- ( ; N ) print.to.ofi =only.to.ofi
- ( ; B ) print.to.ofi
- newpath 0 0 moveto
- onechar false charpath flattenpath pathbbox
- newpath
- round cvi /ury edef round cvi /urx edef
- round cvi /lly edef round cvi /llx edef
- ury lly eq {/ury 0 def /lly 0 def} if % normalize degenrated BB
- urx llx eq {/urx 0 def /llx 0 def} if %
- llx =only.to.ofi ( ) print.to.ofi lly =only.to.ofi ( ) print.to.ofi
- urx =only.to.ofi ( ) print.to.ofi ury =only.to.ofi ( ) print.to.ofi
- (;) =to.ofi
-} def
-
-/printinfoitem {
- 3 1 roll 2 copy known {
- get dup type /stringtype ne { =string cvs } if exch
- print.to.ofi ( ) print.to.ofi =to.ofi
- }{
- pop pop pop
- } ifelse
-} def
-
-/printfontinfo {
- (Comment AFM Generated by Ghostscript/pf2afm) =to.ofi
- currfont /FontName (FontName) printinfoitem
- %
- currfont /FontInfo get
- dup /FullName (FullName) printinfoitem
- dup /FamilyName (FamilyName) printinfoitem
- dup /Weight (Weight) printinfoitem
- dup /Notice (Notice) printinfoitem
- dup /ItalicAngle (ItalicAngle) printinfoitem
- dup /isFixedPitch (IsFixedPitch) printinfoitem
- dup /UnderlinePosition (UnderlinePosition) printinfoitem
- dup /UnderlineThickness (UnderlineThickness) printinfoitem
- /version (Version) printinfoitem
- %
- (EncodingScheme FontSpecific) =to.ofi
- %
- (FontBBox) print.to.ofi
- currfont /FontBBox get {
- ( ) print.to.ofi round cvi =only.to.ofi
- } forall
- eolch print.to.ofi
- %
- currPFMfile () ne {
- PFMdict
- dup /PFMCapHeight (CapHeight) printinfoitem
- dup /PFMXHeight (XHeight) printinfoitem
- dup /PFMLowerCaseDescent (Descender) printinfoitem
- /PFMLowerCaseAscent (Ascender) printinfoitem
- } if
-} def
-
-/readPFBfile {
- % make a shot of the actual font directory:
- /oldFontDirectory FontDirectory dup length dict copy def
- isPFB {% defined in `makeafm'
- (r) file true /PFBDecode filter cvx % true is better (see gs_type1.ps)
- mark exch exec
- }{
- (r) file mark exch run
- } ifelse
- cleartomark
- % make a shot of the updated font directory:
- /newFontDirectory FontDirectory dup length dict copy def
- % spot the added font:
- oldFontDirectory {pop newFontDirectory exch undef} forall
- newFontDirectory length 1 ne {
- newFontDirectory length =
- (Weird PFB file?\n) printquit
- } if
- newFontDirectory {pop} forall
- findfont /currfont edef
-} def
-
-/readPFMfile {
- dup () ne {
- (r) file /currPFMfile edef
- 10 dict dup /PFMdict edef begin
- readPFMheader
- readPFMExtMetric
- end
- }{
- pop /currPFMfile () def
- } ifelse
-} def
-
-% pfmfilename pf[ba]filename filetype printafm -
-% where filetype=(a) or (b)
-
-/printafm {
- readPFBfile
- readPFMfile
- (StartFontMetrics 2.0) =to.ofi
- printfontinfo
- printcharmetrics
- printkernpairs
- (EndFontMetrics) =to.ofi
-} def
-
-% pf[ba]filename makeafm -
-
-/makeafm {
- count 0 eq {(Missing font file name\n) printquit} if
- /ifn edef
- ifn length 0 eq {(Empty font file name\n) printquit} if
-% the following piece of the code does, in fact, the job of a system shell,
-% i.e., it analyses the supplied names, appends extensions if needed,
-% and check files:
- /pfbn () def /pfan () def /pfmn () def % initialisation
- ifn (.pfb) search {
- 3 -1 roll length 0 eq {% file name extension = ".pfb"
- ifn dup length string copy /pfbn edef
- /ifn edef
- }{pop} ifelse
- } if pop
- ifn (.pfa) search {
- 3 -1 roll length 0 eq {% file name extension = ".pfa"
- ifn dup length string copy /pfan edef
- /ifn edef
- }{pop} ifelse
- } if pop
- pfbn () eq pfan () eq and dup {% no extension was supplied, try ".pfb"
- /pfbn ifn (.pfb) concatstrings def
- } if
- pfbn () ne {% check whether "filename.pfb" exists
- pfbn status {pop pop pop pop /isPFB true def}{/pfbn () def} ifelse
- } if
- pfbn () eq and {% checking "filename.pfb" unsuccessful, try ".pfa"
- /pfan ifn (.pfa) concatstrings def
- } if
- pfan () ne {% check whether "filename.pfa" exists
- pfan status {pop pop pop pop /isPFB false def}{/pfan () def} ifelse
- } if
-
- pfbn () eq pfan () eq and {
- (Neither pfa nor pfb found\n) printquit
- } if
-
- /ofn ifn (.afm) concatstrings def
- ofn status {
- pop pop pop pop (Resulting file exists\n) printquit
- } if
- /ofi ofn (w) file def
-
- /pfmn ifn (.pfm) concatstrings def
- pfmn status {
- pop pop pop pop
- }{
- () pfmn {
- (/) search {
- 4 -1 roll exch concatstrings exch concatstrings exch
- }{
- exit
- } ifelse
- } loop
- (pfm/) exch concatstrings concatstrings
- dup status {
- pop pop pop pop /pfmn edef
- }{
- pop /pfmn () def (pfm file not found -- ignored\n) print
- } ifelse
- } ifelse
- //systemdict /.setsafe known {
- <<
- /PermitFileReading
- [ pfmn dup length 0 eq { pop } if
- isPFB {pfbn}{pfan} ifelse
- ]
- /PermitFileWriting [ ]
- /PermitFileControl [ ]
- >> setuserparams
- .locksafe
- } if
-
-
- pfmn
- isPFB {pfbn}{pfan} ifelse
- printafm
-
-} def
-
-% Check for command line arguments.
-[ shellarguments
- { ] dup length 1 eq {
- 0 get makeafm
- }{
- (This is PF2AFM -- AFM generator \(ver. 1.00\)\n) print
- (Usage: gs [-dNODISPLAY] -- pf2afm.ps disk_font_name\n) printquit
- } ifelse
- }
- {pop}
-ifelse
-
diff --git a/Master/tlpkg/tlgs/lib/pfbtopfa.ps b/Master/tlpkg/tlgs/lib/pfbtopfa.ps deleted file mode 100644 index 0a5caaa0f5c..00000000000 --- a/Master/tlpkg/tlgs/lib/pfbtopfa.ps +++ /dev/null @@ -1,34 +0,0 @@ -% Copyright (C) 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pfbtopfa.ps 6300 2005-12-28 19:56:24Z giles $
-% pfbtopfa.ps
-% Convert a .pfb font to .pfa format.
-
-[ shellarguments {
- counttomark 2 eq {
- /pfa exch def /pfb exch def pop
- /in1 pfb (r) file def
- /in in1 true /PFBDecode filter def
- /out pfa (w) file def
- { in read not { exit } if out exch write } loop
- out closefile in closefile in1 closefile
- quit
- } {
- cleartomark (Usage: pfbtopfa input.pfb output.pfa) = flush
- } ifelse
-} {
- pop
-} ifelse
diff --git a/Master/tlpkg/tlgs/lib/ppath.ps b/Master/tlpkg/tlgs/lib/ppath.ps deleted file mode 100644 index d621c1531c7..00000000000 --- a/Master/tlpkg/tlgs/lib/ppath.ps +++ /dev/null @@ -1,54 +0,0 @@ -% Copyright (C) 1989, 1995, 1997 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: ppath.ps 6300 2005-12-28 19:56:24Z giles $
-% Redefine pathforall for tracing.
-% Can't be used recursively.
-
-/# {( )print} def
-
-/-mat matrix def
-/-imat matrix def
-/-smat { //-mat currentmatrix pop //-imat setmatrix } bind def
-/-rmat { //-mat setmatrix } bind def
-/-pathforall /pathforall load def
-/-p2 { ( ) print exch =only ( ) print =only } bind def
-/-dp2 { 2 copy -p2 2 { exch 4096 mul dup cvi dup ( ) print =only sub dup 0 eq { pop } { (+) print =only } ifelse } repeat } bind def
-/-tp2 { //-mat itransform -p2 } bind def
-/-dict 5 dict def
-
-/pathforall
- { -dict begin
- /-close exch def /-curve exch def /-line exch def /-move exch def
- end -smat -mat ==only ( setmatrix) =
- {2 copy -tp2 ( moveto\t%)print
- 2 copy -dp2 (\n)print
- flush -dict /-move get -rmat exec -smat}
- {2 copy -tp2 ( lineto\t%)print
- 2 copy -dp2 (\n)print
- flush -dict /-line get -rmat exec -smat}
- {5 index 5 index -tp2 3 index 3 index -tp2 2 copy -tp2 ( curveto\t%)print
- 5 index 5 index -dp2 3 index 3 index -dp2 2 copy -dp2 (\n)print
- flush -dict /-curve get -rmat exec -smat}
- {(closepath\n)print flush -dict /-close get -rmat exec -smat}
- -pathforall -rmat
- }
-def
-
-% Just print the current path
-
-/printpath {
- {pop pop} {pop pop} {pop pop pop pop pop pop} {} pathforall
-} def
diff --git a/Master/tlpkg/tlgs/lib/pphs.ps b/Master/tlpkg/tlgs/lib/pphs.ps deleted file mode 100644 index 2d97c224ff1..00000000000 --- a/Master/tlpkg/tlgs/lib/pphs.ps +++ /dev/null @@ -1,221 +0,0 @@ -% Copyright (C) 2001 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: pphs.ps 6300 2005-12-28 19:56:24Z giles $
-% Print Linearized PDF hint streams
-
-% Utilities
-/read1 { % <file> read1 <value>
- read not {
- (**** Unexpected EOF) = flush quit
- } if
-} bind def
-/read2 { % <file> read2 <value>
- dup read1 8 bitshift exch read1 add
-} bind def
-/read4 { % <file> read4 <value>
- dup read2 16 bitshift exch read2 add
-} bind def
-% Free variables: Bits, Bitsleft
-/readninit { % - <readninit> -
- /Bits 0 def
- /Bitsleft 0 def
-} bind def
-
-/pdftoken { % <file> pdftoken <token>
- dup token pop
- dup type /nametype eq 1 index xcheck and {
- dup dup (<<) cvn eq exch ([) eq or {
- exec exch {
- dup pdftoken dup dup (>>) cvn eq exch (]) eq or {
- exch pop exec exit
- } if exch
- } loop
- } {
- exch pop
- } ifelse
- } {
- exch pop
- } ifelse
-} bind def
-/makemask { % <nbits> makemask <mask>
- 1 exch bitshift 1 sub
-} bind def
-/readn { % <file> <nbits> readn <value>
- dup Bitsleft le {
- exch pop
- /Bitsleft Bitsleft 2 index sub def
- makemask Bits Bitsleft neg bitshift and
- } {
- Bitsleft makemask Bits and
- exch Bitsleft sub exch 1 index bitshift 3 1 roll
- /Bits 2 index read1 def /Bitsleft 8 def
- readn add
- } ifelse
-} bind def
-/sread { % <string> sread <file>
- 0 () /SubFileDecode filter
-} bind def
-
-/ptag { % <pre-tag> <proc> <post-tag> ptag -
- 3 -1 roll print (: ) print
- exch exec
- ( % ) print =
-} bind def
-
-% Print the linearization parameters dictionary.
-/plpkeys <<
- /E (end of p. 1 objects)
- /L (total file length)
- /H (PHS start + length)
- /N (# of pages)
- /O (p. 1 object #)
- /T (offset of first main xref entry)
->> def
-/plpdict { % <dict> plpdict -
- (<<) = plpkeys {
- 2 index 2 index .knownget {
- % Stack: dict key label value
- ( ) print 3 -1 roll ===only ( ) print ===only
- ( % ) print =
- } {
- pop pop
- } ifelse
- } forall {
- plpkeys 2 index known {
- pop pop
- } {
- ( ) print exch ===only ( ) print ===
- } ifelse
- } forall (>>) =
-} bind def
-
-% Print the Page Offset Hint Table.
-/ppoht { % <npages> <file> ppoht -
-
- 20 dict begin
- /f exch def
- /npages exch def
- readninit
-
- (1) { f read4 =only } (least # objs/page) ptag
- (2) { f read4 =only } (offset of p. 1 object (+PHS length if beyond PHS)) ptag
- (3) { f read2 dup =only /nb3 exch def } (# bits for # objs/page delta) ptag
- (4) { f read4 =only } (least # bytes/page) ptag
- (5) { f read2 dup =only /nb5 exch def } (# bits for # bytes/page delta) ptag
- (6) { f read4 =only } (least content stream offset-in-page) ptag
- (7) { f read2 dup =only /nb7 exch def } (# bits for content stream offset delta) ptag
- (8) { f read4 =only } (least content stream length) ptag
- (9) { f read2 dup =only /nb9 exch def } (# bits for content stream length delta) ptag
- (10) { f read2 dup =only /nb10 exch def } (# bits for # of shared obj refs) ptag
- (11) { f read2 dup =only /nb11 exch def } (# bits for shared obj indices) ptag
- (12) { f read2 dup =only /nb12 exch def } (# bits for shared obj ref pos numerators) ptag
- (13) { f read2 =only } (shared obj ref pos denominator) ptag
-
- (*1) { [ npages { f nb3 readn } repeat ] ==only } (# objs/page deltas (see 1,3)) ptag
- (*2) { [ npages { f nb5 readn } repeat ] ==only } (# bytes/page deltas (see 4,5)) ptag
- (*3) { [ npages { f nb10 readn } repeat ] dup ==only /nso exch def } (# of shared obj refs (see 10)) ptag
- (*4) { [ nso { [ exch { f nb11 readn } repeat ] } forall ] ==only } (shared obj indices (see 11)) ptag
- (*5) { [ nso { [ exch { f nb12 readn } repeat ] } forall ] ==only } (shared obj ref pos numerators (see 12)) ptag
- (*6) { [ npages { f nb7 readn } repeat ] ==only } (content stream offset-in-page deltas (see 6,7)) ptag
- (*7) { [ npages { f nb9 readn } repeat ] ==only } (content stream length deltas (see 8,9)) ptag
-
- end % temp dict
-
-} bind def
-
-% Print the Shared Objects Hint Table.
-/psoht { % <file> psoht -
-
- 20 dict begin
- /f exch def
- readninit
-
- (1) { f read4 =only } (first shared obj #) ptag
- (2) { f read4 =only } (first shared obj offset (+PHS length if beyond PHS)) ptag
- (3) { f read4 dup =only /n3 exch def } (# of p. 1 shared objs) ptag
- (4) { f read4 dup =only /n4 exch def } (total # of shared objs) ptag
- (5) { f read2 dup =only /nb5 exch def } (# bits for # of shared objs/group) ptag
- (6) { f read4 =only } (least shared obj group length) ptag
- (7) { f read2 dup =only /nb7 exch def } (# bits for shared obj group length delta) ptag
-
- /nse n4 def
- (*1) { [ nse { f nb7 readn } repeat ] ==only } (shared obj group length deltas (see 6,7)) ptag
- (*2) { [ nse { f 1 readn } repeat ] dup ==only /md5s exch def } (MD5 present?) ptag
- (*3:) = md5s {
- 0 ne {
- ( ) print f 16 string readstring pop
- (%stdout) (w) file dup 3 -1 roll writehexstring closefile () =
- } if
- } forall
- (*4) { [ nse { f nb5 readn } repeat ] ==only } (# objs/group (see 5)) ptag
-
- end % temp dict
-
-} bind def
-
-% Print the Primary Hint Stream of a PDF file.
-/pphs { % <file> pphs -
- /pdf exch def
-
- % Read the linearization parameter dictionary.
- { pdf pdftoken /obj eq { exit } if } loop
- pdf pdftoken /lpdict exch def
- /lpdict type /dicttype eq { lpdict /Linearized known } { false } ifelse {
- (Not a linearized PDF file.) = stop
- } if
-
- lpdict plpdict flush
-
- % Read the primary hint stream.
- null {
- pdf pdftoken dup /stream eq { pop exit } if
- exch pop
- } loop
- /phsdict exch def
- % Remove Length if indirect reference.
- phsdict 0 known {
- phsdict 0 undef phsdict /Length undef
- } if
- (PHS: ) print phsdict === flush
- pdf 0 (endstream) /SubFileDecode filter
- dup 64000 string readstring pop exch closefile
- sread /phsdata exch def
-
- % Decode the hint stream data if necessary.
- phsdict /Filter .knownget {
- phsdata exch filter
- dup 5000 string readstring pop exch closefile
- sread /phsdata exch def
- } if
-
- % Adobe says we can assume /P = 0.
- (Page Offset Hint Table:) =
- lpdict /N get
- phsdata phsdict /S get string readstring pop sread
- ppoht
- (Shared Objects Hint Table:) =
- phsdata psoht
-} bind def
-
-% Check for command line arguments.
-[ shellarguments
- { ] dup length 1 eq
- { 0 get (r) file dup pphs closefile }
- { (Usage: pphs filename.pdf\n) print flush }
- ifelse
- }
- { pop }
-ifelse
diff --git a/Master/tlpkg/tlgs/lib/prfont.ps b/Master/tlpkg/tlgs/lib/prfont.ps deleted file mode 100644 index 3afefca1f7d..00000000000 --- a/Master/tlpkg/tlgs/lib/prfont.ps +++ /dev/null @@ -1,248 +0,0 @@ -%!
-%%Creator: Eric Gisin <egisin@waterloo.csnet>
-%%Title: Print font catalog
-% Copyright (c) 1986 Eric Gisin
-% Copyright (C) 1992 Aladdin Enterprises, Menlo Park, CA
-% Modified to print all 256 encoded characters.
-% Copyright (C) 1993 Aladdin Enterprises, Menlo Park, CA
-% Modified to print unencoded characters.
-% Copyright (C) 1994 Aladdin Enterprises, Menlo Park, CA
-% Modified to always create 256-element Encoding vectors.
-% Copyright (C) 1995 Aladdin Enterprises, Menlo Park, CA
-% Modified to print more than 128 unencoded characters.
-% Copyright (C) 1996 Aladdin Enterprises, Menlo Park, CA
-% Modified to leave a slightly wider left margin, because many H-P
-% printers can't print in the leftmost 1/4" of the page.
-% Modified to print unencoded characters in any font that has CharStrings.
-% Copyright (C) 1999 Aladdin Enterprises, Menlo Park, CA
-% Modified to sort unencoded characters.
-% Copyright (C) 2000 Aladdin Enterprises, Menlo Park, CA
-% Modified to print CIDFonts as well as fonts.
-% O(N^2) sorting replaced with O(N log N).
-% Copyright transferred 2000/09/15 to Artifex Software, Inc. Send any questions to
-% bug-gs@ghostscript.com.
-
-% $Id: prfont.ps 8022 2007-06-05 22:23:38Z giles $
-
-% Example usages at bottom of file
-
-/#copies 1 def
-/min { 2 copy gt { exch } if pop } bind def
-
-/T6 /Times-Roman findfont 6 scalefont def
-/Temp 64 string def
-/Inch {72 mul} def
-/Base 16 def % char code output base
-/TempEncoding [ 256 { /.notdef } repeat ] def
-
-% Sort an array. Code used by permission of the author, Aladdin Enterprises.
-/sort { % <array> <lt-proc> sort <array>
- % Heapsort (algorithm 5.2.3H, Knuth vol. 2, p. 146),
- % modified for 0-origin indexing. */
- 10 dict begin
- /LT exch def
- /recs exch def
- /N recs length def
- N 1 gt {
- /l N 2 idiv def
- /r N 1 sub def {
- l 0 gt {
- /l l 1 sub def
- /R recs l get def
- } {
- /R recs r get def
- recs r recs 0 get put
- /r r 1 sub def
- r 0 eq { recs 0 R put exit } if
- } ifelse
- /j l def {
- /i j def
- /j j dup add 1 add def
- j r lt {
- recs j get recs j 1 add get LT { /j j 1 add def } if
- } if
- j r gt { recs i R put exit } if
- R recs j get LT not { recs i R put exit } if
- recs i recs j get put
- } loop
- } loop
- } if recs end
-} def
-
-% do single character of page
-% output to rectangle ll=(0,-24) ur=(36,24)
-/DoGlyph { % C, N, W set
-
- % print code name, width and char name
- T6 setfont
- N /.notdef ne {0 -20 moveto N Temp cvs show} if
- 0 -12 moveto C Base Temp cvrs show ( ) show
- W 0.0005 add Temp cvs 0 5 getinterval show
-
- % print char with reference lines
- N /.notdef ne {
- 3 0 translate
- 0 0 moveto F24 setfont N glyphshow
- /W W 24 mul def
- 0 -6 moveto 0 24 lineto
- W -6 moveto W 24 lineto
- -3 0 moveto W 3 add 0 lineto
- 0 setlinewidth stroke
- } if
-} def
-/DoChar {
- /C exch def
- /N F /Encoding get C get def
- /S (_) dup 0 C put def
- /W F setfont S stringwidth pop def
- DoGlyph
-} def
-/CIDTemp 20 string def
-/DoCID {
- /N exch def
- /C N def
- /W F setfont gsave
- matrix currentmatrix nulldevice setmatrix
- 0 0 moveto N glyphshow currentpoint pop
- grestore def
- DoGlyph
-} def
-
-% print page title
-/DoTitle {
- /Times-Roman findfont 18 scalefont setfont
- 36 10.5 Inch moveto FName Temp cvs show ( ) show ((24 point)) show
-} def
-
-% print one block of characters
-/DoBlock { % firstcode lastcode
- /FirstCode 2 index def
- 1 exch {
- /I exch def
- /Xn I FirstCode sub 16 mod def /Yn I FirstCode sub 16 idiv def
- gsave
- Xn 35 mul 24 add Yn -56 mul 9.5 Inch add translate
- I DoCode
- grestore
- } for
-} def
-
-% print a line of character
-/DoCharLine { % firstcode lastcode
- 1 exch { (_) dup 0 3 index put show pop } for
-} def
-/DoCIDLine { % firstcode lastcode
- 1 exch { glyphshow } for
-} def
-
-% initialize variables
-/InitDoFont { % fontname font
- /F exch def % font
- /FName exch def % font name
- /F24 F 24 scalefont def
- /Line0 96 string def
- /Line1 96 string def
- /Namestring1 128 string def
- /Namestring2 128 string def
-} def
-
-% print pages of unencoded characters
-/DoUnencoded { % glyphs
- /Unencoded exch def
- /Count Unencoded length def
-
- % Print the unencoded characters in blocks of 128.
-
- 0 128 Unencoded length 1 sub
- { /BlockStart 1 index def
- dup 128 add Unencoded length .min 1 index sub
- Unencoded 3 1 roll getinterval TempEncoding copy
- /BlockEncoding exch def
- /BlockCount BlockEncoding length def
- save
- F /Encoding known {
- F length dict F
- { 1 index /FID eq { pop pop } { 2 index 3 1 roll put } ifelse }
- forall dup /Encoding TempEncoding put
- /* exch definefont
- /F exch def
- /F24 F 24 scalefont def
- /BlockStart 0 def
- } if
-
- DoTitle (, unencoded characters) show
- BlockStart dup BlockCount 1 sub add DoBlock
- F 10 scalefont setfont
- 36 2.4 Inch moveto
- 0 32 BlockCount 1 sub {
- 0 -0.4 Inch rmoveto gsave
- dup 31 add BlockCount 1 sub .min
- exch BlockStart add exch BlockStart add DoLine
- grestore
- } for
- showpage
- restore
- } for
-
-} def
-
-% print font sample pages
-/DoFont {
- dup findfont InitDoFont
- /DoCode {DoChar} def
- /DoLine {DoCharLine} def
-
- % Display the first 128 encoded characters.
-
- DoTitle (, characters 0-127) show
- 0 127 DoBlock
- F 10 scalefont setfont
- 36 2.0 Inch moveto 0 31 DoLine
- 36 1.6 Inch moveto 32 63 DoLine
- 36 1.2 Inch moveto 64 95 DoLine
- 36 0.8 Inch moveto 96 127 DoLine
- showpage
-
- % Display the second 128 encoded characters.
-
- DoTitle (, characters 128-255) show
- 128 255 DoBlock
- F 10 scalefont setfont
- 36 2.0 Inch moveto 128 159 DoLine
- 36 1.6 Inch moveto 160 191 DoLine
- 36 1.2 Inch moveto 192 223 DoLine
- 36 0.8 Inch moveto 224 255 DoLine
- showpage
-
- F /CharStrings known
- {
- % Find and display the unencoded characters.
-
- /Encoded F /Encoding get length dict def
- F /Encoding get { true Encoded 3 1 roll put } forall
- [ F /CharStrings get
- { pop dup Encoded exch known { pop } if }
- forall ] {
- exch Namestring1 cvs exch Namestring2 cvs lt
- } sort DoUnencoded
-
- }
- if
-
-} def
-
-% print CIDFont sample pages
-/DoCIDFont {
- dup /CIDFont findresource InitDoFont
- /DoCode {DoCID} def
- /DoLine {DoCIDLine} def
-
- [ 0 1 F /CIDCount get 1 sub { } for ] DoUnencoded
-} def
-
-% Do font samples
-% /Times-Roman DoFont % Test (less than a minute)
-% /Hershey-Gothic-English DoFont % Test (8 minutes)
-
-% Do a complete catalog
-% FontDirectory {pop DoFont} forall % All fonts (quite a long time)
diff --git a/Master/tlpkg/tlgs/lib/printafm.ps b/Master/tlpkg/tlgs/lib/printafm.ps deleted file mode 100644 index 66ac708b8cc..00000000000 --- a/Master/tlpkg/tlgs/lib/printafm.ps +++ /dev/null @@ -1,165 +0,0 @@ -%!
-% written by James Clark <jjc@jclark.uucp>
-% print an afm file on the standard output
-% usage is `fontname printafm' eg `/Times-Roman printafm'
-
-% From the `dvitops' distribution, which included this notice:
-% dvitops is not copyrighted; you can do with it exactly as you please.
-% I would, however, ask that if you make improvements or modifications,
-% you ask me before distributing them to others.
-
-% Altered by d.love@dl.ac.uk to produce input for Rokicki's afm2tfm,
-% which groks the format of the Adobe AFMs.
-
-% $Id: printafm.ps 6677 2006-03-22 18:10:43Z giles $
-% Modified by L. Peter Deutsch 9/14/93:
-% uses Ghostscript's =only procedure to replace 'buf cvs print'.
-% Modified by L. Peter Deutsch 9/6/95:
-% uses Ghostscript's shellarguments facility to accept the font name
-% on the command line.
-
-% Altered my master@iaas.msu.ru to work with fonts of more than 256 glyphs
-% and avoid FSType output
-
-/onechar 1 string def
-
-% c toupper - c
-/toupper {
- dup dup 8#141 ge exch 8#172 le and {
- 8#40 sub
- } if
-} bind def
-
-% print unencoded character metric data lines for glyphs in `v' array
-% and reset `v' -
-/printv {
- % define a new font with v as its encoding vector
- currentfont maxlength dict /f exch def
- currentfont {
- exch dup dup /FID ne exch /Encoding ne and {
- exch f 3 1 roll put
- } {
- pop pop
- } ifelse
- } forall
- f /Encoding v put
- f /FontName /temp put
- % make this new font the current font
- /temp f definefont setfont
- % print a entry for each character not in old vector
- /e currentfont /Encoding get def
- 0 1 255 {
- dup e exch get
- dup dup /.notdef ne exch s exch known not and {
- exch -1 printmetric
- } {
- pop pop
- } ifelse
- } for
- 0 1 255 {
- v exch /.notdef put
- } for
-} bind def
-
-% printcharmetrics -
-
-/printcharmetrics {
- (StartCharMetrics ) print
- currentfont /CharStrings get dup length exch /.notdef known { 1 sub } if =
- currentfont 1000 scalefont setfont 0 0 moveto
- /e currentfont /Encoding get def
- 0 1 255 {
- dup e exch get
- dup /.notdef ne {
- exch dup printmetric
- } {
- pop pop
- } ifelse
- } for
- % s contains an entry for each name in the original encoding vector
- /s 256 dict def
- e {
- s exch true put
- } forall
- % v is the new encoding vector
- /v 256 array def
- 0 1 255 {
- v exch /.notdef put
- } for
- % fill up v with names in CharStrings
- /i 0 def
- currentfont /CharStrings get {
- pop
- i 255 le {
- v i 3 -1 roll put
- /i i 1 add def
- } {
- printv
- v 0 3 -1 roll put
- /i 1 def
- } ifelse
- } forall
- printv
- (EndCharMetrics) =
-} bind def
-
-% name actual_code normal_code printmetric -
-
-/printmetric {
- /saved save def
- (C ) print =only
- ( ; WX ) print
- onechar 0 3 -1 roll put
- onechar stringwidth pop round cvi =only
- ( ; N ) print =only
- ( ; B ) print
- onechar false charpath flattenpath mark pathbbox counttomark {
- counttomark -1 roll
- round cvi =only
- ( ) print
- } repeat pop
- (;) =
- saved restore
-} bind def
-
-% fontname printafm -
-
-/printafm {
- findfont gsave setfont
- (StartFontMetrics 2.0) =
- (FontName ) print currentfont /FontName get =
-
- % Print the FontInfo
-
- currentfont /FontInfo get {
- exch
- dup /FSType ne {
- =string cvs dup dup 0 get 0 exch toupper put print
- ( ) print =
- } {
- pop pop
- } ifelse
- } forall
-
- % Print the FontBBox
-
- (FontBBox) print
- currentfont /FontBBox get {
- ( ) print round cvi =only
- } forall
- (\n) print
-
- printcharmetrics
- (EndFontMetrics) =
- grestore
-} bind def
-
-% Check for command line arguments.
-[ shellarguments
- { ] dup length 1 eq
- { 0 get printafm }
- { (Usage: printafm fontname\n) print flush }
- ifelse
- }
- { pop }
-ifelse
diff --git a/Master/tlpkg/tlgs/lib/ps2ai.ps b/Master/tlpkg/tlgs/lib/ps2ai.ps deleted file mode 100644 index 8f0a3ab7c7b..00000000000 --- a/Master/tlpkg/tlgs/lib/ps2ai.ps +++ /dev/null @@ -1,551 +0,0 @@ -%!
-% Copyright (C) 1994 , 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: ps2ai.ps 6300 2005-12-28 19:56:24Z giles $
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-%
-% ps2ai.ps - a postscript to editable adobe illustrator file filter
-%
-/vers {2.14} def % January 31, 1999
-
-% conditional def ( if the key is already defined before, don't
-% redefine it. This can be used by other programs to overwrite
-% some settings from externally
-%
-/cdef { 1 index where { pop pop pop } { def } ifelse } def
-%
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-%
-% needs a postscript level 2 interpreter, like gnu ghostscript, to work
-%
-% Usage: gs -q -dNODISPLAY ps2ai.ps file.ps > file.aips
-% or (see below)
-% gs -q -dNODISPLAY ps2ai.ps file.ps
-% or
-% cat ps2ai.ps file.ps | lpr (then look in log file)
-%
-% or from within gsview via:
-% Edit->Convert to vector format
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-% Options
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-% Output Options: directly to a file or standard out
-%
-/jout false cdef % true=file false=stdout (default=false)
-/joutput (ps2ai.out.aips) cdef % Name of Output file
-%
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-%
-% Other Options
-%
-/jtxt3 true cdef % output text in AI3 form (false=ai88)
- % for coreldraw/photoshop readable output
-/joutln false cdef % use font outline instead of font
-/jerr false def % use error handling (ie die gracefully)
-/jbiterr false def % attempt to handle bitmap fonts (kludge)
-/jMacGS false def % true if using MacGS (not fully implemented yet)
-/jMacfix true def % convert filled boxes to lines (only usefull with
- % laserwriter 8 postscript input)
-
-%
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-% No options below here
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-%
-% - Notes -
-% ai uses cmykcolor, so level 1 interpreters don't work
-% ai doesn't use image/imagemask - so bitmaps don't work correctly
-% the output file has a header so it is viewable/printable/reconvertable
-%
-% Comments, suggestions, bug-fixes, etc send to:
-%
-% Jason Olszewski (olszewsk@splash.princeton.edu)
-%
-% anonymous ftp: toby.princeton.edu /pub/olszewsk/ps2ai.ps
-% URL ftp://toby.princeton.edu/pub/olszewsk
-%
-% - Fix History -
-% 2.14 added cdef to allow overwriting of certain values from externally
-% 2.13 check for bitmap fonts, work better with TeX,WinPS,etc
-% 2.12 fixed initclip to US letter size page
-% 2.11 added header support for *u/*U compound paths
-% 2.1 option of font outline instead of text(gwhite@trevnx.bio.dfo.ca)
-% 2.0 major change to complex path handling
-% 1.9 fixed text leaking ascii (,),\
-% 1.85 added default font to handle no setfont (Courier)
-% 1.84 added even-odd fill/clip (D)
-% 1.83 undefined PPD PageSize printer specific info
-% 1.82 added kludge to save clipping status through a restore
-% 1.81 added custom color/gray support to header (x/X, g/G)
-% 1.8 added newpath if clippath is not consumed correctly(amiga)
-% 1.79 eliminated scientific notation of numbers less than 0.0001
-% 1.78 fixed transposed h & H
-% 1.77 made laserwriter 8 fixes optional
-% 1.76 added margin fix for unix AI (brown@wi.extrel.com)
-% 1.75 added kludge to handle bitmap font errors (TeX, Windows.ps)
-% 1.74 made grestore a little smarter
-% 1.73 included header handle encoded fontname (/_fontname)
-% 1.72 fixed problem with restore/clip info - (not enough Qs problem)
-% 1.71 filter font names to remove previous encoding (|,_,etc)
-% 1.7 change text format to AI3, works better with PS & CD
-% 1.67 deal with weird makefonts
-% 1.66 handle to many bad stroke/fills (s s s w/o paths)
-% 1.65 more useable with non-gs interpreters (defaultmatrix fix)
-% 1.64 fixed "smart grestore" repeat bug
-% 1.63 fixed ashow/awidthshow bug
-% 1.62 check if cmykcolor is understood otherwise rgb
-% 1.61 made grestore smarter (only print if different)
-% 1.6 add better compatibility to CorelDraw and PhotoShop
-% 1.53 make it more gs-backward compatible (clarke@lsl.co.uk)
-% 1.52 handle clipping paths a little better (Posted)
-% 1.51 improve mac lw8 output (lines instead of filled boxes)
-% 1.5 handle some level 2 stuff (mac lw8)
-% 1.4 fixed scaling of linewidth and dash
-% 1.31 made trailer more AI88 friendly
-% 1.3 add ablity to output to file directly
-% 1.21 print matrix cleaner
-% 1.2 fix rotated fonts, thanks to G.Cameron (g.cameron@biomed.abdn.ac.uk)
-% 1.1 fix stroke/fill color difference (k vs K)
-% 1.0 posted to comp.lang.postscript
-%
-% - To Do List -
-% find real %%BoundingBox: llx lly urx ury
-% make MacGS friendly (line-endings)
-% handle eps w/o showpage:(append to end)
-% write out image data to external file
-%
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-% Nothing of Interest below here
-%xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-matrix identmatrix setmatrix % make ctm [1 0 0 1 0 0]
-/oldgsave {} def /oldgrestore {} def
-/initgraphics {} def /initmatrix {} def
-% undefine PPD PageSizes to be more printer independant
-/letter {} def /legal {} def /a4 {} def /b5 {} def /lettersmall {} def
-/setpagedevice { pop } def % for level 2 PPD PageSizes
-/Courier findfont 12 scalefont setfont % handle no setfont
-/initclip {0 0 moveto 0 792 lineto 612 792 lineto 612 0 lineto closepath
- clip newpath } def
-/xdef {exch def} def
-/trx {transform exch} def
-/cbdef {cvx bind def} def
-/jltz {dup abs 0.0001 lt {pop 0} if} def % get rid of scientific notation bug
-/clstate false def % closepath state
-/dpth false def % destroy path (ie newpath)
-/fclp false def % first paint after clip
-/kscl {1.0} def % default current scale X-factor
-/gcnt {1} def % graphics state counter
-/spth {1} def % multiple paths on stack
-/jeol (\n) def % default end-of-line
-/jnump {0} def % number of paths on stack
-/jx {0} def /jy {0} def /j_ax {0} def
-/j3ftxt true def
-/clarry 10 array def
-0 1 9 {clarry exch false put} for % initilize no clipping path
-%
-% handle cmyk color on level 1 interpreters
-/setcmykcolor where {pop}
- {/setcmykcolor {
- /blk exch def /yel exch def /mag exch def /cyan exch def
- /ccomp {add dup 1 gt {pop 1} if} def
- /red {1 cyan blk ccomp sub} def
- /green {1 mag blk ccomp sub} def
- /blue {1 yel blk ccomp sub} def
- red green blue setrgbcolor
- } def
-} ifelse
-/currentcmykcolor where {pop}
- {/currentcmykcolor {
- currentrgbcolor /bval xdef /gval xdef /rval xdef
- /rawC 1 rval sub def /rawM 1 gval sub def /rawY 1 bval sub def
- rawC rawM ge { rawY rawM ge { /blk rawM def} if } if
- rawC rawY ge { rawM rawY ge { /blk rawY def} if } if
- rawY rawC ge { rawM rawC ge { /blk rawC def} if } if
- rawY rawC eq { rawM rawC eq { /blk rawC def} if } if
- /cyan rawC blk sub def
- /mag rawM blk sub def
- /yel rawY blk sub def
- /blk blk def
- cyan mag yel blk
- } def
-} ifelse
-% If using Mac Ghostscript
-jMacGS {
-% /jeol {(\r) jp} def
- /jout true def
- (%%Note: Loading ps2ai.ps\n) print
- } if
-/jstr 40 string def
-jout {joutput (w) file /joutput xdef} if
-%
-% Output
-%
-jout {/jp { joutput exch writestring } bind def }{/jp {print}bind def} ifelse
-/jpnum {jltz ( ) jp =string cvs jp } bind def
-/jpmat { dup /jarry exch def length 1 sub /j_num exch def
- (\[) jp 0 1 j_num {jarry exch get jpnum} for (\]) jp } def
-%
-% Stack to Paths converters
-%
-/ckpnt { % check which paint and clipping to use
- dpth { % if there are multiple paths on the stack
- clarry gcnt get fclp and {clstate {(h W\n) jp }{(H W\n) jp } ifelse} if
- spth 0 eq {clstate {(n\n) jp }{(N\n) jp } ifelse} if
- spth 1 eq {clstate {(s\n) jp }{(S\n) jp } ifelse} if
- spth 2 eq {clstate {(f\n) jp }{(F\n) jp } ifelse} if
- } if
-} def
-/jpm {
- ckpnt
- /dpth true def
- transform 2 copy /yst xdef /xst xdef exch jpnum jpnum ( m\n) jp } bind def
-/jpl { trx jpnum jpnum ( l\n) jp } bind def
-/jpc { 6 4 roll trx jpnum jpnum 4 2 roll trx jpnum jpnum trx
- jpnum jpnum ( c\n) jp } bind def
-/jpp {xst jpnum yst jpnum ( l\n) jp /clstate true def} def
-/cntpaths { % count paths on stack
- oldgsave
- {pop pop /jnump jnump 1 add def} {pop pop} {6 {pop} repeat}{} pathforall
- oldgrestore
-} def
-/ppforall {
- cntpaths % find out how many paths are on the stack
- jnump 1 gt { (*u\n) jp } if
- {jpm}{jpl}{jpc}{jpp} pathforall
- ckpnt
- jnump 1 gt { (*U\n) jp } if
- /jnump 0 def /clstate false def /dpth false def /fclp false def
- oldnewpath
-} bind def
-%
-% Painting Operators
-%
-/oldnewpath [/newpath load] cbdef
-/newpath { (\n) jp /spth 0 def ppforall} def
-/stroke { (\n) jp /spth 1 def ppforall } def
-/fill {(\n) jp /spth 2 def ppforall } def
-/eofill {(1 D\n) jp fill (0 D\n) jp} def
-/clip {clarry gcnt get {(Q\nq\n) jp}{(q\n) jp} ifelse
- /fclp true def clarry gcnt true put} def
-/eoclip {(1 D\n) jp clip (0 D\n) jp} def
-%
-% Text Operators
-%
-/oldshow [/show load] cbdef
-/curpt {stringwidth pop jx add jy} def
-/jNN {dup 0 eq {pop oldgsave currentfont /FontMatrix get setmatrix kscl
- oldgrestore} if
-} def
-/curftmatrix {
- currentfont /FontMatrix get dup 0 get jNN abs /norm exch def
- dup 0 get norm div exch dup
- 1 get norm div exch dup 2 get norm div exch dup 3 get norm div exch dup
- 4 get exch 5 get 6 array astore matrix currentmatrix matrix concatmatrix
-} def
-% AI does not support negitive font sizes
-/curftsize {currentfont /FontMatrix get 0 get jNN abs 1000 mul} def
-/hstr (X) def
-/vbar (|) 0 get def /undsc (_) 0 get def
-/ftnamefix { % handle font names with |,_ (previously encoded)
-jstr cvs
-{ %forall
- dup vbar eq {pop}{ %ifelse
- dup undsc eq {pop}{ %ifelse
- hstr exch 0 exch put hstr jp
- } ifelse
- } ifelse
- } forall flush
-} bind def
-%/curftname {currentfont /FontName get ftnamefix}def
-/curftname { currentfont /FontName known {currentfont /FontName get}
- { (Times-Roman)} ifelse ftnamefix } def
-/lftpar (\() 0 get def
-/rhtpar (\)) 0 get def
-/bckslsh (\\) 0 get def
-/handft { % handle strings with (,),\
- (\() jp
- { %forall
- dup lftpar eq { (\\\() jp }{ %ifelse
- dup rhtpar eq { (\\\)) jp }{ %ifelse
- dup bckslsh eq { (\\\\) jp }{ %ifelse
- hstr exch 0 exch put hstr jp
- } ifelse
- } ifelse
- } ifelse
- } forall (\)) jp flush
-} bind def
-% AI 3 text format pieces
-jtxt3 {
-/j3txt { j3ftxt {(0 Ts 100 Tz 0 Tt 0 TA 0 0 5 TC 100 100 200 TW 0 0 0 Ti\n) jp
- (0 Ta 0 Tq 0 0 TI 0 Tc 0 Tw\n) jp} if } def
-/show {oldgsave (0 To\n) jp
- currentpoint 2 copy /jy exch def /jx exch def translate
- curftmatrix /jitm exch def
- 0 1 5 {jitm exch get jpnum} for ( 0 Tp\n) jp (TP\n) jp
- (0 Tr\n) jp (\/_) jp curftname curftsize jpnum ( Tf\n) jp
- (0) jp j_ax curftsize div 100 mul jpnum ( 100 TC\n) jp % percent(?)
- dup curpt moveto mark exch handft ( Tx\n) jp (TO\n) jp /j3ftxt false def
- cleartomark currentpoint oldgrestore moveto
-} def
-/ashow {exch pop exch /j_ax exch def show /j_ax {0} def } def
-}
- {
-/show {oldgsave (u\n) jp currentpoint 2 copy /jy exch def /jx exch def translate
- (\/) jp curftname jstr cvs jp
- curftsize dup jpnum jpnum ( 0 0 z\n) jp
- curftmatrix jpmat ( e\n) jp
- dup curpt moveto mark exch handft ( t T U\n) jp
- cleartomark currentpoint oldgrestore moveto} def
-/ashow {oldgsave (u\n) jp currentpoint translate (\/) jp curftname jstr cvs jp
- curftsize dup jpnum jpnum exch kscl mul jpnum ( 0 z\n) jp
- curftmatrix jpmat ( e\n) jp dup curpt moveto mark exch handft
- ( t T U\n) jp cleartomark currentpoint oldgrestore moveto} def
-} ifelse
-/widthshow { show pop pop pop} def
-/awidthshow {ashow pop pop pop} def
-/kshow {show pop} def
-%/show {true charpath fill} bind def % get outline of charactor
-joutln {/show { true charpath currentpoint
- /jy exch def /jx exch def fill jx jy moveto} bind def} if
-%/show {oldshow} def % do nothing different
-%
-% Color Operators
-%
-/oldsetcmykcolor [/setcmykcolor load] cbdef
-/setcmykcolor {oldsetcmykcolor
-currentcmykcolor 4 -1 roll jpnum 3 -1 roll jpnum 2 -1 roll jpnum jpnum ( k\n) jp
-currentcmykcolor 4 -1 roll jpnum 3 -1 roll jpnum 2 -1 roll jpnum jpnum ( K\n) jp
- } def
-/oldsetgray [/setgray load] cbdef
-/setgray {0 0 0 4 -1 roll 1 exch sub setcmykcolor} def
-/oldsethsbcolor [/sethsbcolor load] cbdef
-/sethsbcolor {oldsethsbcolor currentcmykcolor setcmykcolor} def
-/oldsetrgbcolor [/setrgbcolor load] cbdef
-/setrgbcolor {oldsetrgbcolor currentrgbcolor /bval xdef /gval xdef /rval xdef
- /rawC 1 rval sub def /rawM 1 gval sub def /rawY 1 bval sub def
- rawC rawM ge { rawY rawM ge { /blk rawM def} if } if
- rawC rawY ge { rawM rawY ge { /blk rawY def} if } if
- rawY rawC ge { rawM rawC ge { /blk rawC def} if } if
- rawY rawC eq { rawM rawC eq { /blk rawC def} if } if
- /cyan rawC blk sub def
- /mag rawM blk sub def
- /yel rawY blk sub def
- /blk blk def
- cyan mag yel blk setcmykcolor } def
-%
-% State Operators
-%
-/oldsetlinewidth [/setlinewidth load] cbdef
-/setlinewidth {kscl abs mul jltz oldsetlinewidth
- currentlinewidth jpnum ( w\n) jp } def
-/oldsetlinecap [/setlinecap load] cbdef
-/setlinecap {dup oldsetlinecap jpnum ( J\n) jp} def
-/oldsetlinejoin [/setlinejoin load] cbdef
-/setlinejoin {dup oldsetlinejoin jpnum ( j\n) jp} def
-/oldsetmiterlimit [/setmiterlimit load] cbdef
-/setmiterlimit {dup oldsetmiterlimit jpnum ( M\n) jp}def
-/oldsetdash [/setdash load] cbdef
-/setdash {exch [ exch {kscl abs mul} forall ] exch kscl abs mul oldsetdash
- currentdash exch jpmat jpnum ( d\n) jp } def
-/oldsetflat [/setflat load] cbdef
-/setflat {dup oldsetflat jpnum ( i\n) jp } def
-%
-% More State Operators
-%
-/kscl { % use just the x scale factor
- oldgsave
- matrix currentmatrix /jctm exch def
- jctm 4 0 put jctm 5 0 put jctm setmatrix
- 1 0 moveto currentpoint transform
- dup mul exch dup mul add sqrt 10000 mul round 10000 div
- oldgrestore
-} def
-/currentstate {currentcmykcolor setcmykcolor
- currentflat jpnum ( i) jp currentlinecap jpnum ( J) jp
- currentlinejoin jpnum ( j) jp currentlinewidth jpnum ( w) jp
- currentmiterlimit jpnum ( M ) jp currentdash exch jpmat jpnum ( d\n) jp
-} def
-/jdifG {
- currentcmykcolor /jok xdef /joy xdef /jom xdef /joc xdef
- currentflat /jof xdef currentlinecap /jolc xdef currentlinejoin /jolj xdef
- currentlinewidth /jolw xdef currentmiterlimit /joml xdef
- currentdash /jood xdef /joad xdef
- oldgrestore
- currentcmykcolor /jnk xdef /jny xdef /jnm xdef /jnc xdef
- currentflat /jnf xdef currentlinecap /jnlc xdef currentlinejoin /jnlj xdef
- currentlinewidth /jnlw xdef currentmiterlimit /jnml xdef
- currentdash /jnod xdef /jnad xdef
- % compare old gstate to new gstate
- joc jnc ne jom jnm ne joy jny ne jok jnk ne
- jof jnf ne jolc jnlc ne jolj jnlj ne jolw jnlw ne joml jnml ne
- false joad {true exit} forall {pop pop true}{false} ifelse
- false jnad {true exit} forall {pop pop true}{false} ifelse ne
- jood jnod ne 10 {or} repeat {currentstate} if
-} def
-/oldgsave [/gsave load] cbdef
-/gsave {oldgsave /gcnt gcnt 1 add def } def % clarry gcnt false put} def
-% (%%Note:gsave ) jp gcnt jpnum (\n) jp} def
-/oldgrestore [/grestore load] cbdef
-/grestore {dpth {newpath} if clarry gcnt get {(Q\n) jp clarry gcnt false put} if
- jdifG /gcnt gcnt 1 sub def } def
-% oldgrestore currentstate } def
-% (%%Note:grestore ) jp gcnt 1 add jpnum (\n) jp} def
-/oldrestore [/restore load] cbdef
-% a kludgy way of saving the clipping path status information
-/restore {clarry aload pop 11 -1 roll oldrestore clarry astore pop} def
-/showpage { 0 1 9 {clarry exch get {(Q\n) jp} if } for
- (%%Note: If Error, make sure there are matched pairs of 'q's and 'Q's\n) jp
- (%%Note: in the file. Add 'Q's before '%%Trailer' until equal\n) jp
- (%%Trailer\n) jp
- jtxt3 {(Adobe_IllustratorA_AI3 /terminate get exec\n) jp
- (Adobe_typography_AI3 /terminate get exec\n) jp
- (Adobe_customcolor /terminate get exec\n) jp
- (Adobe_cshow /terminate get exec\n) jp
- (Adobe_cmykcolor /terminate get exec\n) jp
- (Adobe_packedarray /terminate get exec\n) jp
-}{
- (Adobe_Illustrator881 /terminate get exec\n) jp
- (Adobe_customcolor /terminate get exec\n) jp
- (Adobe_cshow /terminate get exec\n) jp
- (Adobe_cmykcolor /terminate get exec\n) jp
- (Adobe_packedarray /terminate get exec\n) jp
- } ifelse
-( showpage\n%EOF\n%%EndDocument\n) jp
- jout {joutput closefile} if jMacGS not {quit} if /j3ftxt true def } def
-%
-% Error handling
-%
-errordict begin
-% Attempt to handle the error caused by bitmap fonts (TeX,Windows.ps,etc)
-% this is a big-time kludge
-jbiterr {
- /undefined {pop pop (Times-Roman)} def
- /typecheck {pop pop} def
-} if
-jerr {
- /handleerror {
- (%%Note: ps2ai error, aborting rest of conversion\n) jp showpage
- } def
-} if
-end
-%
-% Mac LW 8 improvements
-%
-/jmacimp { % stroked line instead of thin filled boxes
- /@a { 3 -1 roll 2 div dup 3 -1 roll add exch 3 -1 roll add exch moveto
- 3 -1 roll 2 div dup 3 -1 roll add exch 3 -1 roll exch sub exch lineto
- abs setlinewidth stroke pop pop} def
- /@b { 3 -1 roll 2 div dup 3 -1 roll add exch 3 -1 roll add exch moveto
- pop
- 3 -1 roll 2 div dup 3 -1 roll add exch 3 -1 roll add exch lineto
- abs setlinewidth stroke} def
- /endp {showpage pm restore} def % because the restore stops clean up
-} def
-%
-% Handle (some) PS Level 2
-%
-/rectstroke { 4 2 roll moveto 1 index 0 rlineto 0 exch rlineto neg 0 rlineto
- closepath stroke} def
-/rectfill { 4 2 roll moveto 1 index 0 rlineto 0 exch rlineto neg 0 rlineto
- fill } def
-/rectclip { 4 2 roll moveto 1 index 0 rlineto 0 exch rlineto neg 0 rlineto
- closepath clip newpath jMacfix {jmacimp} if } def
-%
-% Add a header prolog to the output file so it is still view/print-able
-%
-(%!PS-Adobe-2.0 EPSF-1.2\n%%BoundingBox: 0 0 612 792\n) jp
-(%%Title: Adobe Illustator 3 Editable Document\n) jp
-(%%Creator: ps2ai.ps vers.) jp vers jpnum ( \(C\) 1993-94 Jason Olszewski\n) jp
-(%%TemplateBox: 0 0 612 792\n) jp
-jtxt3 {(%%AI3_Margin:0 0 0 0\n) jp } if
-(%%EndComments\n) jp
-(%%BeginProlog\n) jp
-(/m {moveto} def /l {lineto} def /c {curveto} def\n) jp
-(/S {stroke} def /F {fill} def\n) jp
-(/s {closepath S} def /f {closepath F} def\n) jp
-(/q {gsave} def /Q {grestore} def /W {clip} def /k {setcmykcolor} def\n) jp
-(/i {setflat} def /J {setlinecap} def /j {setlinejoin} def\n) jp
-(/w {setlinewidth} def /M {setmiterlimit} def /d {setdash} def\n) jp
-(/u {gsave} def /U {grestore} def /K {k} def\n) jp
-(/N {newpath} def /n {closepath N} def\n) jp
-(/g {setgray} def /G {g} def\n) jp
-(/x {pop pop k} def /X {x} def\n) jp
-(/H {} def /h {H closepath} def /D {pop} def\n) jp
-(/*u { /N {/spth 0 def}def /S{/spth 1 def}def /F {/spth 2 def} def} def\n) jp
-(/*U { spth 0 eq {newpath} if spth 1 eq {stroke} if spth 2 eq {fill} if\n) jp
-( /N {newpath} def /S {stroke} def /F {fill} def } def\n) jp
-%(\n) jp
-jtxt3 {
- (/TC {pop pop pop} def /Tr {pop} def\n) jp
- (/To {pop gsave} def /TO {grestore} def\n) jp
- (/Tp {pop matrix astore concat} def /TP {0 0 moveto} def\n) jp
- (/a_str 40 string def /cnt 0 def /h_str (X) def /undsc (_) 0 get def\n) jp
- (/fntfix {a_str cvs dup length 1 sub /f_str exch string def\n) jp
- ( {dup undsc eq {pop}{f_str cnt 3 -1 roll put /cnt cnt 1 add def\n) jp
- ( } ifelse } forall flush /cnt 0 def f_str cvn } bind def\n) jp
-
- (/Tf {exch fntfix findfont exch scalefont setfont} def /Tx {show} def\n) jp
-}{
- (/z {pop pop pop exch findfont exch scalefont setfont} def\n) jp
- (/e {concat 0 0 m} def /t {show} def /T {} def\n) jp
-} ifelse
-(\n) jp
-jtxt3 {
- (userdict /Adobe_packedarray 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_cmykcolor 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_cshow 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_customcolor 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_typography_AI3 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_IllustratorA_AI3 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
-}{
- (userdict /Adobe_packedarray 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_cmykcolor 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_cshow 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_customcolor 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
- (userdict /Adobe_Illustrator881 2 dict dup begin put\n) jp
- (/initialize {} def /terminate {} def\n) jp
-} ifelse
-(%%EndProlog\n) jp
-(%%BeginSetup\n) jp
-jtxt3 {
- (Adobe_packedarray /initialize get exec\n) jp
- (Adobe_cmykcolor /initialize get exec\n) jp
- (Adobe_cshow /initialize get exec\n) jp
- (Adobe_customcolor /initialize get exec\n) jp
- (Adobe_typography_AI3 /initialize get exec\n) jp
- (Adobe_IllustratorA_AI3 /initialize get exec\n) jp
-}{
- (Adobe_packedarray /initialize get exec\n) jp
- (Adobe_cmykcolor /initialize get exec\n) jp
- (Adobe_cshow /initialize get exec\n) jp
- (Adobe_customcolor /initialize get exec\n) jp
- (Adobe_Illustrator881 /initialize get exec\n) jp
-} ifelse
-(%%EndSetup\n) jp
-0 0 0 1 oldsetcmykcolor
-currentstate
-
-jout {(%%Note: Load Postscript file to be converted now\n) print} if
diff --git a/Master/tlpkg/tlgs/lib/ps2ascii.ps b/Master/tlpkg/tlgs/lib/ps2ascii.ps deleted file mode 100644 index 8a8c1ff755b..00000000000 --- a/Master/tlpkg/tlgs/lib/ps2ascii.ps +++ /dev/null @@ -1,1524 +0,0 @@ -% Copyright (C) 1991, 1995, 1996, 1998, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: ps2ascii.ps 6300 2005-12-28 19:56:24Z giles $
-% Extract the ASCII text from a PostScript file. Nothing is displayed.
-% Instead, ASCII information is written to stdout. The idea is similar to
-% Glenn Reid's `distillery', only a lot more simple-minded, and less robust.
-
-% If SIMPLE is defined, just the text is written, with a guess at line
-% breaks and word spacing. If SIMPLE is not defined, lines are written
-% to stdout as follows:
-%
-% F <height> <width> (<fontname>)
-% Indicate the font height and the width of a space.
-%
-% P
-% Indicate the end of the page.
-%
-% S <x> <y> (<string>) <width>
-% Display a string.
-%
-% <width> and <height> are integer dimensions in units of 1/720".
-% <x> and <y> are integer coordinates, in units of 1/720", with the origin
-% at the lower left.
-% <string> and <fontname> are strings represented with the standard
-% PostScript escape conventions.
-
-% If COMPLEX is defined, the following additional types of lines are
-% written to stdout.
-%
-% C <r> <g> <b>
-% Indicate the current color.
-%
-% I <x> <y> <width> <height>
-% Note the presence of an image.
-%
-% R <x> <y> <width> <height>
-% Fill a rectangle.
-%
-% <r>, <g>, and <b> are RGB values expressed as integers between 0 and 1000.
-%
-% Note that future versions of this program (in COMPLEX mode) may add
-% other output elements, so programs parsing the output should be
-% prepared to ignore elements that they do not recognize.
-
-% Note that this code will only work in all cases if systemdict is writable
-% and if `binding' the definitions of operators defined as procedures
-% is deferred. For this reason, it is normally invoked with
-% gs -q -dNODISPLAY -dDELAYBIND -dWRITESYSTEMDICT ps2ascii.ps
-
-% Thanks to:
-% J Greely <jgreely@cis.ohio-state.edu> for improvements to this code;
-% Jerry Whelan <jerryw@abode.ccd.bnl.gov> for motivating other improvements;
-% David M. Jones <dmjones@theory.lcs.mit.edu> for improvements noted below.
-
-%% Additional modifications by David M. Jones
-%% (dmjones@theory.lcs.mit.edu), December 23, 1997
-%%
-%% (a) Rewrote forall loop at the end of .show.write. This fixes a
-%% stack leakage problem, but the changes are more significant
-%% than that.
-%%
-%% .char.map includes the names of all characters in the
-%% StandardEncoding, ISOLatin1Encoding, OT1Encoding and
-%% T1Encoding vectors. Thus, if the Encoding vector for the
-%% current font contains a name that is not in .char.map, it's
-%% redundant to check if the Encoding vector is equal to one of
-%% the known vectors. Previous versions of ps2ascii would give
-%% up at this point, and substitute an asterisk (*) for the
-%% character. I've taken the liberty of instead using the
-%% OT1Encoding vector to translate the character, on the grounds
-%% that in the cases I'm most interested in, a font without a
-%% useful Encoding vector was most likely created by a DVI to PS
-%% converter such as dvips or DVILASER (and OT1Encoding is
-%% largely compatible with StandardEncoding anyway). [Note that
-%% this does not make my earlier changes to support dvips (see
-%% fix (a) under my 1996 changes) completely obsolete, since
-%% there's additional useful information I can extract in that
-%% case.]
-%%
-%% Overall, this should provide better support for some documents
-%% (e.g, DVILASER documents will no longer be translated into a
-%% series of *'s) without breaking any other documents any worse
-%% than they already were broken.
-%%
-%% (b) Fixed two bugs in dvips.df-tail: (1) changed "dup 127" to "dup
-%% 128" to fix fencepost error, and (2) gave each font it's own
-%% FontName rather than having all fonts share the same name.
-%%
-%% (c) Added one further refinement to the heuristic for detecting
-%% paragraph breaks: do not ever start a new paragraph after a
-%% line ending in a hyphen.
-%%
-%% (d) Added a bunch of missing letters from the T1Encoding,
-%% OT1Encoding and ISOLatin1Encoding vectors to .letter.chars to
-%% improve hyphen-elimination algorithm. This still won't help
-%% if there's no useful Encoding vector.
-%%
-%% NOTE: A better solution to the problem of missing Encoding vectors
-%% might be to redefine definefont to check whether the Encoding
-%% vector is sensible and, if not, replace it by a default. This
-%% would alleviate the need for constant tests in the .show.write
-%% loop, as well as automatically solving the problem noted in fix
-%% (d) above, and the similar problem with .break.chars. This should
-%% be investigated. Also, the hyphen-elimination algorithm really
-%% needs to be looked at carefully and rethought.
-
-%%* Modifications to ps2ascii.ps by David M. Jones
-%%* (dmjones@theory.lcs.mit.edu), June 25-July 8, 1996
-
-%%* Modifications:
-%%*
-%%* (a) added code to give better support for dvips files by providing
-%%* FontBBox's, FontName's and Encoding vectors for downloaded
-%%* bitmap fonts. This is done by using dvips's start-hook to
-%%* overwrite the df-tail and D procedures that dvips uses to
-%%* define its Type 3 bitmap fonts. Thus, this change should
-%%* provide better support for dvips-generated PS files without
-%%* affecting the handling of other documents.
-%%*
-%%* (b) Fixed two bugs that could potentially affect any PS file, not
-%%* just those created by dvips: (1) added missing "get" operator
-%%* in .show.write and (2) fixed bug that caused a hyphen at the
-%%* end of a line to be replaced by a space rather than begin
-%%* deleted. Note that the first bug was a source of stack
-%%* leakage, causing ps2ascii to run out of operand stack space
-%%* occasionally.
-%%*
-%%* Search for "%%* BF" to find these modifications.
-%%*
-%%* (c) Improved the heuristic for determining whether a line break
-%%* has occurred and whether a line break represents a paragraph
-%%* break. Previously, any change in the vertical position caused
-%%* a line break; now a line break is only registered if the
-%%* change is larger than the height of the current font. This
-%%* means that superscripts, subscripts, and such things as
-%%* shifted accents generated by TeX won't cause line breaks.
-%%* Paragraph-recognition is now done by comparing the indentation
-%%* of the new line to the indentation of the previous line and by
-%%* comparing the vertical distance between the new line and the
-%%* previous line to the vertical distance between the previous
-%%* line and its predecessor.
-%%*
-%%* (d) Added a hook for renaming the files where stdout and stderr
-%%* go.
-%%*
-%%* In general, my additions or changes to the code are described in
-%%* comments beginning with "%%*". However, there are numerous other
-%%* places where I have either re-formatted code or added comments to
-%%* the code while I was trying to understand it. These are usually
-%%* not specially marked.
-%%*
-
-/QUIET true def
-systemdict wcheck { systemdict } { userdict } ifelse begin
-/.max where { pop } { /.max { 2 copy lt { exch } if pop } bind def } ifelse
-/COMPLEX dup where { pop true } { false } ifelse def
-/SIMPLE dup where { pop true } { false } ifelse def
-/setglobal where
- { pop currentglobal /setglobal load true setglobal }
- { { } }
-ifelse
-
-% Define a way to store and retrieve integers that survives save/restore.
-/.i.string0 (0 ) def
-/.i.string .i.string0 length string def
-/.iget { cvi } bind def
-/.iput { exch //.i.string exch copy cvs pop } bind def
-/.inew { //.i.string0 dup length string copy } bind def
-
-% We only want to redefine operators if they are defined already.
-
-/codef { 1 index where { pop def } { pop pop } ifelse } def
-
-% Redefine the end-of-page operators.
-
-/erasepage { } codef
-/copypage { SIMPLE { (\014) } { (P\n) } ifelse //print } codef
-/showpage { copypage erasepage initgraphics } codef
-
-% Redefine the fill operators to detect rectangles.
-
-/.orderrect % <llx> <lly> <urx> <ury> .orderrect <llx> <lly> <w> <h>
- { % Ensure llx <= urx, lly <= ury.
- 1 index 4 index lt { 4 2 roll } if
- dup 3 index lt { 3 1 roll exch } if
- exch 3 index sub exch 2 index sub
- } odef
-/.fillcomplex
- { % Do a first pass to see if the path is all rectangles in
- % the output coordinate system. We don't worry about overlapping
- % rectangles that might be partially not filled.
- % Stack: mark llx0 lly0 urx0 ury0 ... true mark x0 y0 ...
- mark true mark
- % Add a final moveto so we pick up any trailing unclosed subpath.
- 0 0 itransform moveto
- { .coord counttomark 2 gt
- { counttomark 4 gt { .fillcheckrect } { 4 2 roll pop pop } ifelse }
- if
- }
- { .coord }
- { cleartomark not mark exit }
- { counttomark -2 roll 2 copy counttomark 2 roll .fillcheckrect }
- pathforall cleartomark
- { .showcolor counttomark 4 idiv
- { counttomark -4 roll .orderrect
- (R ) //print .show==4
- }
- repeat pop
- }
- { cleartomark
- }
- ifelse
- } odef
-/.fillcheckrect
- { % Check whether the current subpath is a rectangle.
- % If it is, add it to the list of rectangles being accumulated;
- % if not exit the .fillcomplex loop.
- % The subpath has not been closed.
- % Stack: as in .fillcomplex, + newx newy
- counttomark 10 eq { 9 index 9 index 4 2 roll } if
- counttomark 12 ne { cleartomark not mark exit } if
- 12 2 roll
- % Check for the two possible forms of rectangles:
- % x0 y0 x0 y1 x1 y1 x1 y0 x0 y0
- % x0 y0 x1 y0 x1 y1 x0 y1 x0 y0
- 9 index 2 index eq 9 index 2 index eq and
- 10 index 9 index eq
- { % Check for first form.
- 7 index 6 index eq and 6 index 5 index eq and 3 index 2 index eq and
- }
- { % Check for second form.
- 9 index 8 index eq and
- 8 index 7 index eq and 5 index 4 index eq and 4 index 3 index eq and
- }
- ifelse not { cleartomark not mark exit } if
- % We have a rectangle.
- pop pop pop pop 4 2 roll pop pop 8 4 roll
- } odef
-/eofill { COMPLEX { .fillcomplex } if newpath } codef
-/fill { COMPLEX { .fillcomplex } if newpath } codef
-/rectfill { gsave newpath .rectappend fill grestore } codef
-/ueofill { gsave newpath uappend eofill grestore } codef
-/ufill { gsave newpath uappend fill grestore } codef
-
-% Redefine the stroke operators to detect rectangles.
-
-/rectstroke
- { gsave newpath
- dup type dup /arraytype eq exch /packedarraytype eq or
- { dup length 6 eq { exch .rectappend concat } { .rectappend } ifelse }
- { .rectappend }
- ifelse stroke grestore
- } codef
-/.strokeline % <fromx> <fromy> <tox> <toy> .strokeline <tox> <toy>
- % Note: fromx and fromy are in output coordinates;
- % tox and toy are in user coordinates.
- { .coord 2 copy 6 2 roll .orderrect
- % Add in the line width. Assume square or round caps.
- currentlinewidth 2 div dup .dcoord add abs 1 .max 5 1 roll
- 4 index add 4 1 roll 4 index add 4 1 roll
- 4 index sub 4 1 roll 5 -1 roll sub 4 1 roll
- (R ) //print .show==4
- } odef
-/.strokecomplex
- { % Do a first pass to see if the path is all horizontal and vertical
- % lines in the output coordinate system.
- % Stack: true mark origx origy curx cury
- true mark null null null null
- { .coord 6 2 roll pop pop pop pop 2 copy }
- { .coord 1 index 4 index eq 1 index 4 index eq or
- { 4 2 roll pop pop }
- { cleartomark not mark exit }
- ifelse
- }
- { cleartomark not mark exit }
- { counttomark -2 roll 2 copy counttomark 2 roll
- 1 index 4 index eq 1 index 4 index eq or
- { pop pop 2 copy }
- { cleartomark not mark exit }
- ifelse
- }
- pathforall cleartomark
- 0 currentlinewidth .dcoord 0 eq exch 0 eq or and
- % Do the second pass to write out the rectangles.
- % Stack: origx origy curx cury
- { .showcolor null null null null
- { 6 2 roll pop pop pop pop 2 copy .coord }
- { .strokeline }
- { }
- { 3 index 3 index .strokeline }
- pathforall pop pop pop pop
- }
- if
- } odef
-/stroke { COMPLEX { .strokecomplex } if newpath } codef
-/ustroke
- { gsave newpath
- dup length 6 eq { exch uappend concat } { uappend } ifelse
- stroke grestore
- } codef
-
-% The image operators must read the input and note the dimensions.
-% Eventually we should redefine these to detect 1-bit-high all-black images,
-% since this is how dvips does underlining (!).
-
-/.noteimagerect % <width> <height> <matrix> .noteimagerect -
- { COMPLEX
- { gsave setmatrix itransform 0 0 itransform
- grestore .coord 4 2 roll .coord .orderrect
- (I ) //print .show==4
- }
- { pop pop pop
- }
- ifelse
- } odef
-/colorimage where
- { pop /colorimage
- { 1 index
- { dup 6 add index 1 index 6 add index 2 index 5 add index }
- { 6 index 6 index 5 index }
- ifelse .noteimagerect gsave nulldevice //colorimage grestore
- } codef
- } if
-/.noteimage % Arguments as for image[mask]
- { dup type /dicttype eq
- { dup /Width get 1 index /Height get 2 index /ImageMatrix get }
- { 4 index 4 index 3 index }
- ifelse .noteimagerect
- } odef
-/image { .noteimage gsave nulldevice //image grestore } codef
-/imagemask { .noteimage gsave nulldevice //imagemask grestore } codef
-
-% Output the current color if necessary.
-/.color.r .inew def
- .color.r -1 .iput % make sure we write the color at the beginning
-/.color.g .inew def
-/.color.b .inew def
-/.showcolor
- { COMPLEX
- { currentrgbcolor
- 1000 mul round cvi
- 3 1 roll 1000 mul round cvi
- exch 1000 mul round cvi
- % Stack: b g r
- dup //.color.r .iget eq
- 2 index //.color.g .iget eq and
- 3 index //.color.b .iget eq and
- { pop pop pop
- }
- { (C ) //print
- dup //.color.r exch .iput .show==only
- ( ) //print dup //.color.g exch .iput .show==only
- ( ) //print dup //.color.b exch .iput .show==only
- (\n) //print
- }
- ifelse
- }
- if
- } bind def
-
-% Redefine `show'.
-
-% Set things up so our output will be in tenths of a point, with origin at
-% lower left. This isolates us from the peculiarities of individual devices.
-
-/.show.ident.matrix matrix def
-/.show.ident { % - .show.ident <scale> <matrix>
-% //.show.ident.matrix defaultmatrix
-% % Assume the original transformation is well-behaved.
-% 0.1 0 2 index dtransform abs exch abs .max /.show.scale exch def
-% 0.1 dup 3 -1 roll scale
- gsave initmatrix
- % Assume the original transformation is well-behaved...
- 0.1 0 dtransform abs exch abs .max
- 0.1 dup scale .show.ident.matrix currentmatrix
- % ... but undo any rotation into landscape orientation.
- dup 0 get 0 eq {
- 1 get dup abs div 90 mul rotate
- .show.ident.matrix currentmatrix
- } if
- grestore
-} bind def
-
-/.coord { % <x> <y> .coord <x'> <y'>
- transform .show.ident exch pop itransform
- exch round cvi exch round cvi
-} odef
-
-/.dcoord { % <dx> <dy> .coord <dx'> <dy'>
- % Transforming distances is trickier, because
- % the coordinate system might be rotated.
- .show.ident pop 3 1 roll
- exch 0 dtransform
- dup mul exch dup mul add sqrt
- 2 index div round cvi
- exch 0 exch dtransform
- dup mul exch dup mul add sqrt
- 3 -1 roll div round cvi
-} odef
-
-% Remember the current X, Y, and height.
-/.show.x .inew def
-/.show.y .inew def
-/.show.height .inew def
-
-% Remember the last character of the previous string; if it was a
-% hyphen preceded by a letter, we didn't output the hyphen.
-
-/.show.last (\000) def
-
-% Remember the current font.
-/.font.name 130 string def
-/.font.name.length .inew def
-/.font.height .inew def
-/.font.width .inew def
-
-%%* Also remember indentation of current line and previous vertical
-%%* skip
-
-/.show.indent .inew def
-/.show.dy .inew def
-
-% We have to redirect stdout somehow....
-
-/.show.stdout { (%stdout) (w) file } bind def
-
-% Make sure writing will work even if a program uses =string.
-/.show.string =string length string def
-/.show.=string =string length string def
-/.show==only
- { //=string //.show.=string copy pop
- dup type /stringtype eq
- { dup length //.show.string length le
- { dup rcheck { //.show.string copy } if
- } if
- } if
- .show.stdout exch write==only
- //.show.=string //=string copy pop
- } odef
-/.show==4
- { 4 -1 roll .show==only ( ) //print
- 3 -1 roll .show==only ( ) //print
- exch .show==only ( ) //print
- .show==only (\n) //print
- } odef
-
-/.showwidth % Same as stringwidth, but disable COMPLEX so that
- % we don't try to detect rectangles during BuildChar.
- { COMPLEX
- { /COMPLEX false def stringwidth /COMPLEX true def }
- { stringwidth }
- ifelse
- } odef
-
-/.showfont % <string> .showfont <string>
- { gsave
- % Try getting the height and width of the font from the FontBBox.
- currentfont /FontBBox .knownget not { {0 0 0 0} } if
- aload pop % llx lly urx ury
- exch 4 -1 roll % lly ury urx llx
- sub % lly ury dx
- 3 1 roll exch % dx ury lly
- sub % dx dy
- 2 copy .max 0 ne
- { currentfont /FontMatrix get dtransform
- }
- { pop pop
- % Fonts produced by dvips, among other applications, have
- % BuildChar procedures that bomb out when given unexpected
- % characters, and there is no way to determine whether a given
- % character will do this. So for Type 1 fonts, we measure a
- % typical character ('X'); for others, we punt.
- currentfont /FontType get 1 eq
- { (X) .showwidth pop dup 1.3 mul
- }
- { % No safe way to get the character size. Punt.
- 0 0
- }
- ifelse
- }
- ifelse .dcoord exch
- currentfont /FontName .knownget not { () } if
- dup type /stringtype ne { //.show.string cvs } if
- grestore
- % Stack: height width fontname
- SIMPLE
- { pop pop //.show.height exch .iput }
- { 2 index //.font.height .iget eq
- 2 index //.font.width .iget eq and
- 1 index //.font.name 0 //.font.name.length .iget getinterval eq and
- { pop pop pop
- }
- { (F ) //print
- 3 -1 roll dup //.font.height exch .iput .show==only ( ) //print
- exch dup //.font.width exch .iput .show==only ( ) //print
- dup length //.font.name.length exch .iput
- //.font.name cvs .show==only (\n) //print
- }
- ifelse
- }
- ifelse
- } odef
-
-% Define the letters -- characters which, if they occur followed by a hyphen
-% at the end of a line, cause the hyphen and line break to be ignored.
-/.letter.chars 100 dict def
-mark
- 65 1 90 { dup 32 add } for
- counttomark
- { StandardEncoding exch get .letter.chars exch dup put }
- repeat
-pop
-
-%%* Add the rest of the letters from the [O]T1Encoding and
-%%* ISOLatin1Encoding vectors
-
-mark
- /AE
- /Aacute
- /Abreve
- /Acircumflex
- /Adieresis
- /Agrave
- /Aogonek
- /Aring
- /Atilde
- /Cacute
- /Ccaron
- /Ccedilla
- /Dcaron
- /Eacute
- /Ecaron
- /Ecircumflex
- /Edieresis
- /Egrave
- /Eng
- /Eogonek
- /Eth
- /Gbreve
- /Germandbls
- /IJ
- /Iacute
- /Icircumflex
- /Idieresis
- /Idot
- /Igrave
- /Lacute
- /Lcaron
- /Lslash
- /Nacute
- /Ncaron
- /Ntilde
- /OE
- /Oacute
- /Ocircumflex
- /Odieresis
- /Ograve
- /Ohungarumlaut
- /Oslash
- /Otilde
- /Racute
- /Rcaron
- /Sacute
- /Scaron
- /Scedilla
- /Tcaron
- /Tcedilla
- /Thorn
- /Uacute
- /Ucircumflex
- /Udieresis
- /Ugrave
- /Uhungarumlaut
- /Uring
- /Yacute
- /Ydieresis
- /Zacute
- /Zcaron
- /Zdot
- /aacute
- /abreve
- /acircumflex
- /adieresis
- /ae
- /agrave
- /aogonek
- /aring
- /atilde
- /cacute
- /ccaron
- /ccedilla
- /dbar
- /dcaron
- /dotlessi
- /dotlessj
- /eacute
- /ecaron
- /ecircumflex
- /edieresis
- /egrave
- /eng
- /eogonek
- /eth
- /exclamdown
- /ff
- /ffi
- /ffl
- /fi
- /fl
- /gbreve
- /germandbls
- /iacute
- /icircumflex
- /idieresis
- /igrave
- /ij
- /lacute
- /lcaron
- /lslash
- /nacute
- /ncaron
- /ntilde
- /oacute
- /ocircumflex
- /odieresis
- /oe
- /ograve
- /ohungarumlaut
- /oslash
- /otilde
- /questiondown
- /racute
- /rcaron
- /sacute
- /scaron
- /scedilla
- /section
- /sterling
- /tcaron
- /tcedilla
- /thorn
- /uacute
- /ucircumflex
- /udieresis
- /ugrave
- /uhungarumlaut
- /uring
- /yacute
- /ydieresis
- /zacute
- /zcaron
- /zdot
-counttomark
- { .letter.chars exch dup put }
-repeat
-pop
-
-% Define a set of characters which, if they occur at the start of a line,
-% are taken as indicating a paragraph break.
-/.break.chars 50 dict def
-mark
- /bullet /dagger /daggerdbl /periodcentered /section
- counttomark
- { .break.chars exch dup put }
- repeat
-pop
-
-% Define character translation to ASCII.
-% We have to do this for the entire character set.
-
-/.char.map 500 dict def
-
-/.chars.def { counttomark 2 idiv { .char.map 3 1 roll put } repeat pop } def
-
-% Encode the printable ASCII characters.
-
-mark 32 1 126
- { 1 string dup 0 4 -1 roll put
- dup 0 get StandardEncoding exch get exch
- }
-for .chars.def
-
- % Encode accents.
-mark
- /acute (')
- /caron (^)
- /cedilla (,)
- /circumflex (^)
- /dieresis (")
- /grave (`)
- /ring (*)
- /tilde (~)
-.chars.def
-
- % Encode the ISO accented characters.
-mark 192 1 255
- { ISOLatin1Encoding exch get =string cvs
- dup 0 1 getinterval 1 index dup length 1 sub 1 exch getinterval
- .char.map 2 index known .char.map 2 index known and
- { .char.map 3 -1 roll get .char.map 3 -1 roll get concatstrings
- .char.map 3 1 roll put
- }
- { pop pop pop
- }
- ifelse
- }
-for .chars.def
-
-% Encode the remaining standard and ISO alphabetic characters.
-
-mark
- /AE (AE) /Eth (DH) /OE (OE) /Thorn (Th)
- /ae (ae) /eth (dh)
- /ffi (ffi) /ffl (ffl) /fi (fi) /fl (fl)
- /germandbls (ss) /oe (oe) /thorn (th)
-.chars.def
-
-% Encode the other standard and ISO characters.
-
-mark
- /brokenbar (|) /bullet (*) /copyright ((C)) /currency (#)
- /dagger (#) /daggerdbl (##) /degree (o) /divide (/) /dotaccent (.)
- /dotlessi (i)
- /ellipsis (...) /emdash (--) /endash (-) /exclamdown (!)
- /florin (f) /fraction (/)
- /guillemotleft (<<) /guillemotright (>>)
- /guilsinglleft (<) /guilsinglright (>) /hungarumlaut ("") /logicalnot (~)
- /macron (_) /minus (-) /mu (u) /multiply (*)
- /ogonek (,) /onehalf (1/2) /onequarter (1/4) /onesuperior (1)
- /ordfeminine (-a) /ordmasculine (-o)
- /paragraph (||) /periodcentered (*) /perthousand (o/oo) /plusminus (+-)
- /questiondown (?) /quotedblbase (") /quotedblleft (") /quotedblright (")
- /quotesinglbase (,) /quotesingle (') /registered ((R))
- /section ($) /sterling (#)
- /threequarters (3/4) /threesuperior (3) /trademark ((TM)) /twosuperior (2)
- /yen (Y)
-.chars.def
-
-% Encode a few common Symbol characters.
-
-mark
- /asteriskmath (*) /copyrightsans ((C)) /copyrightserif ((C))
- /greaterequal (>=) /lessequal (<=) /registersans ((R)) /registerserif ((R))
- /trademarksans ((TM)) /trademarkserif ((TM))
-.chars.def
-
-%%* Add a few characters from StandardEncoding and ISOLatin1Encoding
-%%* that were missing.
-
-mark
- /cent (c)
- /guilsinglleft (<)
- /guilsinglright (>)
- /breve (*)
- /Lslash (L/)
- /lslash (l/)
-.chars.def
-
-%%* Define the OT1Encoding and T1Encoding vectors for use with dvips
-%%* files. Unfortunately, there's no way of telling what font is
-%%* really being used within a dvips document, so we can't provide an
-%%* appropriate encoding for each individual font. Instead, we'll
-%%* just provide support for the two most popular text encodings, the
-%%* OT1 and T1 encodings, and just accept the fact that any font not
-%%* using one of those encodings will be rendered as gibberish.
-%%*
-%%* OT1 is Knuth's 7-bit encoding for the CMR text fonts, while T1
-%%* (aka the Cork encoding) is the 8-bit encoding used by the DC
-%%* fonts, a preliminary version of the proposed Extended Computer
-%%* Modern fonts. Unfortunately, T1 is not a strict extension of OT1;
-%%* they differ in positions 8#000 through 8#040, 8#074, 8#076, 8#134,
-%%* 8#137, 8#173, 8#174, 8#175 and 8#177, so we can't use the same
-%%* vector for both.
-%%*
-%%* Of course, we also can't reliably tell the difference between an
-%%* OT1-encoded font and a T1-encoded font based on the information in
-%%* a dvips-created PostScript file. As a best-guess solution, we'll
-%%* use the T1 encoding if the font contains any characters in
-%%* positions above 8#177 and the OT1 encoding if it doesn't.
-
-/T1Encoding 256 array def
-
-/OT1Encoding 256 array def
-
-%%* T1Encoding shares a lot with StandardEncoding, so let's start
-%%* there.
-
-StandardEncoding T1Encoding copy pop
-
-/OT1.encode {
- counttomark
- 2 idiv
- { OT1Encoding 3 1 roll put }
- repeat
- cleartomark
-} def
-
-/T1.encode {
- counttomark
- 2 idiv
- { T1Encoding 3 1 roll put }
- repeat
- cleartomark
-} def
-
-mark
- 8#000 /grave
- 8#001 /acute
- 8#002 /circumflex
- 8#003 /tilde
- 8#004 /dieresis
- 8#005 /hungarumlaut
- 8#006 /ring
- 8#007 /caron
-
- 8#010 /breve
- 8#011 /macron
- 8#012 /dotaccent
- 8#013 /cedilla
- 8#014 /ogonek
- 8#015 /quotesinglbase
- 8#016 /guilsinglleft
- 8#017 /guilsinglright
-
- 8#020 /quotedblleft
- 8#021 /quotedblright
- 8#022 /quotedblbase
- 8#023 /guillemotleft
- 8#024 /guillemotright
- 8#025 /endash
- 8#026 /emdash
- 8#027 /cwm
-
- 8#030 /perthousandzero
- 8#031 /dotlessi
- 8#032 /dotlessj
- 8#033 /ff
- 8#034 /fi
- 8#035 /fl
- 8#036 /ffi
- 8#037 /ffl
-
-%% 8#040 through 8#176 follow StandardEncoding
-
- 8#177 /hyphen
-T1.encode
-
-mark
- 8#200 /Abreve
- 8#201 /Aogonek
- 8#202 /Cacute
- 8#203 /Ccaron
- 8#204 /Dcaron
- 8#205 /Ecaron
- 8#206 /Eogonek
- 8#207 /Gbreve
- 8#210 /Lacute
- 8#211 /Lcaron
- 8#212 /Lslash
- 8#213 /Nacute
- 8#214 /Ncaron
- 8#215 /Eng
- 8#216 /Ohungarumlaut
- 8#217 /Racute
- 8#220 /Rcaron
- 8#221 /Sacute
- 8#222 /Scaron
- 8#223 /Scedilla
- 8#224 /Tcaron
- 8#225 /Tcedilla
- 8#226 /Uhungarumlaut
- 8#227 /Uring
- 8#230 /Ydieresis
- 8#231 /Zacute
- 8#232 /Zcaron
- 8#233 /Zdot
- 8#234 /IJ
- 8#235 /Idot
- 8#236 /dbar
- 8#237 /section
- 8#240 /abreve
- 8#241 /aogonek
- 8#242 /cacute
- 8#243 /ccaron
- 8#244 /dcaron
- 8#245 /ecaron
- 8#246 /eogonek
- 8#247 /gbreve
- 8#250 /lacute
- 8#251 /lcaron
- 8#252 /lslash
- 8#253 /nacute
- 8#254 /ncaron
- 8#255 /eng
- 8#256 /ohungarumlaut
- 8#257 /racute
- 8#260 /rcaron
- 8#261 /sacute
- 8#262 /scaron
- 8#263 /scedilla
- 8#264 /tcaron
- 8#265 /tcedilla
- 8#266 /uhungarumlaut
- 8#267 /uring
- 8#270 /ydieresis
- 8#271 /zacute
- 8#272 /zcaron
- 8#273 /zdot
- 8#274 /ij
- 8#275 /exclamdown
- 8#276 /questiondown
- 8#277 /sterling
-
- 8#300 /Agrave
- 8#301 /Aacute
- 8#302 /Acircumflex
- 8#303 /Atilde
- 8#304 /Adieresis
- 8#305 /Aring
- 8#306 /AE
- 8#307 /Ccedilla
- 8#310 /Egrave
- 8#311 /Eacute
- 8#312 /Ecircumflex
- 8#313 /Edieresis
- 8#314 /Igrave
- 8#315 /Iacute
- 8#316 /Icircumflex
- 8#317 /Idieresis
- 8#320 /Eth
- 8#321 /Ntilde
- 8#322 /Ograve
- 8#323 /Oacute
- 8#324 /Ocircumflex
- 8#325 /Otilde
- 8#326 /Odieresis
- 8#327 /OE
- 8#330 /Oslash
- 8#331 /Ugrave
- 8#332 /Uacute
- 8#333 /Ucircumflex
- 8#334 /Udieresis
- 8#335 /Yacute
- 8#336 /Thorn
- 8#337 /Germandbls
-
- 8#340 /agrave
- 8#341 /aacute
- 8#342 /acircumflex
- 8#343 /atilde
- 8#344 /adieresis
- 8#345 /aring
- 8#346 /ae
- 8#347 /ccedilla
- 8#350 /egrave
- 8#351 /eacute
- 8#352 /ecircumflex
- 8#353 /edieresis
- 8#354 /igrave
- 8#355 /iacute
- 8#356 /icircumflex
- 8#357 /idieresis
- 8#360 /eth
- 8#361 /ntilde
- 8#362 /ograve
- 8#363 /oacute
- 8#364 /ocircumflex
- 8#365 /otilde
- 8#366 /odieresis
- 8#367 /oe
- 8#370 /oslash
- 8#371 /ugrave
- 8#372 /uacute
- 8#373 /ucircumflex
- 8#374 /udieresis
- 8#375 /yacute
- 8#376 /thorn
- 8#377 /germandbls
-
-T1.encode
-
-%%* Now copy OT1Encoding into T1Encoding and make a few changes.
-
-T1Encoding OT1Encoding copy pop
-
-mark
- 8#000 /Gamma
- 8#001 /Delta
- 8#002 /Theta
- 8#003 /Lambda
- 8#004 /Xi
- 8#005 /Pi
- 8#006 /Sigma
- 8#007 /Upsilon
-
- 8#010 /Phi
- 8#011 /Psi
- 8#012 /Omega
- 8#013 /ff
- 8#014 /fi
- 8#015 /fl
- 8#016 /ffi
- 8#017 /ffl
-
- 8#020 /dotlessi
- 8#021 /dotlessj
- 8#022 /grave
- 8#023 /acute
- 8#024 /caron
- 8#025 /breve
- 8#026 /macron
- 8#027 /ring
-
- 8#030 /cedilla
- 8#031 /germandbls
- 8#032 /ae
- 8#033 /oe
- 8#034 /oslash
- 8#035 /AE
- 8#036 /OE
- 8#037 /Oslash
-
- 8#040 /polishslash
-
- 8#042 /quotedblright
-
- 8#074 /exclamdown
- 8#076 /questiondown
-
- 8#134 /quotedblleft
- 8#137 /dotaccent
-
- 8#173 /endash
- 8#174 /emdash
- 8#175 /hungarumlaut
- 8#177 /dieresis
-OT1.encode
-
-%%* And add a few characters from the OT1Encoding
-
-mark
- /Gamma (\\Gamma )
- /Delta (\\Delta )
- /Theta (\\Theta )
- /Lambda (\\Lambda )
- /Xi (\\Xi )
- /Pi (\\Pi )
- /Sigma (\\Sigma )
- /Upsilon (\\Upsilon )
-
- /Phi (\\Phi )
- /Psi (\\Psi )
- /Omega (\\Omega )
-
- /dotlessj (j)
- /ff (ff)
-
- /cwm ()
-
- /perthousandzero (0)
-
- /polishslash ()
-
- /Abreve (A*)
- /Aogonek (A,)
- /Cacute (C')
- /Ccaron (C^)
- /Dcaron (D^)
- /Ecaron (E^)
- /Eogonek (E,)
- /Gbreve (G*)
- /Lacute (L')
- /Lcaron (L^)
- /Nacute (N')
- /Ncaron (N^)
- /Eng (NG)
- /Ohungarumlaut (O"")
- /Racute (R')
- /Rcaron (R^)
- /Sacute (S')
- /Scaron (S^)
- /Scedilla (S,)
- /Tcaron (T^)
- /Tcedilla (T,)
- /Uhungarumlaut (U"")
- /Uring (U*)
- /Ydieresis (Y")
- /Zacute (Z')
- /Zcaron (Z^)
- /Zdot (Z.)
- /IJ (IJ)
- /Idot (I.)
- /dbar (d-)
- /abreve (a*)
- /aogonek (a,)
- /cacute (c')
- /ccaron (c^)
- /dcaron (d^)
- /ecaron (e^)
- /eogonek (e,)
- /gbreve (g*)
- /lacute (l')
- /lcaron (l^)
- /nacute (n')
- /ncaron (n^)
- /eng (ng)
- /ohungarumlaut (o"")
- /racute (r')
- /rcaron (r^)
- /sacute (s')
- /scaron (s^)
- /scedilla (s,)
- /tcaron (t^)
- /tcedilla (t,)
- /uhungarumlaut (u"")
- /uring (u*)
- /zacute (z')
- /zcaron (z^)
- /zdot (z.)
- /ij (ij)
- /Germandbls (SS)
-.chars.def
-
-%%* We extend the df-tail command to stick in an Encoding vector (see
-%%* above for a discussion of the T1 and OT1 encodings), put in a
-%%* FontName (which will just be dvips's name for the font, i.e., Fa,
-%%* Fb, etc.) and give each font a separate FontBBox instead of
-%%* letting them all share a single one.
-
-/dvips.df-tail % id numcc maxcc df-tail
- {
- /nn 9 dict N
- nn begin
- %%
- %% Choose an encoding based on the highest position occupied.
- %%
- dup 128 gt { T1Encoding } { OT1Encoding } ifelse
- /Encoding X
- /FontType 3 N
- %%
- %% It's ok for all the fonts to share a FontMatrix, but they
- %% need to have separate FontBBoxes
- %%
- /FontMatrix fntrx N
- /FontBBox [0 0 0 0] N
- string /base X
- array /BitMaps X
- %%
- %% And let's throw in a FontName for good measure
- %%
- dup ( ) cvs
- %%
- %% Make sure each font gets it own private FontName. -- dmj,
- %% 12/23/97
- %%
- dup length string copy
- /FontName X
- /BuildChar {CharBuilder} N
- end
- dup { /foo setfont }
- 2 array copy cvx N
- load
- 0 nn put
- /ctr 0 N
- [
-} def
-
-%%* This is functionally equivalent to dvips's /D procedure, but it
-%%* also calculates the Font Bounding Box while defining the
-%%* characters.
-
-/dvips.D % char-data ch D - : define character bitmap in current font
-{
- /cc X % char-data
- dup type /stringtype ne {]} if % char-data
-
- /ch-xoff where
- { pop }
- { dup /Cd exch def
- /ch-width { Cw } def
- /ch-height { Ch } def
- /ch-xoff { Cx } def
- /ch-yoff { Cy } def
- /ch-dx { Cdx } def
- } ifelse
- /ch-data X
- nn /base get cc ctr put % (adds ctr to cc'th position of BASE)
- nn /BitMaps get
- ctr
- ch-data % BitMaps ctr char-data
- sf 1 ne {
- dup dup length 1 sub dup 2 index S get sf div put
- } if
- put % puts char-data into BitMaps at index ctr
- /ctr ctr 1 add N
-%%
-%% Make sure the Font Bounding Box encloses the Bounding Box of the
-%% current character
-%%
- nn /FontBBox get % BB
-
- dup % calculate new llx
- dup 0 get
- ch-xoff
- .min
- 0 exch put
-
- dup % calculate new lly
- dup 1 get
- ch-yoff ch-height sub
- .min
- 1 exch put
-
- dup % calculate new urx
- dup 2 get
- ch-dx ch-width add
- .max
- 2 exch put
-
- dup 3 get % calculate new ury
- ch-yoff
- .max
- 3 exch put
-
-} def
-
-%%* Define start-hook to replace df-tail and D by our versions.
-%%* Unfortunately, the user can redefine start-hook and thus bypass
-%%* these changes, but I don't see an obvious way around that.
-
-userdict /start-hook {
- TeXDict /df-tail /dvips.df-tail load bind put
- TeXDict /D /dvips.D load bind put
-} put
-
-%%* Introduce a symbolic constant for hyphens. (Need to make
-%%* allowance for hyphen being in different place?)
-
-/.hyphen 45 def
-
-% Write out a string. If it ends in a letter and a hyphen,
-% don't write the hyphen, and set .show.last to a hyphen;
-% otherwise, set .show.last to the character (or \000 if it was a hyphen).
-/.show.write % <string>
- {
- dup length 1 ge
- { dup dup length 1 sub get % string last_char
- dup .hyphen eq % string last_char hyphen?
- { % string last_char
- 1 index length 1 gt
- { 1 index dup length 2 sub get }
- { //.show.last 0 get }
- ifelse % string last_char prev-char
- currentfont /Encoding get exch get % look up prev-char
- //.letter.chars exch known % is it a letter?
- { % Remove the hyphen % string last_char
- exch % last_char string
- dup length 1 sub % last_char string len-1
- 0 exch getinterval % last_char string-1
- exch % string-1 last_char
- }
- { pop 0 } % string 0
- ifelse
- }
- if
- //.show.last 0 3 -1 roll put % store last_char
- % in .show.last
- % If .show.last ==
- % hyphen, then
- % last char of
- % previous string
- % was a hyphen
- }
- if % string
- currentfont /FontType get 0 ne
- {
- { % begin forall % c
- dup % c c
- currentfont /Encoding get % c c vec
- exch get % c name
- dup //.char.map exch known % c name bool
- { exch pop }
- { pop OT1Encoding exch get }
- ifelse % name
- //.char.map exch get % translation
- .show.stdout exch writestring
- }
- forall
- }
- { (\0) dup 0 get 0 eq
- { 0 1 put
- (%stderr) (w) file dup
- (*** Warning: composite font characters dumped without decoding.\n) writestring
- closefile
- }
- { pop
- }
- ifelse
- .show.stdout exch writestring
- }
- ifelse
-} odef
-
-/.showstring1 { % string
- currentpoint .coord % string x y
- 3 -1 roll dup .showwidth % x y string dx dy
- 1 index % x y string dx dy dx
- 0 rmoveto % x y string dx dy
- .dcoord pop % x y string width
- SIMPLE
- { % x y string width
- 2 index % x y string width y
- //.show.y .iget % x y string width y old.y
- %%*
- %%* Replaced test "has y changed" by "has y changed by more
- %%* than the current font height" so that subscripts and
- %%* superscripts won't cause line/paragraph breaks
- %%*
- sub abs dup % x y string width dy dy
- //.show.height .iget
- gt
- { % x y string width dy
-
- %%* Vertical position has changed by more than the font
- %%* height, so we now try to figure out whether we've
- %%* started a new paragraph or merely a new line, using a
- %%* variety of heuristics.
-
- %%* If any of the following is true, we start a new
- %%* paragraph:
-
- %%* (a) the current vertical shift is more than 1.1 times
- %%* the previous vertical shift, where 1.1 is an
- %%* arbitrarily chosen factor that could probably be
- %%* refined.
-
- dup % x y string width dy dy
- //.show.dy .iget 1.1 mul
- gt
- exch
-
- %%* Save the new vertical shift
-
- //.show.dy exch .iput
-
- %%* (b) The vertical shift is more than 1.3 times the
- %%* "size" of the current font. I've removed this
- %%* test since it's not really very useful.
-
-%%* //.show.dy .iget
-%%* //.show.height .iget 1.4 mul
-%%* gt % x y string width bool
-%%* .show.height .iget 0 gt and % only perform test if font
-%%* % height is nonzero
-%%* or
-
- %%* (c) the first character of the new line is one of the
- %%* .break.chars
-
- 2 index length % x y string width newpar? len
- 0 gt % x y string width newpar? len>0?
- {
- 2 index 0 get % x y string width newpar? s
- currentfont /Encoding get
- exch get % x y string width newpar? s_enc
- //.break.chars exch known { pop true } if
- }
- if % x y string width newpar?
-
- %%* (d) The indentation of the new line is greater than
- %%* the indentation of the previous line.
-
- 4 index
- //.show.indent .iget
- gt
- or
-
- %%* HOWEVER, if the line ends in a hyphen, we do NOT begin
- %%* a new paragraph (cf. comment at end of BF2). --dmj,
- %%* 12/23/97
-
- //.show.last 0 get .hyphen ne
- and
-
- % newpar?
- { (\n\n) } % Paragraph
- { % Line
- %%*
- %%* BF2: If last character on a line is
- %%* a hyphen, we omit the hyphen and
- %%* run the lines together. Of
- %%* course, this will fail if a word
- %%* with an explicit hyphen (e.g.,
- %%* X-ray) is split across two lines.
- %%* Oh, well. (What should we do
- %%* about a hyphen that ends a
- %%* "paragraph"? Perhaps that should
- %%* inhibit a paragraph break.)
- %%*
- //.show.last 0 get .hyphen eq
- { () }
- { ( ) }
- ifelse % x y string width char
- }
- ifelse
- //print
-
- //.show.y 3 index .iput % x y string width
- //.show.x 4 index .iput % x y string width
- //.show.indent 4 index .iput
- }
- { % x y string width dy
- % If the word processor split a hyphenated word within
- % the same line, put out the hyphen now.
- pop
- //.show.last 0 get .hyphen eq { (-) //print } if
- }
- ifelse
- %%*
- %%* If have moved more than 1 point to
- %%* the right, interpret it as a
- %%* space? This need to be looked at
- %%* more closely.
- %%*
- 3 index % x y string width x
- //.show.x .iget 10 add gt % x y string width bool
- { ( ) //print }
- if
- % x y string width
- 4 1 roll % width x y string
- .show.write pop % width x
- add //.show.x exch .iput % <empty>
- }
- { (S ) //print .show==4 }
- ifelse
-} odef
-
-/.showstring
- { dup () eq { pop } { .showstring1 } ifelse
- } bind def
-
-% Redefine all the string display operators.
-
-/show {
- .showfont
- .showcolor
- .showstring
-} codef
-
-% We define all the other operators in terms of .show1.
-
-/.show1.string ( ) def
-/.show1 { //.show1.string exch 0 exch put //.show1.string .showstring } odef
-/ashow
- { .showfont .showcolor
- { .show1 2 copy rmoveto } forall
- pop pop
- } codef
-/awidthshow
- { .showfont .showcolor
- { dup .show1 4 index eq { 4 index 4 index rmoveto } if
- 2 copy rmoveto
- }
- forall
- pop pop pop pop pop
- } codef
-/widthshow
- { .showfont .showcolor
- //.show1.string 0 4 -1 roll put
- { //.show1.string search not { exit } if
- .showstring .showstring
- 2 index 2 index rmoveto
- } loop
- .showstring pop pop
- } codef
-/kshow
- { .showfont .showcolor
- %**************** Should construct a closure, in case the procedure
- %**************** affects the o-stack.
- { .show1 dup exec } forall pop
- } codef
-
-% We don't really do the right thing with the Level 2 show operators,
-% but we do something semi-reasonable.
-/xshow { pop show } codef
-/yshow { pop show } codef
-/xyshow { pop show } codef
-/glyphshow
- { currentfont /Encoding .knownget not { {} } if
- 0 1 2 index length 1 sub
- { % Stack: glyph encoding index
- 2 copy get 3 index eq { exch pop exch pop null exit } if
- pop
- }
- for null eq { (X) dup 0 4 -1 roll put show } { pop } ifelse
- } codef
-
-end
-
-% Bind the operators we just defined, and all the others if we didn't
-% do it before.
-
-DELAYBIND { .bindnow } if
-
-% Make systemdict read-only if it wasn't already.
-
-systemdict wcheck { systemdict readonly pop } if
-
-% Restore the current local/global VM mode.
-
-exec
diff --git a/Master/tlpkg/tlgs/lib/ps2epsi.ps b/Master/tlpkg/tlgs/lib/ps2epsi.ps deleted file mode 100644 index ce83969a731..00000000000 --- a/Master/tlpkg/tlgs/lib/ps2epsi.ps +++ /dev/null @@ -1,250 +0,0 @@ -% Copyright (C) 1990, 2000 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: ps2epsi.ps 8491 2008-01-18 06:17:02Z alexcher $
-% Convert an arbitrary PostScript file to an EPSI file.
-%
-% Please do not contact these users if you have questions. They no longer
-% have the time, interest, or current expertise to keep this code working.
-% If you find bugs, please send proposed fixes to bug-gs@ghostscript.com.
-%
-% Bug fix 2002-04-20 by rayjj: Bounding box was incorrect since it depended
-% on the dither pattern and gray shade at the boundary. Changed to use
-% 8-bit grayscale preview image to allow correct bounding box (at the
-% expense of a 8x larger preview image). Also moved .setsafe until after
-% the device and file operations are complete (but still before the input
-% file is processed.
-% Bug fix 2000-04-11 by lpd: if a font didn't have a FontName (which is the
-% case for bitmap fonts produced by recent versions of dvips), setfont
-% caused an error.
-% Bug fix 8/21/99 by lpd: many of the margin and width computations were
-% wrong (off by 1). The code only "worked" because the bugs were
-% (mostly) in conservative directions.
-% Modified 3/17/98 by lpd to make it possible to run this file without
-% running the ps2epsi script first, for debugging.
-% Bug fix 9/29/97 by lpd <ghost@aladdin.com>: if the page size wasn't an
-% exact multiple of 8 bits, an incorrect bounding box (or a rangecheck
-% error) could occur.
-% Patched 7/26/95 by
-% Greg P. Kochanski <gpk@bell-labs.com>
-% to add many new DSC comments and make the comments conforming.
-% Original version contributed by
-% George Cameron <george@bio-medical-physics.aberdeen.ac.uk>
-%
-
-% Initialize, and redefine copypage and showpage.
-
-% ps2edict is normally defined in the pre-loaded code created by the
-% ps2epsi script.
-/ps2edict where { pop } { /ps2edict 25 dict def } ifelse
-ps2edict begin
-
- % The main procedure
- /ps2epsi
- { % Open the file
- outfile (w) file /epsifile exch def
- % Get the device parameters
- currentdevice getdeviceprops .dicttomark
- /HWSize get aload pop
- /devheight exch def
- /devwidth exch def
- matrix defaultmatrix
- /devmatrix exch def
- % Make a corresponding 8-bit deep memory device
- devmatrix devwidth devheight
- 256 string 0 1 255 { 1 index exch dup 255 exch sub put } for
- makeimagedevice
- /arraydevice exch def
- arraydevice
- % Turn on anti-aliasing
- mark /TextAlphaBits 4 /GraphicsAlphaBits 4 6 -1 roll
- putdeviceprops
- setdevice % (does an erasepage)
- /rowwidth devwidth def
- /row rowwidth string def
- /zerorow rowwidth string def % all zero
- % Replace the definition of showpage
- userdict /showpage { ps2edict begin epsipage end } bind put
- userdict /setfont { ps2edict begin epsisetfont end } bind put
- userdict /setpagedevice /pop load put
- //systemdict /.setsafe known { .setsafe } if
- } bind def
-
- /epsifontdict 100 dict def
-
- /epsisetfont
- {
- % code here keeps a list of font names in dictionary epsifontdict
- /tmpfont exch def
- tmpfont /FontName known {
- /tmpfontname tmpfont /FontName get def
- epsifontdict tmpfontname known not { epsifontdict tmpfontname 0 put } if
- epsifontdict tmpfontname 2 copy get 1 add put
- } if
- tmpfont setfont
- } bind def
-
-% Get a scan line from the memory device, zeroing any bits beyond
-% the device width.
-/getscanline { % <device> <y> <string> getscanline <string>
- dup 4 1 roll copyscanlines pop
- 16#ff00 devwidth 7 and neg bitshift 255 and
- dup 0 ne {
- 1 index dup length 1 sub 2 copy get 4 -1 roll and put
- } {
- pop
- } ifelse
-} bind def
-
-/margintest { % <y-start> <step> <y-limit> margintest <y-non-blank>
- % <y-start> <step> <y-limit> margintest -
- { dup arraydevice exch row getscanline
- zerorow ne { exit } if pop
- } for
-} bind def
-
-
- /epsiNameStr 200 string def
- /epsiNpages 0 def
- /epsiNpageStr 20 string def
- /epsipage
- {
- /epsiNpages epsiNpages 1 add def
- /loopcount devheight 1 sub def
-
- % Find top margin -- minimum Y of non-blank scan line.
- -1 0 1 loopcount margintest
- dup -1 eq { (blank page!!\n) print quit }{ exch pop } ifelse
- /tm exch def
-
- % Find bottom margin -- maximum Y of non-blank scan line.
- loopcount -1 0 margintest
- /bm exch def
-
- % Initialise limit variables
- /loopcount rowwidth 1 sub def
- /lm loopcount def
- /rm 0 def
-
- % Find left and right boundaries of image
- tm 1 bm
- { % Get more data
- arraydevice exch row getscanline pop
- % Scan from left to find first non-zero element
- % We save first the element, then the index
- -1 0 1 loopcount
- { dup row exch get 0 ne { exch pop exit }{ pop } ifelse
- } for
- % If we found -1, row is blank ..
- dup -1 ne
- { % Find the leftmost index
- dup lm lt
- % If the new index is less, we save index and element
- { /lm exch def } { pop } ifelse
- % Now find the rightmost index
- loopcount -1 0
- { dup row exch get 0 ne { exit }{ pop } ifelse
- } for
- dup rm gt
- % If the new index is greater, we save index and element
- { /rm exch def } { pop } ifelse
- } if
- } for
-
- % Calculate the bounding box values.
- % Note that these must be corrected to produce closed-open intervals.
- /llx lm def
- /lly devheight bm sub 1 sub def
- /urx rm 1 add def
- /ury devheight tm sub def
-
- % Write out the magic string and bounding box information
- epsifile (%!PS-Adobe-2.0 EPSF-1.2\n) writestring
- /epsititle where { pop epsifile epsititle writestring } if
- /epsicreator where { pop epsifile epsicreator writestring } if
- /epsicrdt where { pop epsifile epsicrdt writestring } if
- /epsifor where { pop epsifile epsifor writestring } if
- epsifile flushfile
-
- % Write out the page count:
- epsifile (%%Pages: ) writestring
- epsifile epsiNpages epsiNpageStr cvs writestring
- epsifile (\n) writestring
- epsifile flushfile
-
- % Write out the list of used fonts:
- epsifile (%%DocumentFonts:) writestring
- epsifontdict {
- epsifile ( ) writestring
- pop epsiNameStr cvs epsifile exch writestring
- } forall
- epsifile (\n) writestring
- epsifile flushfile
-
- epsifile (%%BoundingBox: ) writestring
- epsifile llx write==only epsifile ( ) writestring
- epsifile lly write==only epsifile ( ) writestring
- epsifile urx write==only epsifile ( ) writestring
- epsifile ury write==
-
- % Define character and bit widths for the output line buffer:
- /cwidth rm lm sub 1 add def
- /out cwidth string def
-
- epsifile (%%EndComments\n\n) writestring
- epsifile (%%BeginProlog\n) writestring
- epsifile (%%BeginPreview: ) writestring
- epsifile cwidth write==only epsifile ( ) writestring
- epsifile bm tm sub 1 add write==only epsifile ( 8 ) writestring
- epsifile bm tm sub 1 add
- cwidth 39 add 40 idiv mul write==
- epsifile flushfile
-
- gsave
-
- tm 1 bm
- { % Get a scan line interval from the array device
- arraydevice exch row copyscanlines lm cwidth getinterval
- % Write out the hex data as 40 bytes per line (82 chars)
- 0 40 cwidth
- { epsifile (% ) writestring
- epsifile exch 2 index exch
- dup cwidth exch sub 40 .min getinterval writehexstring
- epsifile (\n) writestring
- } for
- pop
- } for
-
- epsifile (%%EndImage\n) writestring
- epsifile (%%EndPreview\n) writestring
- epsifile flushfile
- grestore
- erasepage initgraphics
-
- DonePage 0 1 put
- } bind def
-
-
-(outfile) getenv
- { /outfile exch def
- ps2epsi
-
- /DonePage 1 string def
- (%stdin) (r) file cvx execute0
- DonePage 0 get 0 eq { showpage } if
- } if
-
-end
-quit
diff --git a/Master/tlpkg/tlgs/lib/quit.ps b/Master/tlpkg/tlgs/lib/quit.ps deleted file mode 100644 index eb5f288470a..00000000000 --- a/Master/tlpkg/tlgs/lib/quit.ps +++ /dev/null @@ -1 +0,0 @@ -quit
diff --git a/Master/tlpkg/tlgs/lib/rinkj-2200-setup b/Master/tlpkg/tlgs/lib/rinkj-2200-setup deleted file mode 100644 index d3d7073a572..00000000000 --- a/Master/tlpkg/tlgs/lib/rinkj-2200-setup +++ /dev/null @@ -1,222 +0,0 @@ -Manufacturer: EPSON
-Model: Stylus Photo 2200
-Resolution: 1440x720
-Dither: 2
-Aspect: 2
-Microdot: 16
-Unidirectional: 0
-AddLut: K
-23
-0 0
-0.041667 0.072936
-0.083333 0.144825
-0.125000 0.193066
-0.166667 0.249716
-0.208333 0.302334
-0.250000 0.342984
-0.291667 0.386044
-0.333333 0.425084
-0.375000 0.458522
-0.416667 0.520504
-0.458333 0.577275
-0.500000 0.605041
-0.541667 0.652086
-0.583333 0.679372
-0.625000 0.703745
-0.666667 0.727044
-0.708333 0.750855
-0.750000 0.765267
-0.791667 0.920270
-0.833333 0.992157
-0.875000 0.996076
-0.916667 1.000000
-AddLut: K
-4
-0 0
-0 0.5
-0.15 0.75
-0.65 1
-AddLut: k
-23
-0 0
-0.041667 0.072936
-0.083333 0.144825
-0.125000 0.193066
-0.166667 0.249716
-0.208333 0.302334
-0.250000 0.342984
-0.291667 0.386044
-0.333333 0.425084
-0.375000 0.458522
-0.416667 0.520504
-0.458333 0.577275
-0.500000 0.605041
-0.541667 0.652086
-0.583333 0.679372
-0.625000 0.703745
-0.666667 0.727044
-0.708333 0.750855
-0.750000 0.765267
-0.791667 0.920270
-0.833333 0.992157
-0.875000 0.996076
-0.916667 1.000000
-AddLut: k
-5
-0 0
-0.2 0.375
-0.35 0.5
-0.1 0.75
-0 1
-AddLut: C
-22
-0 0
-0.041667 0.088977
-0.083333 0.167638
-0.125000 0.235395
-0.166667 0.296362
-0.208333 0.359009
-0.250000 0.407284
-0.291667 0.453199
-0.333333 0.493685
-0.375000 0.528351
-0.416667 0.592415
-0.458333 0.651623
-0.500000 0.681794
-0.541667 0.742354
-0.583333 0.784790
-0.625000 0.816796
-0.666667 0.850265
-0.708333 0.873510
-0.750000 0.884950
-0.791667 0.966983
-0.833333 0.998659
-0.875000 1.000000
-AddLut: C
-4
-0 0
-0 0.5
-0.15 0.75
-0.65 1
-AddLut: c
-22
-0 0
-0.041667 0.088977
-0.083333 0.167638
-0.125000 0.235395
-0.166667 0.296362
-0.208333 0.359009
-0.250000 0.407284
-0.291667 0.453199
-0.333333 0.493685
-0.375000 0.528351
-0.416667 0.592415
-0.458333 0.651623
-0.500000 0.681794
-0.541667 0.742354
-0.583333 0.784790
-0.625000 0.816796
-0.666667 0.850265
-0.708333 0.873510
-0.750000 0.884950
-0.791667 0.966983
-0.833333 0.998659
-0.875000 1.000000
-AddLut: c
-5
-0 0
-0.2 0.375
-0.35 0.5
-0.1 0.75
-0 1
-AddLut: M
-23
-0 0
-0.041667 0.066179
-0.083333 0.127506
-0.125000 0.171801
-0.166667 0.217173
-0.208333 0.263159
-0.250000 0.299030
-0.291667 0.335471
-0.333333 0.365411
-0.375000 0.389305
-0.416667 0.439855
-0.458333 0.485691
-0.500000 0.513796
-0.541667 0.597812
-0.583333 0.657433
-0.625000 0.706738
-0.666667 0.755192
-0.708333 0.795656
-0.750000 0.826408
-0.791667 0.948840
-0.833333 0.998498
-0.875000 0.999740
-0.916667 1.000000
-AddLut: M
-4
-0 0
-0 0.5
-0.15 0.75
-0.65 1
-AddLut: m
-23
-0 0
-0.041667 0.066179
-0.083333 0.127506
-0.125000 0.171801
-0.166667 0.217173
-0.208333 0.263159
-0.250000 0.299030
-0.291667 0.335471
-0.333333 0.365411
-0.375000 0.389305
-0.416667 0.439855
-0.458333 0.485691
-0.500000 0.513796
-0.541667 0.597812
-0.583333 0.657433
-0.625000 0.706738
-0.666667 0.755192
-0.708333 0.795656
-0.750000 0.826408
-0.791667 0.948840
-0.833333 0.998498
-0.875000 0.999740
-0.916667 1.000000
-AddLut: m
-5
-0 0
-0.2 0.375
-0.35 0.5
-0.1 0.75
-0 1
-AddLut: Y
-21
-0 0
-0.041667 0.082679
-0.083333 0.173423
-0.125000 0.251594
-0.166667 0.336706
-0.208333 0.407062
-0.250000 0.459290
-0.291667 0.522042
-0.333333 0.577070
-0.375000 0.636163
-0.416667 0.683434
-0.458333 0.726899
-0.500000 0.761784
-0.541667 0.789214
-0.583333 0.810356
-0.625000 0.852995
-0.666667 0.869116
-0.708333 0.900888
-0.750000 0.925593
-0.791667 0.989315
-0.833333 1.000000
-AddLut: Y
-3
-0 0
-0.2 0.5
-0.65 1
diff --git a/Master/tlpkg/tlgs/lib/rollconv.ps b/Master/tlpkg/tlgs/lib/rollconv.ps deleted file mode 100644 index 2c1243444be..00000000000 --- a/Master/tlpkg/tlgs/lib/rollconv.ps +++ /dev/null @@ -1,372 +0,0 @@ -%!
-% Copyright (C) 1995, 1996 Aladdin Enterprises. All rights reserved.
-
-% $Id: rollconv.ps 6300 2005-12-28 19:56:24Z giles $
-% Utility program for converting Japanese fonts produced by Macromedia's
-% Rollup program to Type 0 fonts suitable for use with Ghostscript.
-%
-% Rollup produces the following files, where xxx is the font name:
-% xxx-H, xxx-SA, xxx-SB, xxx-SK, xxx-SR, xxx-UG
-% JIS83-1_COD
-% JIS83-1_CSA
-% The _COD and _CSA files are large files containing the actual
-% character outline data; they may theoretically be shared between
-% multiple fonts.
-%
-% rollconv.ps converts the above to files named:
-% fff.ps
-% fff.COD
-% fff.CSA
-% fff.CSR
-% where fff is a font file name provided by the user at conversion time.
-% The fff.ps file is the actual font file to be loaded with `run'
-% or placed in a Fontmap or a directory named by [GS_]FONTPATH;
-% the other two files must be present at runtime in a directory that is
-% on Ghostscript's search path (-I, GS_LIB, GS_LIB_DEFAULT).
-%
-% The normal way to invoke this program is
-% gsnd -- rollconv.ps xxx fff InDir CDir OutDir
-% (assuming that gsnd is an alias for gs -dNODISPLAY), where:
-% xxx is the font name;
-% fff is the base part of the output file name;
-% InDir is the name of the directory containing the xxx-* input files;
-% CDir is the name of the directory containing the _COD and _CSA
-% input files (typically the same as InDir);
-% OutDir is the name of the directory where the output should be written
-% (OutDir must already exist).
-% For example:
-% gsnd -- rollconv.ps HGGothicBPRO gothic /gs/k/rufonts/Gothic \
-% /gs/k/rufonts/Gothic /gs/k/gsfonts
-% To suppress output messages, you may insert -q:
-% gsnd -q -- rollconv.ps ...
-%
-% This program assumes that the files have been FTP'ed from a Macintosh and
-% therefore have 128 bytes of garbage at the beginning. If you have
-% transferred them in some manner that avoids this, change true to false
-% in the following line.
-/fromMac true def
-% The FontName of the converted font is xxx-83pv-RKSJ-H. In order to
-% use a converted font with Ghostscript, you may either load it explicitly
-% at run time, e.g.,
-% (gothic.ps) run
-% or you may add an entry to the Fontmap file, in the form:
-% /HGGothicBPRO-83pv-RKSJ-H (gothic.ps) ;
-% which will allow the font to be loaded automatically. After
-% loading the font, by either method, you can select it in the usual way:
-% /HGGothicBPRO-83pv-RKSJ-H findfont 36 scalefont setfont
-% or
-% /HGGothicBPRO-83pv-RKSJ-H 36 selectfont
-
-
-/macrfile % <filename> macrfile <file>
- { (r) file
- fromMac
- { % Get rid of the initial Mac garbage (128 characters).
- % The garbage at the end is unpredictable,
- % so we'll just have to hope that it's all nulls.
- dup =string 0 128 getinterval readstring pop pop
- }
- if
- } bind def
-
-/convert % <FName> <OutBase> <InDir> <CDir> <OutDir> convert -
- { /OutDir exch def
- /CDir exch def
- /InDir exch def
- /OutBase exch def
- /FName exch def
-
- /inprefix InDir (/) concatstrings FName concatstrings (-) concatstrings def
- /inh inprefix (H) concatstrings def
-
- % Open the output file.
-
-/OutDot OutDir (/) concatstrings OutBase concatstrings (.) concatstrings def
-/outname OutDot (ps) concatstrings def
-QUIET not { (Writing ) print outname = flush } if
-/cdfromstr (\(pgfonts/) FName concatstrings (-JIS83-1_) concatstrings def
-/cdstr (\() OutBase concatstrings (.) concatstrings def
-/out outname (w) file def
-/buffer 65000 string def
-
- % Copy the initial comments from the input file.
-
-inh macrfile
- { dup =string readline pop
- out 1 index writestring out (\n) writestring
- (%%EndComments) eq { exit } if
- }
-loop
-
- % Write out our preamble.
-
-out (
-currentpacking true setpacking
-userdict /AltsysCFD3 known { (%END) .skipeof } if
-userdict /AltsysCFD3 25 dict dup begin
-/beint { 0 exch { exch 8 bitshift add } forall } bind def
-/rfile { findlibfile { exch pop } { (r) file } ifelse } bind def
-/str 500 string def
-/AltRO { } def
-/BuildCh % <font> <ccode> <bias> BuildCh -
- { /bias exch def /ccode exch def begin % font
- ccode dup 255 and dup bias lt exch 252 gt or { pop 127 } if
- dup -8 bitshift -67 mul add % subfonts have 189 chars, not 256
- bias sub buildch1
- } bind def
-/BuildChr % <font> <ccode> BuildChr -
- { /ccode exch def begin % font
- ccode buildch1
- } bind def
-/buildch1
- { 6 mul PGOffsets add
- FileNames 0 get rfile dup dup 4 -1 roll setfileposition
- (xxxxxx) readstring pop exch closefile
- dup 1 3 getinterval beint % COD offset
- exch 4 2 getinterval beint % length
- dup 0 eq
- { pop pop currentdict end
- 1000 0 0 0 1 1 0 -1000 500 1000 setcachedevice2
- }
- { dup str length gt { /str 1 index string store } if
- FileNames 1 get rfile dup dup % offset length file file file
- 5 -1 roll setfileposition % length file file
- str 0 5 -1 roll getinterval readstring pop pop closefile
- currentdict end ccode str 1183615869 internaldict /CCRun get exec
- }
- ifelse
- } bind def
-/privates 100 dict def
-/BuildPr % <stdhw> <stdvw> BuildPr <dict>
- { 2 copy 1000 mul add privates 1 index known
- { privates exch get 3 1 roll pop pop
- }
- { 7 dict begin
- /MinFeature{16 16}executeonly def
- /BlueValues BlueValues def
- /StdVW 3 -1 roll 1 array astore def
- /StdHW 3 -1 roll 1 array astore def
- /password 5839 def
- /LanguageGroup 1 def
- /Subrs Subrs def
- currentdict readonly end
- privates 2 index 2 index put exch pop
- }
- ifelse
- } bind def
-/FullEncoding
- systemdict { pop } forall
- systemdict length 512 sub 1 255 { (x) dup 0 4 -1 roll put cvn } for
-768 packedarray def
-/BlueValues[-250 -250 1100 1100]readonly def
-/BuildChar{AltsysCFD3 begin 64 BuildCh end}bind def
-/CharStrings 1 dict
-dup /.notdef (¿1pyÊ8å) noaccess put
-readonly def
-/CDevProc
- { pop pop pop pop 0 exch -1000 exch 2 div currentfont /FontBBox get 3 get
- } bind def
-/FontMatrix[0.001 0.0 0.0 0.001 0.0 0.0]readonly def
-/Subrs [
-(¿1p|=-“D\âR) noaccess
-(¿1py¼öUz) noaccess
-(¿1py½Äži) noaccess
-(¿1pù) noaccess
-(¿1p|35r·I) noaccess
-] noaccess def
-end put
-%END
-) writestring
-
- % Locate and copy the definition of NotDefFont.
-
-out (
-FontDirectory /NotDefFont known { (%END) .skipeof } if
-) writestring
- { dup =string readline pop
- dup (/NotDefFont) eq { exit } if pop
- }
-loop out exch writestring out (\n) writestring
- { dup =string readline pop
- (definefont) search { pop pop pop exit } if
- out exch writestring out (\n) writestring
- }
-loop out (definefont pop
-%END
-) writestring
-
- % Copy the definitions of the subfonts, moving the
- % CharStrings of the Roman supplement to an external file.
- % Stack for pattern procedures: infile line
-
-/CSRName OutDot (CSR) concatstrings def
-/csr CSRName (w) file def
-QUIET not { (Writing ) print CSRName = flush } if
-
-/encoding 256 array def
-
-/patterns [
- % Patterns specific to the Roman supplement, in which
- % the outlines are in an eexec section.
- { (/Encoding 256 array) {
- pop out (/Encoding ) writestring
- { dup buffer readline pop
- dup (dup) search { exit } if pop pop
- }
- loop
- { % Stack: infile dupline postdup (dup) predup
- pop pop exch pop
- % The top element of the stack is a string beginning with
- % an index and value to put into the Encoding.
- token pop exch token pop exch pop encoding 3 1 roll put
- dup buffer readline pop
- dup (dup) search not { pop exit } if
- }
- loop
- out encoding cvx write== out ( cvlit ) writestring
- out exch writestring out (\n) writestring
- } }
- { (/FontType 1 def) {
- pop out (/FontType 4 def\n) writestring
- out (/BuildChar{AltsysCFD3 begin BuildChr end}bind def\n) writestring
- out (/FileNames[) writestring
- 2 { out OutBase (.CSR) concatstrings write==only } repeat
- out (]def\n) writestring
- } }
- { (currentfile eexec) {
- pop out (systemdict begin\n) writestring
- dup //.eexec_param_dict /eexecDecode filter
- } }
- { (dup/CharStrings ) {
- % Copy the individual CharStrings to the CSR file,
- % recording the lengths and offsets.
- pop out (dup/CharStrings AltsysCFD3 /CharStrings get put\n) writestring
- /offsets 256 dict def
- { dup token pop % char name
- dup dup type /nametype eq exch xcheck not and not { pop exit } if
- 1 index token pop % length of binary data
- 2 index token pop pop % skip RD
- 2 index buffer 0 3 index getinterval readstring pop % charstring
- offsets 3 index csr fileposition 16 bitshift 4 index add put
- csr exch writestring pop pop
- dup buffer readline pop pop % skip ND
- }
- loop
- % We skipped the 'end'; skip the 'readonly put' as well.
- 2 { dup token pop pop } repeat
- out (dup/PGOffsets ) writestring
- out csr fileposition write=only
- out ( put\n) writestring
- encoding
- { offsets exch .knownget not { 0 } if
- 2 { csr 0 write } repeat
- 4 { dup -24 bitshift csr exch write 8 bitshift } repeat pop
- }
- forall
- } }
- { (/OtherSubrs[) {
- pop
- { dup buffer readline pop
- (]noaccess def) search { pop pop pop exit } if pop
- }
- loop
- } }
- { (/Subrs 5 array) {
- pop out (/Subrs AltsysCFD3 /Subrs get def\n) writestring
- 6 { dup buffer readline pop pop } repeat
- } }
- { (currentfile closefile) {
- pop out (end % systemdict\n) writestring
- closefile
- } }
- % Patterns for other supplements.
- { (pgfonts/) {
- { cdfromstr search not { exit } if
- out exch writestring pop out cdstr writestring
- }
- loop out exch writestring out (\n) writestring
- } }
- { (/BuildChar{AltsysCFD3 begin 64 BuildCh end}bind def) {
- pop out (\t/BuildChar AltsysCFD3 /BuildChar get def\n) writestring
- } }
- { (/CDevProc{pop pop pop pop 0 exch -1000 exch 2 div ) {
- pop out (\t/CDevProc AltsysCFD3 /CDevProc get def\n) writestring
- } }
- { (/CharStrings 1 dict dup begin) {
- pop out (\t/CharStrings AltsysCFD3 /CharStrings get def\n) writestring
- 2 { dup buffer readline pop pop } repeat
- } }
- { (/FontMatrix[0.001 0.0 0.0 0.001 0.0 0.0]def) {
- pop out (\t/FontMatrix AltsysCFD3 /FontMatrix get def\n) writestring
- } }
- { (/Private 14 dict dup begin) {
- pop out (\t/Private) writestring
- { dup buffer readline pop
- (end def) search { pop pop pop exit } if
- (/Std) search
- { pop pop dup length 3 sub 3 exch getinterval
- (]) search pop out ( ) writestring out exch writestring pop
- }
- if pop
- }
- loop out ( AltsysCFD3 begin BuildPr end def\n) writestring
- } }
- { (UniqueID) { pop } }
- { () {
- out exch writestring out (\n) writestring
- } }
-] def
-[ (SR) (SA) (SK) (SB) (UG) ]
- { 0 1 255 { encoding exch /.notdef put } for
- inprefix exch concatstrings macrfile
- { dup buffer readline not { pop exit } if
- /patterns load
- { 2 copy 0 get search { pop pop pop 1 get exec exit } if pop pop }
- forall
- }
- loop closefile
- }
-forall
-csr closefile
-
- % Copy the definition of the root font.
-
-dup buffer readstring pop out exch writestring closefile
-out (
-setpacking
-) writestring
-out closefile
-
- % Remove the Mac garbage from the outline files.
-
-[ (COD) (CSA) ]
- { CDir (/) concatstrings (JIS83-1_) concatstrings
- 1 index concatstrings macrfile
- exch OutDot exch concatstrings
- QUIET not { (Writing ) print dup = flush } if
- (w) file
- % Stack: infile outfile
- { 1 index buffer readstring exch
- % Stack: infile outfile noteof substring
- 2 index exch writestring not { exit } if
- }
- loop closefile closefile
- }
-forall
-
- } bind def
-
-% If the program was invoked from the command line, run it now.
-[ shellarguments
- { counttomark 5 eq
- { convert
- QUIET not { (Done.\n) print flush } if
- }
- { cleartomark
- (Usage: gsnd -- rollconv.ps FName OutBase InDir CDir OutDir\n) print
- ( e.g.: gsnd -- rollconv.ps HGMinchoE mincho HGfonts/Mincho HGfonts/Mincho HGfonts/gs\n) print flush
- mark
- }
- ifelse
- }
-if pop
diff --git a/Master/tlpkg/tlgs/lib/showchar.ps b/Master/tlpkg/tlgs/lib/showchar.ps deleted file mode 100644 index d6ef66c6ba0..00000000000 --- a/Master/tlpkg/tlgs/lib/showchar.ps +++ /dev/null @@ -1,93 +0,0 @@ -% Copyright (C) 1993, 1994, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: showchar.ps 6300 2005-12-28 19:56:24Z giles $
-% showchar.ps
-% Show the outline and rasterized forms of a character.
-
-/F where { pop } { /F /Times-Roman def } ifelse
-/P where { pop } { /P 16 def } ifelse
-/Rx where { pop } { /Rx 100 def } ifelse
-/Ry where { pop } { /Ry 100 def } ifelse
-/Cs where { pop } { /Cs (M) def } ifelse
-/Pr where { pop } { /Pr false def } ifelse
-/Delay where { pop } { /Delay 0 def } ifelse
-
-0 setgray
-(markpath.ps) runlibfile
-(markhint.ps) runlibfile
-/mmx [1 0 0 1 0 0] def
-/getpath % - getpath <pathproc>
- { [
- { /moveto cvx } { /lineto cvx } { /curveto cvx } { /closepath cvx }
- pathforall
- ] cvx
- } def
-/bitselectfont % <fontname> <scale> bitselectfont -
- { exch findfont exch scalefont setfont
- % Compute the bounding box in device coordinates.
- gsave [Rx 72 div 0 0 Ry 72 div 0 0] setmatrix
- currentfont /FontMatrix get concat
- currentfont /FontBBox get aload pop
- transform ceiling cvi /ury exch def ceiling cvi /urx exch def
- transform floor cvi /lly exch def floor cvi /llx exch def
- /bbx urx llx sub def /bby ury lly sub def
- grestore
- } def
-/bitshow % <string> bitshow -
- { /S exch def gsave
- /W bbx 8 add 7 or 1 add def
- /H bby 8 add def
- /buf W 8 idiv string def
- /M [Rx 72 div 0 0 Ry -72 div 4 llx sub H 4 sub] def
- M W H <ff 00> makeimagedevice
- /dev exch def
- gsave dev setdevice
- newpath 0 lly idtransform moveto
- 0 setgray
- gsave
- /hpath S false charpath getpath def
- grestore
- S show grestore
- 20 20 translate
- 50000 Rx Ry .max P mul div dup scale
- 0.7 setgray
- 0 W H true M
- { dup 1 add exch dev exch buf copyscanlines
- } imagemask pop
- 0 setlinewidth
- gsave 0.5 1 0.5 setrgbcolor hpath exec mmx markpath grestore
- 0 0.5 1 setrgbcolor hpath exec stroke
- % Show the hints for Type 1 fonts also.
- currentfont /FontType get 1 eq
- { gsave 1 0 0 setrgbcolor
- 0 lly M idtransform translate
- currentfont /FontMatrix get
- dup Pr markfonthints
- currentfont /Encoding get S 0 get get exch Pr markcharhints
- grestore
- }
- if
- } def
-F P bitselectfont
-/S1 1 string def
-Cs
- { /C exch def
- currentfont /Encoding get C get /.notdef ne
- { save S1 0 C put S1 bitshow
- showpage restore
- } if
- } forall
-quit
diff --git a/Master/tlpkg/tlgs/lib/showpage.ps b/Master/tlpkg/tlgs/lib/showpage.ps deleted file mode 100644 index 0a6ae9a7e1f..00000000000 --- a/Master/tlpkg/tlgs/lib/showpage.ps +++ /dev/null @@ -1 +0,0 @@ -showpage
diff --git a/Master/tlpkg/tlgs/lib/stcinfo.ps b/Master/tlpkg/tlgs/lib/stcinfo.ps deleted file mode 100644 index 8d7135935a5..00000000000 --- a/Master/tlpkg/tlgs/lib/stcinfo.ps +++ /dev/null @@ -1,799 +0,0 @@ -% Copyright (C) 1995 Aladdin Enterprises. All rights reserved
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: stcinfo.ps 6300 2005-12-28 19:56:24Z giles $
-% stcinfo.ps
-% Epson Stylus-Color Printer-Driver
-
-% The purpose of this file is to print & show Parameters of the
-% stcolor-driver. If not run on ghostscript/stcolor, it prints
-% something like a color-chart.
-
-% use either existing STCinfo-dictionary, retrieve new one or create dummy
-
-statusdict begin product end
-dup (Ghostscript) eq 1 index (Aladdin Ghostscript) eq or
-exch (AFPL Ghostscript) eq or{
-
- currentdevice getdeviceprops .dicttomark
- dup /Name get (stcolor) eq /STCi_onstc exch def
- /STCinfo where {/STCinfo get exch pop} if
- /STCinfo exch def
-
-}{
-
- /STCinfo 10 dict def
- STCinfo begin /Name (unknown) def end
- /STCi_onstc false def
-
-}ifelse
-
-% Next Block are procedures to generate the color-triangles.
-% you may wish to separate them, just look ahead for the name
-% given in the next line to achieve that.
-% Begin: colortri_procedures
-
-% Plot the CIE-XY-triangle (or something like that)
-
-% /colortri_mat Conversion matrix RGB -> XYZ
-% /colortri_bg procedure, that takes X/Y-Values and delivers the
-% "background color" as RGB-Values, default is:
-% {pop pop 0.85 dup dup}
-
-% The default matrix was taken from:
-% Color spaces FAQ - David Bourgin
-% Date: 15/6/94 (items 5.3 and 6 updated)
-% Last update: 29/6/94
-
- /colortri_mat [ % RGB -> CIE XYZitu601-1 (D65)
- 0.4306 0.3415 0.1784
- 0.2220 0.7067 0.0713
- 0.0202 0.1295 0.9394
- ] def
-
- /colortri_bg {pop pop 0.85 dup dup} bind def
-
-
-% +---------------------------------------------------------------------+
-% | Besides from fixing bugs, nothing should be changed below this line |
-% +---------------------------------------------------------------------+
-
-
-% Arbitrary operation on a pair of vectors, *CHANGES* 1st.
-% invoke: Vaccu Vop op vop
- /vop {
- bind 0 1 3 index length 1 sub {
- 3 index 1 index get 3 index 2 index get 3 index exec 4 index 3 1 roll put
- } for pop pop
- } bind def
-
- /vsub { {sub} vop } bind def % subtract two vectors
- /vmul { {mul} vop } bind def % multiply two vectors
-
-% Compute sum of vectors elements
- /vsum {0.0 exch{add}forall} bind def
-
-
-% Sum up products of elements
- /veqn { [ 3 -1 roll {} forall ] exch vmul vsum } bind def
-
-% Find index of |maximum| in array
- /imax {
- dup 0 get abs 0 exch % array i v[i]
- 1 1 4 index length 1 sub {
- 3 index 1 index get abs dup 3 index gt {4 2 roll}if pop pop
- } for
- 3 -1 roll pop
- } bind def
-
-% Procedure to *CHANGE* RGB-Values into XYZ-Values
- /rgb2xyz {
- 0 3 6 { colortri_mat exch 3 getinterval 1 index veqn exch } for astore
- } bind def
-
-% Procedure to *CHANGE* transform rgb->xy
- /rgb2xy {
- rgb2xyz
- dup 0 get 1 index 1 get 2 index vsum % XYZ X Y sum
- dup 0 ne {
- exch 1 index div 3 1 roll div % XYZ y x
- 2 index exch 0 exch put % xYZ y
- 1 index exch 1 exch put % xyZ
- }{
- pop pop pop dup 0 0 put dup 0 1 put
- } ifelse
- 0 2 getinterval
- } bind def
-
-% So here we go with our procedure
-
-/colortri { %Usage: box #pixels
- save
- 1 index type /arraytype eq {exch 8}{3 1 roll} ifelse % Default scale
- /colortri_scale exch def
- /colortri_box exch def
-
-
-% Prepare some useful constants for xy -> RGB conversion
-
- /colsum [ % Array with column-sums
- 0 1 2{0 exch 3 1 index 6 add{colortri_mat exch get add}for}for
- ] def
-
- /Xrow colortri_mat 0 3 getinterval def % two rows from colortri_mat
- /Yrow colortri_mat 3 3 getinterval def
-
-% Avoid allocating new arrays
- /xcoeff 3 array def
- /ycoeff 3 array def
-
-% Procedure to derive RGB-Values form X,Y
- /xy2rgb{ aload pop
- dup dup dup ycoeff astore colsum vmul Yrow vsub imax
- 3 index dup dup xcoeff astore colsum vmul Xrow vsub imax
- 3 -1 roll 1 index 1 index gt{
- xcoeff ycoeff /xcoeff exch def /ycoeff exch def pop 3 -1 roll pop
- }{
- 3 1 roll pop pop
- } ifelse
- 1e-6 lt { % No Pivot ?
- pop colortri_bg xcoeff astore pop
- }{ % Have a Pivot
- dup ycoeff exch get neg
- 0 1 2 { dup ycoeff exch get 2 index div ycoeff 3 1 roll put} for
- pop ycoeff 1 index 0 put
-
- xcoeff 1 index get
- 0 1 2 {
- ycoeff 1 index get 2 index mul xcoeff 2 index get add
- xcoeff 3 1 roll put
- } for
- pop xcoeff 1 index 0 put
- xcoeff imax 1e-6 lt { % no Pivot ?
- pop pop colortri_bg xcoeff astore pop
- }{
- dup 2 index or 3 exch sub
- xcoeff 1 index get xcoeff 3 index get div neg
- xcoeff exch 3 index exch put
- xcoeff 1 index 1 put
- ycoeff exch get ycoeff 2 index get xcoeff 4 -1 roll get mul add
- xcoeff 3 1 roll put
- 0 1 2 {
- xcoeff exch get dup -0.0015 lt exch 1.0015 gt or {
- colortri_bg xcoeff astore dup exit
- } if
- } for
- pop pop xcoeff
- } ifelse
- } ifelse
- } bind def
-
-% Compute the displayed range
- [ 1 1 1 ] rgb2xy
- dup 0 get /colortri_x0 exch def /colortri_dx colortri_x0 def
- 1 get /colortri_y0 exch def /colortri_dy colortri_y0 def
- [[0 0 1][0 1 0][0 1 1][1 0 0][1 0 1][1 1 0]] {
- rgb2xy
- dup 0 get
- dup colortri_x0 lt {/colortri_x0 1 index def}if
- dup colortri_dx gt {/colortri_dx 1 index def}if
- pop 1 get
- dup colortri_y0 lt {/colortri_y0 1 index def}if
- dup colortri_dy gt {/colortri_dy 1 index def}if
- pop
- } forall
- colortri_dx colortri_x0 sub /colortri_dx exch def
- colortri_dy colortri_y0 sub /colortri_dy exch def
-%
-
-% determine the scale
- colortri_box 2 get colortri_box 0 get sub colortri_dx div % fx
- colortri_box 3 get colortri_box 1 get sub colortri_dy div % fx fy
- gt { % fy limits
- colortri_box 3 get colortri_box 1 get sub
- dup colortri_dx mul colortri_dy div exch
- }{ % fx limits
- colortri_box 2 get colortri_box 0 get sub
- dup colortri_dy mul colortri_dx div
- } ifelse
- dtransform abs colortri_scale div cvi /colortri_ny exch def
- abs colortri_scale div cvi /colortri_nx exch def
- colortri_nx colortri_scale mul colortri_ny colortri_scale mul
- idtransform abs exch abs exch
- colortri_box 0 get colortri_box 2 get 1 index sub 3 index sub 2 div add
- colortri_box 1 get colortri_box 3 get 1 index sub 3 index sub 2 div add
- transform .5 add cvi exch .5 add cvi exch itransform
- translate scale
-
-% String & indices
- /colortri_tmp colortri_nx 3 mul string def
- /colortri_dx colortri_dx colortri_nx 1 sub div def
- /colortri_dy colortri_dy colortri_ny 1 sub div def
- /colortri_xy [ colortri_x0 colortri_y0 ] def
- /colortri_ie colortri_tmp length 3 sub def
-
- colortri_nx colortri_ny 8 [ colortri_nx 0 0 colortri_ny 0 0 ]
- {
- colortri_xy 0 colortri_x0 put
- 0 3 colortri_ie {
- colortri_tmp exch % buf ir
- colortri_xy xy2rgb % buf ir rgb buf ib
- 2 index 2 index 2 add 2 index 2 get 255 mul cvi put
- 2 index 2 index 1 add 2 index 1 get 255 mul cvi put
- 0 get 255 mul cvi put
- colortri_xy dup 0 exch 0 get colortri_dx add put
- }for
- colortri_xy dup 1 exch 1 get colortri_dy add put
- colortri_tmp
- } bind
- false 3 colorimage
- restore
-} bind def
-
-% [ newpath clippath pathbbox ] colortri showpage % standalone usage
-
-% End: colortri_procedures
-
-% The next section is a group of procedures, that I for myself
-% do no more fully understand, but they do the Job.
-
-% Begin: stcinfo_procedures_1
-
-% fetch a parameter from the dictionary
-/STCiget { STCinfo exch get } bind def
-
-% action upon ProcessColorModel
-/STCimode {
- /ProcessColorModel STCiget dup
- /DeviceCMYK eq{pop 2}{/DeviceRGB eq{1}{0}ifelse}ifelse get exec
-} bind def
-
-% print given number of blanks
-/STCipspace {
- dup 0 gt{ 1 exch 1 exch { pop ( ) print}for }{ pop } ifelse
-} bind def
-
-% print right or left-justified text
-/STCiprint {
- dup 0 gt { dup 2 index length sub STCipspace } if
- 1 index print
- dup 0 lt { neg dup 2 index length sub STCipspace } if
- pop pop
-} bind def
-
-% floating-point to fixed-length-string conversion
-
-/STCicvs { % number -> string
-
-% Prepare the result
- 8 string dup 0 ( ) putinterval
- exch
-
-% Make it unsigned
- dup 0 lt {neg(-)}{( )}ifelse 0 get exch
-
- dup 1000 lt 1 index 0 eq 2 index 0.001 ge or and { % floating point
- (e+) 0
- }{ % engineering
- 0 {
- 1 index 1000.0 ge
- {3 add exch 1000 div exch}
- {1 index 1 lt {3 sub exch 1000 mul exch}{exit}ifelse}
- ifelse
- }loop
- dup 0 lt {neg(e-)}{(e+)}ifelse exch
- }ifelse
-
-% string sign num esig e
-
-% always up to three Integer Digits plus sign
- 2 index cvi 3 { % string sign num esig e int ind
- 1 index 10 div cvi dup 10 mul 3 index exch sub cvi
- (0123456789) exch get 8 index exch 3 index exch put
- 3 -2 roll 1 sub exch pop dup 0 eq 2 index 0 eq or {exit} if
- } loop exch pop % string sign num esig e ind
- 5 index exch 6 -1 roll put % string num esig e
-
-% print either fraction or exponent
- dup 0 eq { pop pop dup cvi sub % String fraction
-
- dup 0.0 ne { % Fraction present
- 0.0005 add 1 index 4 (.) putinterval
- 5 1 7 { % string frac ind
- exch 10 mul dup cvi exch 1 index sub % string ind ic nfrac
- exch (0123456789) exch get 3 -1 roll % string nfrac chr ind
- exch 3 index 3 1 roll put
- } for
- } if
- pop
-
- }{ 3 -1 roll pop % string esig e
-
- exch 2 index exch 4 exch putinterval
- 7 -1 6 { % string n i
- 1 index 10 div cvi dup 10 mul 3 index exch sub cvi % string n i n/10
- (0123456789) exch get 4 index exch 3 index exch put
- exch pop exch pop
- } for
- pop
- } ifelse
-
-} bind def
-
-% compute colorvalue-steps from transfer & coding
-/STCisteps { % xfer, coding => X-values, Y-Values
-% 2^nbits
- 2 /BitsPerComponent STCiget dup 11 gt { pop 11 } if exp cvi
-
-% X & Y - Arrays (stack: xv:4 yv:3 xfer:2 coding:1 2^ni:0)
- dup 1 add array 1 index array 5 2 roll
-
-% compute GS-Color-Value according to the coding-array
-
- 1 index null eq { % no coding present
-
- 0 1 2 index 1 sub {
- dup 6 index exch dup 4 index div put
- 4 index exch dup 3 index 1 sub div put
- } for
-
- }{ % coding-array given
-
- 1.0 1 index 1 sub div % y step
- 0 % current index
- 0 1 4 index 1 sub { % over indices
- dup 3 index mul
- {
- dup 3 index 1 add dup 8 index length ge {pop pop exit} if % i y
- 7 index exch get le {exit} if
- 2 index 1 add 3 1 roll 4 -1 roll pop
- } loop
- 5 index 3 index get sub
- 5 index 3 index 1 add get 6 index 4 index get sub div
- 2 index add 5 index length 1 sub div
- 2 copy exch dup 0 eq {
- 10 index exch 0.0 put pop
- }{
- dup 10 index exch 1 sub get 3 -1 roll add 2 div
- 10 index 3 1 roll put
- }ifelse
- 7 index 3 1 roll put
- } for % over indices
- pop pop
- } ifelse
- 4 index 1 index 1.0 put
-
-% Replace the raw y-values by those computed from the transfer-array
-
- 0 1 2 index 1 sub { % over indices, 2nd
- dup 5 index exch get
- dup 5 index length 1 sub mul cvi % -> iy
- 5 index 1 index get
- 1 index 1 add 7 index length lt {
- dup 7 index 3 index 1 add get exch sub
- 3 index 3 index 9 index length 1 sub div sub mul
- 7 index length 1 sub mul add
- } if
- exch pop exch pop 5 index 3 1 roll put
- } for % over indices, 2nd
-
- pop pop pop
-} bind def
-
-/STCibar { % Window X-Values proc => Window
- 0 1 3 index length 2 sub {
- dup 3 index exch get exch
- 1 add 3 index exch get
- dup 2 index add 2 div 3 index exec % Color to average
- 4 index 2 get 5 index 0 get sub exch 1 index mul 5 index 0 get add 3 1 roll
- mul 4 index 0 get add 4 index 3 get 5 index 1 get
- newpath
- 2 index 1 index moveto
- 3 index 1 index lineto
- 3 index 2 index lineto
- 2 index 2 index lineto
- closepath fill
- pop pop pop pop
- } for
- pop pop
- 0 setgray
- newpath
- dup 0 get 1 index 1 get moveto
- dup 2 get 1 index 1 get lineto
- dup 2 get 1 index 3 get lineto
- dup 0 get 1 index 3 get lineto
- closepath stroke
- pop
-} bind def
-
-% End: stcinfo_procedures_1
-
-% Begin: stcinfo_preparation
-
-% Compute used area from clippath
-
-/STCi_clip [
- newpath clippath pathbbox
- 2 sub 4 1 roll 2 sub 4 1 roll 2 add 4 1 roll 2 add 4 1 roll
-] def
-
-%
-% Perpare the texual messages, assume no stcolor if this fails
-%
-{
- /STCi_stopped % A Special Mark
-
-% Textual Parameters (an array of pairs of strings)
- /STCi_l1 0 def
- /STCi_l2 0 def
- /STCi_text [
-% Driver-Name & Version
- (Parameters of)
- /Name STCiget length /Version STCiget length add 1 add string
- dup 0 /Name STCiget putinterval dup /Name STCiget length (-)putinterval
- dup /Name STCiget length 1 add /Version STCiget putinterval
-% Dithering-Algorithm
- (Dithering)
- /Dithering STCiget
- [{( \(Monochrome\))}{( \(RGB\))}{( \(CMYK\))}] STCimode
- dup length 2 index length add string exch 1 index exch
- 3 index length exch putinterval dup 3 1 roll exch 0 exch putinterval
-% Flags for the algorithm
- (Flag4-0) 5 string
- dup 0 /Flag4 STCiget {(T)}{(f)} ifelse putinterval
- dup 1 /Flag3 STCiget {(T)}{(f)} ifelse putinterval
- dup 2 /Flag2 STCiget {(T)}{(f)} ifelse putinterval
- dup 3 /Flag1 STCiget {(T)}{(f)} ifelse putinterval
- dup 4 /Flag0 STCiget {(T)}{(f)} ifelse putinterval
-
-% Bits Per Pixel & Bits Per Component
- (BitsPerPixel) 10 string % (nn -> nxnn)
- /BitsPerPixel STCiget 1 index cvs length % string used
- dup 2 index exch ( -> ) putinterval 4 add dup 2 add exch 2 index exch
- [{(1x)}{(3x)}{(4x)}] STCimode putinterval % String used
- /BitsPerComponent STCiget 2 index 2 index 2 getinterval cvs length add
- 0 exch getinterval
-
- () ()
-% ColorAdjustMatrix
- (ColorAdjustMatrix)
- /ColorAdjustMatrix STCiget dup null eq {
- pop (default)
- }{
- { STCicvs } forall
- [{ % Monochrome
- 26 string
- dup 0 6 -1 roll putinterval dup 8 ( ) putinterval
- dup 9 5 -1 roll putinterval dup 17 ( ) putinterval
- dup 18 4 -1 roll putinterval
- }{ % RGB
- 26 string
- dup 0 12 -1 roll putinterval dup 8 ( ) putinterval
- dup 9 11 -1 roll putinterval dup 17 ( ) putinterval
- dup 18 10 -1 roll putinterval
-
- () 26 string
- dup 0 11 -1 roll putinterval dup 8 ( ) putinterval
- dup 9 10 -1 roll putinterval dup 17 ( ) putinterval
- dup 18 9 -1 roll putinterval
-
- () 26 string
- dup 0 10 -1 roll putinterval dup 8 ( ) putinterval
- dup 9 9 -1 roll putinterval dup 17 ( ) putinterval
- dup 18 8 -1 roll putinterval
- }{
- 35 string
- dup 0 19 -1 roll putinterval dup 8 ( ) putinterval
- dup 9 18 -1 roll putinterval dup 17 ( ) putinterval
- dup 18 17 -1 roll putinterval dup 26 ( ) putinterval
- dup 27 16 -1 roll putinterval
-
- () 35 string
- dup 0 17 -1 roll putinterval dup 8 ( ) putinterval
- dup 9 16 -1 roll putinterval dup 17 ( ) putinterval
- dup 18 15 -1 roll putinterval dup 26 ( ) putinterval
- dup 27 14 -1 roll putinterval
-
- () 35 string
- dup 0 15 -1 roll putinterval dup 8 ( ) putinterval
- dup 9 14 -1 roll putinterval dup 17 ( ) putinterval
- dup 18 13 -1 roll putinterval dup 26 ( ) putinterval
- dup 27 12 -1 roll putinterval
-
- () 35 string
- dup 0 13 -1 roll putinterval dup 8 ( ) putinterval
- dup 9 12 -1 roll putinterval dup 17 ( ) putinterval
- dup 18 11 -1 roll putinterval dup 26 ( ) putinterval
- dup 27 10 -1 roll putinterval
-
- }
- ] STCimode
- } ifelse
- () ()
-
-% Printer Model
- (Printer-Model) /Model STCiget
-
-% Resolution
- (Resolution) 15 string % (nnnnnxnnnnn DpI)
- /HWResolution STCiget 0 get cvi 1 index cvs length
- dup 2 index exch (x) putinterval 1 add dup 2 index exch 5 getinterval
- /HWResolution STCiget 1 get cvi exch cvs length add dup 2 index
- exch ( DpI) putinterval 4 add 0 exch getinterval
-
-% HWsize holds entire Page in Pixels,
-% .HWMargins is [left,bottom,right,top] in Points
- (Printed Area) 18 string % (nnnnnxnnnnn Pixel)
- /HWSize STCiget 0 get /.HWMargins STCiget dup 0 get exch 2 get add
- /HWResolution STCiget 0 get mul 72.0 div sub cvi 1 index cvs length
- dup 2 index exch (x) putinterval 1 add dup 2 index exch 5 getinterval
- /HWSize STCiget 1 get /.HWMargins STCiget dup 1 get exch 3 get add
- /HWResolution STCiget 1 get mul 72.0 div sub cvi exch cvs length add
- dup 2 index exch ( Pixel) putinterval 6 add 0 exch getinterval
-
- () ()
-% WeaveMode
- (Weave-Mode)
- /noWeave STCiget {
- (noWeave)
- }{
- /Microweave STCiget {(Microweave)}{(Softweave)}ifelse
- }ifelse
-% Unidirectional
- (Unidirectional) /Unidirectional STCiget {(ON)}{(off)} ifelse
-% Output coding
- (OutputCode) /OutputCode STCiget
-% number of heads
- (escp_Band) /escp_Band STCiget 3 string cvs
- (escp_Width) /escp_Width STCiget 5 string cvs
- (escp_Height) /escp_Height STCiget 5 string cvs
- (escp_Top) /escp_Top STCiget 5 string cvs
- (escp_Bottom) /escp_Bottom STCiget 5 string cvs
- ] def
-
-%
-% compute the Proper X & Y-Arrays
-%
- [{ % Monochrome
- /Ktransfer STCiget /Kcoding STCiget STCisteps
- /STCi_yv [ 3 -1 roll ] def
- /STCi_xv [ 3 -1 roll ] def
- /STCi_col [[0 0 0]] def
- /STCi_set [{1.0 exch sub setgray}] def
- }{ % RGB
- /Rtransfer STCiget /Rcoding STCiget STCisteps
- /Gtransfer STCiget /Gcoding STCiget STCisteps
- /Btransfer STCiget /Bcoding STCiget STCisteps
- exch 4 -1 roll 6 -1 roll exch 3 -1 roll
- /STCi_xv [ 5 2 roll ] def
- /STCi_yv [ 5 2 roll ] def
- /STCi_col [[1 0 0] [0 1 0] [0 0 1]] def
- /STCi_set [
- {1.0 exch sub 1 exch dup setrgbcolor}
- {1.0 exch sub dup 1 exch setrgbcolor}
- {1.0 exch sub dup 1 setrgbcolor}
- ] def
- }{ % CMYK
- /Ctransfer STCiget /Ccoding STCiget STCisteps
- /Mtransfer STCiget /Mcoding STCiget STCisteps exch 3 1 roll
- /Ytransfer STCiget /Ycoding STCiget STCisteps exch 4 1 roll
- /Ktransfer STCiget /Kcoding STCiget STCisteps exch 5 1 roll
- /STCi_yv [ 6 2 roll ] def
- /STCi_xv [ 6 2 roll ] def
- /STCi_col [[0 1 1] [1 0 1] [1.0 0.5 0.0] [0 0 0]] def
- /STCi_set [
- { 0 0 0 setcmykcolor }
- { 0 exch 0 0 setcmykcolor }
- { 0 exch 0 exch 0 setcmykcolor }
- { 0 exch 0 exch 0 exch setcmykcolor }
- ] def
- }
- ]STCimode
-
-} stopped
-
-{ {/STCi_stopped eq {exit}if}loop true}
-{ {/STCi_stopped eq {exit}if}loop false} ifelse
-
-% End: stcinfo_preparation
-
-% The Next section does the real job
-
-% Begin: stcinfo_execution
-{
- (%%[ stcinfo.ps: currentdevice is not supported -> colortri ]%%\n) print
- STCi_clip colortri % The default action
-
-}{
-%
-% Print the text
-%
- 0 2 STCi_text length 2 sub { dup 1 add exch
- STCi_text exch get length dup STCi_l1 gt{/STCi_l1 exch def}{pop}ifelse
- STCi_text exch get length dup STCi_l2 gt{/STCi_l2 exch def}{pop}ifelse
- } for
- /STCi_l2 STCi_l2 neg def
- 0 2 STCi_text length 2 sub {
- dup 1 add STCi_text exch get exch STCi_text exch get
- 1 index length 0 gt {
- dup STCi_l1 STCiprint length 0 gt {(: )}{( )}ifelse print print
- }{
- pop pop
- } ifelse
- (\n) print
- } for
-%
-% Deactivate a present ColorAdjust Matrix, if any
-%
- /ColorAdjustMatrix STCiget null ne STCi_onstc and {
- mark
- /ColorAdjustMatrix null
- currentdevice putdeviceprops pop
- } if
-%
-% "Show" the text
-%
- /Times-Roman findfont 10 scalefont setfont
- /STCi_l1 0 def
- 0 2 STCi_text length 2 sub {
- STCi_text exch get stringwidth pop dup STCi_l1 gt {
- /STCi_l1 exch def
- }{
- pop
- } ifelse
- } for
- STCi_l1 STCi_clip 0 get add /STCi_l1 exch def
-
- STCi_clip 3 get 12 sub
- 0 2 STCi_text length 2 sub {
- STCi_text exch get dup length 0 gt {
- dup stringwidth pop STCi_l1 exch sub 2 index moveto show
- }{
- pop
- } ifelse
- 12 sub
- } for
- pop
-
- /Courier findfont 10 scalefont setfont
- /STCi_l2 0 def
- 1 2 STCi_text length 1 sub {
- STCi_text exch get stringwidth pop dup STCi_l2 gt {
- /STCi_l2 exch def
- }{
- pop
- } ifelse
- } for
-
- STCi_clip 3 get 12 sub
- 1 2 STCi_text length 1 sub {
- STCi_text exch get dup length 0 gt {
- STCi_l1 12 add 2 index moveto show
- }{
- pop
- } ifelse
- 12 sub
- } for
- pop
-
-%
-% compute the space for the graph-window
-%
- STCi_l1 12 add STCi_l2 add 12 add dup STCi_clip 2 get exch sub % Extend
- [ 3 -1 roll dup 3 index add STCi_clip 3 get dup 5 index sub 3 1 roll ]
- /STCi_win exch def /STCi_l1 exch def
-
-% The "Axis"
- newpath
- STCi_win 0 get STCi_win 1 get 14 add moveto
- STCi_win 2 get STCi_win 1 get 14 add lineto stroke
-
- STCi_win 0 get 14 add STCi_win 1 get moveto
- STCi_win 0 get 14 add STCi_win 3 get lineto stroke
-
-% The Labels
- /Times-Roman findfont 10 scalefont setfont
- (Postscript-color) dup stringwidth pop
- STCi_win 2 get STCi_win 0 get sub 14 sub 1 index sub 2 div exch pop
- STCi_win 0 get add 14 add STCi_win 1 get 4 add moveto show
-
- gsave
- STCi_win 0 get 10 add STCi_win 1 get 14 add translate 90 rotate
- (Device-color) dup stringwidth pop
- STCi_win 3 get STCi_win 1 get sub 14 sub 1 index sub 2 div exch pop
- 0 moveto show
- grestore
-
-% The Graphs
- gsave
- STCi_win 0 get 14 add STCi_win 1 get 14 add
- STCi_win 2 get 2 index sub STCi_win 3 get 2 index sub
- 4 2 roll translate
- STCi_col 0 1 2 index length 1 sub {
- 1 index 1 index get aload pop setrgbcolor
- STCi_xv 1 index get STCi_yv 3 -1 roll get
- newpath
- 1 index 0 get 5 index mul 1 index 0 get 5 index mul moveto
- 1 index 1 get 5 index mul 1 index 0 get 5 index mul lineto
- 1 1 2 index length 1 sub {
- 2 index 1 index get 6 index mul
- 2 index 2 index get 6 index mul lineto
- 2 index 1 index 1 add get 6 index mul
- 2 index 2 index get 6 index mul lineto
- pop
- } for
- stroke pop pop
- } for
- pop pop pop
- grestore
-
-%
-% Find lowest Y from Text or graph
-%
- STCi_win 1 get STCi_clip 3 get STCi_text length 2 div 12 mul sub
- dup 2 index gt { pop } { exch pop } ifelse 12 sub
-
-%
-% compute the upper bar-window
-%
- /STCi_win [
- STCi_clip 0 get 4 -1 roll 36 sub STCi_clip 2 get 1 index 36 add
- ] def
-
-%
-% Draw the required number of graphs
-%
- [{ % Monochrome
- STCi_win STCi_xv 0 get {setgray} STCibar
- }{ % RGB
- STCi_win STCi_xv 0 get {0 0 setrgbcolor} STCibar
- STCi_win dup 1 exch 1 get 47 sub put
- STCi_win dup 3 exch 3 get 47 sub put
- STCi_win STCi_xv 1 get {0 0 3 1 roll setrgbcolor} STCibar
- STCi_win dup 1 exch 1 get 47 sub put
- STCi_win dup 3 exch 3 get 47 sub put
- STCi_win STCi_xv 2 get {0 0 3 2 roll setrgbcolor} STCibar
- }{ % CMYK
- STCi_win STCi_xv 0 get {0 0 0 setcmykcolor} STCibar
- STCi_win dup 1 exch 1 get 47 sub put
- STCi_win dup 3 exch 3 get 47 sub put
- STCi_win STCi_xv 1 get {0 0 0 4 1 roll setcmykcolor} STCibar
- STCi_win dup 1 exch 1 get 47 sub put
- STCi_win dup 3 exch 3 get 47 sub put
- STCi_win STCi_xv 2 get {0 0 0 4 2 roll setcmykcolor} STCibar
- STCi_win dup 1 exch 1 get 47 sub put
- STCi_win dup 3 exch 3 get 47 sub put
- STCi_win STCi_xv 3 get {0 0 0 4 3 roll setcmykcolor} STCibar
- }
- ] STCimode
-
- STCi_win 1 STCi_clip 1 get put
- STCi_win dup 3 exch 3 get 47 sub put
-
-%
-% Plot either one or two Color-Triangles
-%
- /ColorAdjustMatrix STCiget null ne STCi_onstc and {
- STCi_win 0 get STCi_win 2 get add 2 div
- [STCi_win 0 get STCi_win 1 get 3 index STCi_win 3 get ] colortri
- mark /ColorAdjustMatrix dup STCiget currentdevice putdeviceprops pop
- [1 index STCi_win 1 get STCi_win 2 get STCi_win 3 get ] colortri
- pop
- }{
- STCi_win colortri
- } ifelse
- newpath clippath stroke
-} ifelse
-showpage
diff --git a/Master/tlpkg/tlgs/lib/stcolor.ps b/Master/tlpkg/tlgs/lib/stcolor.ps deleted file mode 100644 index c4535afce84..00000000000 --- a/Master/tlpkg/tlgs/lib/stcolor.ps +++ /dev/null @@ -1,171 +0,0 @@ -% Copyright (C) 1995 Aladdin Enterprises. All rights reserved
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: stcolor.ps 6300 2005-12-28 19:56:24Z giles $
-% stcolor.ps
-% Epson Stylus-Color Printer-Driver
-
-% The purpose of this file is to configure the stcolor-printer driver
-
-%
-% It is useless and dangerous to interpret the following code with anything
-% else than Ghostscript, so this condition is verified first. If this fails
-% a message is send to the output. If this message bothers you, remove it,
-% but I prefer to know why the device-setup failed.
-
-statusdict begin product end
-dup (Ghostscript) eq 1 index (Aladdin Ghostscript) eq or
-exch (AFPL Ghostscript) eq or{
-
-% fetch the current device-parameters this is specific for Ghostscript.
-
- /STCold currentdevice getdeviceprops .dicttomark def
-
-% Any Ghostscript-Driver has a Name, verify that the selected device is
-% stcolor, otherwise nothing than another message will be produced.
-
- STCold /Name get (stcolor) eq {
-
-%
-% The main thing this file does, is to establish transfer-functions.
-% Here are two predefined arrays for 360x360Dpi and for 720x720DpI.
-% If resolution is 360x720 or 720x360 the average is used. You may
-% want to define other arrays here.
-%
-
- /STCdeftransfer [ 0.0 1.0 ] def
-
- /STCKtransfer360 [
- 0.0000 0.0034 0.0185 0.0377 0.0574 0.0769 0.0952 0.1147
- 0.1337 0.1540 0.1759 0.1985 0.2209 0.2457 0.2706 0.2949
- 0.3209 0.3496 0.3820 0.4145 0.4505 0.4907 0.5344 0.5840
- 0.6445 0.7093 0.8154 0.9816 0.9983 0.9988 0.9994 1.0000
- ] def
-
- /STCKtransfer720 [
- 0.0000 0.0011 0.0079 0.0151 0.0217 0.0287 0.0354 0.0425
- 0.0492 0.0562 0.0633 0.0700 0.0766 0.0835 0.0900 0.0975
- 0.1054 0.1147 0.1243 0.1364 0.1489 0.1641 0.1833 0.2012
- 0.2217 0.2492 0.2814 0.3139 0.3487 0.3996 0.4527 0.5195
- ] def
-
-% compute the resolution
-
- STCold /HWResolution get dup
- 0 get exch 1 get mul sqrt /STCdpi exch def
-
-% pick the colormodel
- STCold /ProcessColorModel get /STCcolor exch def
-
-
- mark % prepare stack for "putdeviceprops"
-
-% warn for BitsPerPixel=30 with fsrgb
- STCcolor /DeviceRGB eq STCold /BitsPerPixel get 32 eq and
- {
- (%%[ stcolor.ps: inefficient RGB-setup, recommend BitsPerPixel=24 ]%%\n)
- print
- } if
-
-% if the Dithering-Method is default (gscmyk), change it to fscmyk
-% this is achieved by pushing a name/value-pair onto the stack
-% if the selected algorithm uses another ProcessColorModel, it is necessary
-% to change the Value of STCcolor according to the new algorithm.
-
- STCold /Dithering get (gscmyk) eq
- {
- /Dithering (hscmyk) % preferred dithering-method
- } if % might be necessary to change STCcolor too
-
-%
-% select the array according to the resolution
-%
- STCdpi 359.0 lt
- { STCdeftransfer }
- { STCdpi 361.0 lt
- { STCKtransfer360 }
- { STCdpi 719.0 gt
- { STCKtransfer720 }
- {
- STCKtransfer360 length STCKtransfer720 length eq
- {
- 0 1 STCKtransfer360 length 1 sub
- {
- dup dup
- STCKtransfer360 exch get
- exch STCKtransfer720 exch get
- add 2.0 div
- STCKtransfer360 3 1 roll put
- } for
- }if
- STCKtransfer360
- } ifelse
- }ifelse
- } ifelse
- /STCtransfer exch def
-
-%
-% Add the arrays. With Version 1.17 and above, it seems to be
-% a good idea, to use the transfer-arrays as coding-arrays too.
-%
-
-%
-% RGB-Model requires inversion of the transfer-arrays
-%
- STCcolor /DeviceRGB eq
- {
- /RGBtransfer STCtransfer length array def
- 0 1 STCtransfer length 1 sub
- {
- dup RGBtransfer length 1 sub exch sub exch
- STCtransfer exch get 1.0 exch sub
- RGBtransfer 3 1 roll put
- } for
-
- /Rtransfer RGBtransfer
- /Gtransfer RGBtransfer
- /Btransfer RGBtransfer
-
- /Rcoding RGBtransfer
- /Gcoding RGBtransfer
- /Bcoding RGBtransfer
-
- }{
-
- /Ctransfer STCtransfer
- /Mtransfer STCtransfer
- /Ytransfer STCtransfer
- /Ktransfer STCtransfer
-
- /Ccoding STCtransfer
- /Mcoding STCtransfer
- /Ycoding STCtransfer
- /Kcoding STCtransfer
-
- } ifelse
-
- counttomark 0 ne
- {currentdevice putdeviceprops pop}{cleartomark}ifelse
-
-% decativate predefined correction
-
- {} dup dup currenttransfer setcolortransfer
-
- }{
- (%%[ stcolor.ps: currentdevice is not stcolor - ignored ]%%\n) print
- } ifelse
-}{
- (%%[ stcolor.ps: not interpreted by AFPL Ghostscript - ignored ]%%\n) print
-} ifelse
diff --git a/Master/tlpkg/tlgs/lib/stocht.ps b/Master/tlpkg/tlgs/lib/stocht.ps deleted file mode 100644 index 82e934dad6d..00000000000 --- a/Master/tlpkg/tlgs/lib/stocht.ps +++ /dev/null @@ -1,62 +0,0 @@ -% Copyright (C) 1999, 2000 Artifex Software, Inc. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: stocht.ps 8022 2007-06-05 22:23:38Z giles $
-% helper file to simplify use of Stochastic Halftone - uses ht_ccsto.ps
-
-% This file sets the /StochasticDefault /Halftone as the current
-% and the /Default halftoning, loading the Stochastic halftone
-% if required.
-
-% Stochastic halftoning is recommended for inkjet printers, and may
-% produce output as pleasing as the more computationally expensive
-% "error diffusion" that *some* device drivers provide.
-
-% For printing technologies other than inkjet, Stochastic halftoning
-% may not look better than standard screening. In particular, thermal
-% transfer and direct thermal tend to be better with standard ordered
-% screening methods. Some laser printers may produce "smoother"
-% looking gray shades with Stochastic halftoning. Try it, and if
-% you like it, use it.
-
-% Note that this /Default halftone can be overridden by PostScript
-% operators that set the screening or halftone (such as setscreen).
-
-% To make Stochastic Halftone be "sticky" so that other screening and
-% halftone setting in the subsequent PostScript will be ignored, use:
-% -c "<< /HalftoneMode 1 >> setuserparams"
-% on the command line prior to the file to be processed. For example,
-%
-% gs stocht.ps -c "<< /HalftoneMode 1 >> setuserparams" -f examples/tiger.eps
-
-% Alternatively, the command to set the /HalftoneMode userparam can be
-% concatenated to this file (see below).
-
-% =====================================================================
-% Try to get the previously defined resource
-{ /StochasticDefault /Halftone findresource } stopped
-{
- pop pop
- % Need to load the Stochastic Halftone using the lib file
- (ht_ccsto.ps) runlibfile
-} if
-
-% If we didn't error out by now, then go ahead and define the /Default
-/StochasticDefault /Halftone findresource
-/Default exch /Halftone defineresource
-sethalftone % Use the halftone
-
-% Uncomment the next line to make the Stocahstic halftoning be "sticky"
-% << /HalftoneMode 1 >> setuserparams
diff --git a/Master/tlpkg/tlgs/lib/traceimg.ps b/Master/tlpkg/tlgs/lib/traceimg.ps deleted file mode 100644 index 91a9850b775..00000000000 --- a/Master/tlpkg/tlgs/lib/traceimg.ps +++ /dev/null @@ -1,42 +0,0 @@ -% Copyright (C) 1994 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: traceimg.ps 6300 2005-12-28 19:56:24Z giles $
-% traceimg.ps
-% Trace the data supplied to the 'image' operator.
-
-% This code currently handles only the (Level 2) dictionary form of image,
-% with a single data source and 8-bit pixels.
-
-/traceimage % <dict> traceimage -
- { currentcolorspace == (setcolorspace\n) print
- (<<) print
- dup { (\t) print exch ==only ( ) print == } forall
- (>>\n) print flush
- begin /i_left Width Height mul store /i_dict currentdict store end
- { i_left 0 le { exit } if
- i_dict /DataSource get exec
- dup type /filetype eq
- { i_buf 0 i_left 32 .min getinterval readstring pop
- } if
- dup (%stdout) (w) file exch writehexstring (\n) print flush
- i_left exch length sub /i_left exch def
- } loop
- } bind odef
-
-/image /traceimage load def
-/i_left 0 def
-/i_dict null def
-/i_buf 32 string def
diff --git a/Master/tlpkg/tlgs/lib/traceop.ps b/Master/tlpkg/tlgs/lib/traceop.ps deleted file mode 100644 index 83e39f3b105..00000000000 --- a/Master/tlpkg/tlgs/lib/traceop.ps +++ /dev/null @@ -1,83 +0,0 @@ -% Copyright (C) 1992, 1993, 1994, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: traceop.ps 6300 2005-12-28 19:56:24Z giles $
-% Trace individual operators or procedures.
-% <opref> is <opname> or <opname> <dict>
-% (dict defaults to dict where op is currently defined, if writable;
-% otherwise uses userdict)
-% <opref> traceop prints vmem usage before;
-% <opref> <numargs|preproc> prints arguments or runs proc before;
-% <opref> <numargs|preproc> <numresults|postproc>
-% also prints results or runs proc after.
-% If traceflush is true, flush the output after each printout.
-/traceflush true def
-
-currentpacking true setpacking
-.currentglobal true .setglobal
-
-% Define the default "before" action
-/tracebefore { vmstatus 3 traceprint pop pop pop } def
-
-% Define the default "after" action
-/traceafter { } def
-
-/traceprint {
- dup type /integertype eq {
- 1 sub -1 0 { ( ) print index ==only } for
- } {
- exec
- } ifelse
-} bind def
-/traceend {
- traceflush { flush } if
-} bind def
-/traceop {
- userdict begin
- dup type dup /nametype eq exch /dicttype eq or { { tracebefore } } if
- 1 index type dup /nametype eq exch /dicttype eq or { { traceafter } } if
- /.tpost exch def /.tpre exch def
- dup type /dicttype ne {
- dup where not { userdict 1 index {} put userdict } if
- } if
- dup dup wcheck not {
- (Warning: substituting userdict for non-writable dictionary.) =
- pop userdict
- } if
- /.tddict exch def /.tdict exch def /.tname exch cvlit def
- .currentglobal [
- .tname /=only cvx ( ) /print cvx
- /.tpre load /traceprint cvx /traceend cvx
- .tdict .tname get /.tdef 1 index cvlit def
- dup xcheck {
- dup type dup /arraytype eq exch /packedarraytype eq or {
- /exec cvx
- } if
- } if
- /.tpost load /traceprint cvx () /= cvx /traceend cvx
- .tdef gcheck /.tpre load gcheck and /.tpost load gcheck and .setglobal
- ] cvx
- .tdef type /operatortype eq {
- .tname exch .makeoperator
- } if
- exch .setglobal
- .tddict exch .tname exch put
- end % userdict
-} bind def
-/tracebind /bind load def % in case someone wants to put it back
-/bind { } def % disable
-
-.setglobal
-setpacking
diff --git a/Master/tlpkg/tlgs/lib/type1enc.ps b/Master/tlpkg/tlgs/lib/type1enc.ps deleted file mode 100644 index 8022f08374e..00000000000 --- a/Master/tlpkg/tlgs/lib/type1enc.ps +++ /dev/null @@ -1,65 +0,0 @@ -% Copyright (C) 1992, 1993 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: type1enc.ps 6300 2005-12-28 19:56:24Z giles $
-% type1enc.ps
-% PostScript language versions of the Type 1 encryption/decryption algorithms.
-
-% This file is normally not needed with Ghostscript, since Ghostscript
-% implements these algorithms in C. For the specifications, see Chapter 7 of
-% "Adobe Type 1 Font Format," ISBN 0-201-57044-0, published by Addison-Wesley.
-
-/.type1crypt % <R> <from> <to> <proc> .type1crypt <R'> <to>
- % (auxiliary procedure)
- { 4 1 roll
- 0 2 index length getinterval
- 0 1 2 index length 1 sub
- { % Stack: proc R from to index
- 2 index 1 index get % proc R from to index C/P
- 4 index -8 bitshift xor 3 copy put % proc R from to index P/C
- 5 index exec % proc R from to C
-
-% Compute R' = ((R + C) * 52845 + 22719) mod 65536
-% without exceeding a 31-bit integer magnitude, given that
-% 0 <= R <= 65535 and 0 <= C <= 255.
-
- 4 -1 roll add
- dup 20077 mul % 52845 - 32768
- exch 1 and 15 bitshift add % only care about 16 low-order bits
- 22719 add 65535 and 3 1 roll
- }
- for exch pop 3 -1 roll pop
- } bind def
-
-% <state> <fromString> <toString> .type1encrypt <newState> <toSubstring>
-% Encrypts fromString according to the algorithm for Adobe
-% Type 1 fonts, writing the result into toString.
-% toString must be at least as long as fromString or a
-% rangecheck error occurs. state is the initial state of
-% the encryption algorithm (a 16-bit non-negative
-% integer); newState is the new state of the algorithm.
-
-/.type1encrypt
- { { exch pop } .type1crypt
- } bind def
-
-% <state> <fromString> <toString> .type1decrypt <newState> <toSubstring>
-% Decrypts fromString according to the algorithm for Adobe
-% Type 1 fonts, writing the result into toString. Other
-% specifications are as for type1encrypt.
-
-/.type1decrypt
- { { pop 2 index exch get } .type1crypt
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/type1ops.ps b/Master/tlpkg/tlgs/lib/type1ops.ps deleted file mode 100644 index 9647a90c98f..00000000000 --- a/Master/tlpkg/tlgs/lib/type1ops.ps +++ /dev/null @@ -1,237 +0,0 @@ -% Copyright (C) 1992, 1997, 1998, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: type1ops.ps 6300 2005-12-28 19:56:24Z giles $
-% type1ops.ps
-% Define the Type 1 and Type 2 font opcodes for use by Ghostscript utilities.
-
-% Define the default value of lenIV.
-% Note that this expects the current font to be on the dictionary stack.
-
-/lenIV { FontType 2 eq { -1 } { 4 } ifelse } def
-
-% ---------------- Encoding ---------------- %
-
-/Type1encode 70 dict
-
- % Data types
-
-dup /nulltype {
- pop ()
-} put
-dup /nametype {
- Type1encode exch get
-} put
-dup /stringtype {
-} put
-dup /integertype {
- dup dup -107 ge exch 107 le and {
- 139 add (x) dup 0 4 -1 roll put
- } {
- dup dup -1131 ge exch 1131 le and {
- dup 0 ge { 16#f694 } { neg 16#fa94 } ifelse add
- (xx) dup dup 0 4 index -8 bitshift put
- 1 4 -1 roll 255 and put
- } {
- (\377xxxx) 1 1 4 {
- dup 8 mul 32 sub 3 index exch bitshift 255 and
- 2 index 3 1 roll put
- } for exch pop
- } ifelse
- } ifelse
-} put
-
- % Operators
-
-% Identical or similar in Type 1 and Type 2.
-/c_hstem 1 def dup /hstem <01> put
-/c_vstem 3 def dup /vstem <03> put
-/c_vmoveto 4 def dup /vmoveto <04> put
-/c_rlineto 5 def dup /rlineto <05> put
-/c_hlineto 6 def dup /hlineto <06> put
-/c_vlineto 7 def dup /vlineto <07> put
-/c_rrcurveto 8 def dup /rrcurveto <08> put
-/c_callsubr 10 def /s_callsubr <0a> def dup /callsubr s_callsubr put
-/c_return 11 def dup /return <0b> put
-/c_escape 12 def
- /ce_div 12 def /s_div <0c0c> def dup /div s_div put
-/c_endchar 14 def /s_endchar <0e> def dup /endchar s_endchar put
-/c_rmoveto 21 def dup /rmoveto <15> put
-/c_hmoveto 22 def dup /hmoveto <16> put
-/c_vhcurveto 30 def dup /vhcurveto <1e> put
-/c_hvcurveto 31 def dup /hvcurveto <1f> put
-% Only in Type 1.
-/c_closepath 9 def dup /closepath <09> put
-/c_hsbw 13 def /s_hsbw <0d> def dup /hsbw s_hsbw put
- /ce_dotsection 0 def /s_dotsection <0c06> def dup /dotsection s_dotsection put
- /ce_vstem3 1 def /s_vstem3 <0c01> def dup /vstem3 s_vstem3 put
- /ce_hstem3 2 def /s_hstem3 <0c02> def dup /hstem3 s_hstem3 put
- /ce_seac 6 def /s_seac <0c06> def dup /seac s_seac put
- /ce_sbw 7 def /s_sbw <0c07> def dup /sbw s_sbw put
- /ce_callothersubr 16 def /s_callothersubr <0c10> def dup /callothersubr s_callothersubr put
- /ce_pop 17 def /s_pop <0c11> def dup /pop s_pop put
- /ce_setcurrentpoint 33 def /s_setcurrentpoint <0c21> def dup /setcurrentpoint s_setcurrentpoint put
- /s_setcurrentpoint_hmoveto s_setcurrentpoint <8b16> concatstrings def
-% Only in Type 2.
-dup /blend <10> put
-dup /hstemhm <12> put
-dup /hintmask <13> put
-dup /cntrmask <14> put
-dup /vstemhm <17> put
-dup /rcurveline <18> put
-dup /rlinecurve <19> put
-dup /vvcurveto <1a> put
-dup /hhcurveto <1b> put
-dup /callgsubr <1d> put
- dup /and <0c03> put
- dup /or <0c04> put
- dup /not <0c05> put
- dup /store <0c08> put
- dup /abs <0c09> put
- dup /add <0c0a> put
- dup /sub <0c0b> put
- dup /load <0c0d> put
- dup /neg <0c0c> put
- dup /eq <0c0f> put
- dup /drop <0c12> put
- dup /put <0c14> put
- dup /get <0c15> put
- dup /ifelse <0c16> put
- dup /random <0c17> put
- dup /mul <0c18> put
- dup /sqrt <0c1a> put
- dup /dup <0c1b> put
- dup /exch <0c1c> put
- dup /index <0c1d> put
- dup /roll <0c1e> put
- dup /hflex <0c22> put
- dup /flex <0c23> put
- dup /hflex1 <0c24> put
- dup /flex1 <0c25> put
-
-readonly def
-
-% ---------------- Decoding ---------------- %
-
-/Type1decode 512 array
-
-Type1encode {
- dup type /stringtype eq {
- dup length 1 eq { 0 get } { 1 get 256 add } ifelse
- % stack: array key code
- exch 2 index 3 1 roll put
- } {
- pop pop
- } ifelse
-} forall
-
-dup 12 {
- dup read pop dup Type1decode exch 256 add get dup null ne
- { exch pop }
- { pop 2 string dup 0 12 put dup 1 4 -1 roll put }
- ifelse
-} put
-dup 28 { % Type 2 only
- dup read pop 128 xor 128 sub 8 bitshift
- 1 index read pop add
-} put
-32 1 246 { 2 copy dup 139 sub put pop } for
-dup 247 { dup read pop 108 add } put
-dup 248 { dup read pop 364 add } put
-dup 249 { dup read pop 620 add } put
-dup 250 { dup read pop 876 add } put
-dup 251 { dup read pop 108 add neg } put
-dup 252 { dup read pop 364 add neg } put
-dup 253 { dup read pop 620 add neg } put
-dup 254 { dup read pop 876 add neg } put
-dup 255 { % Different for Type 1 and Type 2
- dup read pop 128 xor 128 sub
- 3 { 8 bitshift 1 index read pop add } repeat
- FontType 2 eq { 65536.0 div } if
-} put
-
-readonly def
-
-% ---------------- Procedures ---------------- %
-
-% For these utilities, a CharString is represented by a sequence of
-% integers, reals, strings, and names, either in an array or on the stack.
-% Integers and reals represent themselves; strings are other data that
-% appears in the CharString; names are CharString operator names.
-% A CharString in an array is called a "charproc"; a CharString on
-% the stack is called a "charstack", and is delimited by a mark.
-% Individual elements are called "chartokens".
-
-% ------ Encoding ------ %
-
-% Get the string for a chartoken.
-% Note that this string may be overwritten by the next call.
-/chartoken_string { % <chartoken> chartoken_string <string>
- dup type Type1encode exch get exec
-} bind def
-% Compute the length of a CharString.
-/chartoken_length { % <chartoken> chartoken_length <length>
- chartoken_string length
-} bind def
-/charproc_length { % <charproc> charproc_length <length>
- 0 exch { chartoken_length add } forall
-} bind def
-/charstack_length { % <charstack> charstack_length <charstack> <length>
- counttomark 0 exch -1 1 { index chartoken_length add } for
-} bind def
-
-% Write a CharString to a file. Normally this will be a NullEncode filter
-% writing on a string of the correct length.
-/chartoken_write { % <file> <chartoken> chartoken_write -
- chartoken_string writestring
-} bind def
-/charproc_write { % <file> <charproc> charproc_write -
- { 1 index exch chartoken_write } forall pop
-} bind def
-% Note that the arguments of charstack_write are backwards.
-/charstack_write { % <charstack> <file> charstack_write -
- counttomark 1 sub -1 1 { index 1 index exch chartoken_write } for
- cleartomark
-} bind def
-
-% Convert a charproc or charstack to an *un*encrypted CharString.
-/charproc_string { % <charproc> charproc_string <string>
- mark exch aload pop charstack_string
-} bind def
-/charstack_string { % <charstack> charstack_string <string>
- charstack_length lenIV 0 gt {
- lenIV add string
- dup dup length lenIV sub lenIV exch getinterval % skip lenIV
- } {
- string
- } ifelse
- /NullEncode filter
- exch 1 index counttomark 1 add 2 roll
- charstack_write closefile
-% lenIV 0 ge { 4330 exch dup .type1encrypt exch pop readonly } if
-} bind def
-
-% ------ Decoding ------ %
-
-% Decode a CharString (unencrypted).
-/charstack_read { % <file> charstack_read <no-mark-charstack>
- { dup read not { pop exit } if
- Type1decode 1 index get dup null eq {
- pop 1 string dup 0 4 -1 roll put
- } {
- exch pop exec
- } ifelse exch
- } loop
-} bind def
diff --git a/Master/tlpkg/tlgs/lib/uninfo.ps b/Master/tlpkg/tlgs/lib/uninfo.ps deleted file mode 100644 index 49de744c08c..00000000000 --- a/Master/tlpkg/tlgs/lib/uninfo.ps +++ /dev/null @@ -1,220 +0,0 @@ -%!
-% Copyright (C) 1997 Aladdin Enterprises. All rights reserved
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: uninfo.ps 6300 2005-12-28 19:56:24Z giles $
-% uninfo.ps: Utilities for "printing" PostScript items, especially dictionaries
-% Usage:
-% (prefix-string) dict unprint
-
-% Maximum Print-Width
-/HSpwidth 80 def
-
-% any HScvs string
-/HScvs {
-% Number-Syntax
- dup type % stack: any /anytype
- dup /integertype eq 1 index /realtype eq or { pop
- 16 string cvs
- }{
-% Logical-Type
- dup /booleantype eq { pop
- 5 string cvs
- }{
-% Identifiers
- dup /nametype eq { pop
- dup length 1 add string
- dup 0 (/) putinterval
- exch 1 index 1 1 index length 1 sub getinterval cvs pop
- }{
-% Strings
- dup /stringtype eq { pop
-% ------- Compute Length
- 2 1 index { % stack: str len item
- dup 32 lt 1 index 126 gt or { % need 4
- pop 4 add
- }{
- dup 40 eq 1 index 41 eq or 1 index 92 eq or {
- pop 2 add
- }{
- pop 1 add
- } ifelse
- } ifelse
- } forall
-% ------- Allocate & Fill String
- string dup 0 (\() putinterval 1
- 3 -1 roll { % outstr pos item
- dup 32 lt 1 index 126 gt or {
- dup 7 le {
- 2 index 2 index (\\00) putinterval
- 8 3 index 3 index 3 add 1 getinterval cvrs
- }{
- dup 63 le {
- 2 index 2 index (\\0) putinterval
- 8 3 index 3 index 2 add 2 getinterval cvrs
- }{
- 2 index 2 index (\\) putinterval
- 8 3 index 3 index 1 add 3 getinterval cvrs
- } ifelse
- } ifelse
- pop 4 add
- }{
- dup 40 eq 1 index 41 eq or 1 index 92 eq or {
- 2 index 2 index (\\) putinterval
- exch 1 add exch
- } if
- 2 index exch 2 index exch put
- 1 add
- } ifelse
- } forall
- 1 index exch (\)) putinterval
- }{ exch pop
- dup length 1 add string
- dup 0 (-) putinterval
- exch 1 index 1 1 index length 1 sub getinterval cvs pop
- dup dup length 4 sub (-) putinterval
- 0 1 index length 3 sub getinterval
- } ifelse
- } ifelse
- } ifelse
- } ifelse
-} bind def
-
-% int HSpindent - indent-spaces
-/HSpindent {
- dup 0 gt {
- 1 1 3 -1 roll { pop ( ) print } for
- }{
- pop
- } ifelse
-} bind def
-
-% indent array HSaprint -> Print an Array
-/HSaprint {
- dup type /arraytype eq {
- ( [) print
- exch 1 add dup 1 add
- 3 -1 roll { % rind pos item
- HScvs dup length % rind pos str len
- dup 3 index add HSpwidth ge {
- (\n) print
- 3 index HSpindent
- 3 -1 roll pop
- 2 index add
- exch
- }{
- ( ) print
- 2 index add 1 add
- 3 -1 roll pop
- exch
- } ifelse
- print
- } forall
- ( ]) print
- pop pop
- }{
- ( ) print
- HScvs print pop
- } ifelse
- (\n) print
-} bind def
-
-% dict HSdnames dict names (creates sorted name-strings)
-/HSdnames {
-% Build namelist, stack: dic
- dup length 0 eq {
- []
- }{
- [ 1 index {
- pop dup type /nametype eq {
- dup length string cvs
- }{
- pop
- } ifelse
- } forall
- ]
-% Sort the namelist, stack: dic nam
- 0 1 2 index length 2 sub { % stack: dic nam I
- 2 copy get % stack: pre dic nam I nam[I]
- 1 index 1 add 1 4 index length 1 sub { % stack: dic nam I nam[I] J
- 3 index 1 index get % dic nam I S[I] J S[J]
- 2 index 1 index gt { % swap them
- 4 index 2 index 4 index put
- 4 index 4 index 2 index put
- 3 1 roll
- } if
- pop pop
- } for
- pop pop
- } for
- } ifelse
-} bind def
-
-% string:prefix dict:which unprint
-/unprint {
- HSdnames % pre dic nam
-% compute the maximum length
- 0 1 index { % pre dic nam maxlen nam[I]
- length 2 copy lt { exch } if pop
- } forall
-% Print out all the items, stack: pre dic nam maxlen
- (\n) print
- exch { % pre dic maxlen nam[I]
-% no prefix yet, -> flush right
- 3 index length 0 eq {
- dup length 2 index exch sub HSpindent
- }{
- 3 index print (/) print
- } ifelse
-% print the name
- dup print
-% prefix: fill up with blanks
- 3 index length 0 ne {
- dup length 2 index exch sub HSpindent
- } if
-% now print the item itself, stack: pre dic maxlen nam[I]
- 2 index 1 index cvn get dup type % stack: pre dic maxlen nam[i] item typ
-% Dict-Syntax
- dup /dicttype eq { pop % stack: pre dic maxlen nam[i] item
- ( ) print dup HScvs print
- 4 index length 0 eq { % brand new prefix
- 2 index string 0 1 5 index 1 sub { 1 index exch 32 put } for
- dup 4 index 4 index length sub 5 -1 roll putinterval
- }{
- 4 index length 1 add 2 index length add string
- dup 0 7 index putinterval
- dup 6 index length (/) putinterval
- dup 6 index length 1 add 5 -1 roll putinterval
- } ifelse
- exch unprint
- }{
- 3 -1 roll pop % tack: pre dic maxlen item typ
-% Array-Syntax
- dup /arraytype eq { pop % stack: pre dic maxlen item
- 3 index length dup 0 ne { 1 add } if 2 index add
- exch HSaprint
- }{ pop
- ( ) print
- HScvs print
- (\n) print
- } ifelse
- } ifelse
- } forall
- pop pop length -1 eq { (\n) print } if
-} bind def
-
-/currentpagedevice where { % check for currentpagedevice
- /currentpagedevice get exec () exch unprint
-} if
diff --git a/Master/tlpkg/tlgs/lib/unprot.ps b/Master/tlpkg/tlgs/lib/unprot.ps deleted file mode 100644 index fce2db10cdc..00000000000 --- a/Master/tlpkg/tlgs/lib/unprot.ps +++ /dev/null @@ -1,67 +0,0 @@ -% Copyright (C) 1991, 1992, 1998 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: unprot.ps 6300 2005-12-28 19:56:24Z giles $
-% Disable all access checks. This is useful for printing out
-% eexec-encrypted Type 1 fonts, and similar purposes.
-
-systemdict wcheck
- { /protdict systemdict def
- }
- { (Please restart Ghostscript with the -dWRITESYSTEMDICT switch.\n) print
- (Some access checks will remain active if you do not do this.\n) print
- flush
- /protdict userdict def
- }
-ifelse
-
-% The procedures we're about to define will go in systemdict,
-% so they must be allocated in global VM.
-
-.currentglobal true .setglobal
-
-protdict begin
- /readonly. /readonly load def
- /executeonly. /executeonly load def
- /noaccess. /noaccess load def
- /readonly { } odef
- /readonly.. /readonly load def
- /executeonly { } odef
- /executeonly.. /executeonly load def
- /noaccess { } odef
- /noaccess.. /noaccess load def
-end
-
-% Disable the access checks.
-
-/unprot
- { protdict begin
- /readonly /readonly.. load def
- /executeonly /executeonly.. load def
- /noaccess /noaccess.. load def
- end
- } bind def
-
-% Re-enable the access checks.
-
-/reprot
- { protdict begin
- /readonly /readonly. load def
- /executeonly /executeonly. load def
- /noaccess /noaccess. load def
- end
- } bind def
-
-.setglobal
diff --git a/Master/tlpkg/tlgs/lib/viewcmyk.ps b/Master/tlpkg/tlgs/lib/viewcmyk.ps deleted file mode 100644 index e874b09db2b..00000000000 --- a/Master/tlpkg/tlgs/lib/viewcmyk.ps +++ /dev/null @@ -1,63 +0,0 @@ -% Copyright (C) 1996, 1997, 1998 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: viewcmyk.ps 6300 2005-12-28 19:56:24Z giles $
-% viewcmyk.ps
-% Display a raw CMYK file.
-% Requires the colorimage operator.
-% If SCALE is defined, maps input pixels to output pixels with that scale;
-% if SCALE is undefined, scales the image to fit the page.
-% If BITS is defined, it is the number of bits per sample (1,2,4,8,12);
-% if BITS is undefined, its default value is 1.
-
-/viewcmyk { % <filename> <width> viewcmyk -
- 20 dict begin
- /w exch def
- /fname exch def
- /bpc /BITS where { pop BITS } { 1 } ifelse def
- /f fname (r) file def
- mark fname status pop pop pop /flen exch def cleartomark
- /h flen w bpc 4 mul mul 7 add 8 idiv idiv def
- (Dimensions: ) print [w h] == flush
- % Set up scaling.
- /SCALE where {
- pop
- % Map pixels SCALE-for-1. Assume orthogonal transformation.
- SCALE 1 0 dtransform add abs div
- SCALE 0 1 dtransform add abs div
- } {
- % Scale the image (uniformly) to fit the page.
- clippath pathbbox pop pop translate
- pathbbox 3 -1 roll sub h div
- 3 1 roll exch sub w div .min dup
- } ifelse scale
- w h bpc [1 0 0 -1 0 h] f false 4 colorimage
- showpage
- f closefile
- end
-} bind def
-
-% If the program was invoked from the command line, run it now.
-[ shellarguments {
- counttomark 2 eq {
- cvi viewcmyk
- } {
- cleartomark
- (Usage: gs -- viewcmyk.ps filename.cmyk width\n) print
- ( e.g.: gs -- viewcmyk.ps my.cmyk 2550\n) print flush
- } ifelse
-} {
- pop
-} ifelse
diff --git a/Master/tlpkg/tlgs/lib/viewgif.ps b/Master/tlpkg/tlgs/lib/viewgif.ps deleted file mode 100644 index 7cfe8af829d..00000000000 --- a/Master/tlpkg/tlgs/lib/viewgif.ps +++ /dev/null @@ -1,160 +0,0 @@ -% Copyright (C) 1989, 1992, 1993, 1998 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: viewgif.ps 6300 2005-12-28 19:56:24Z giles $
-% viewgif.ps
-% Display a GIF file.
-
-/read1 % <file> read1 <int>
- { read pop
- } bind def
-/read2 % <file> read2 <int>
- { dup read1 exch read1 8 bitshift add
- } bind def
-
-/readGIFheader % <file> readGIFheader <dict>
- { 20 dict begin
- dup 6 string readstring pop
- dup (GIF87a) eq exch (GIF89a) eq or not
- { (Not a GIF file.\n) print cleartomark stop
- } if
- dup read2 /Width exch def
- dup read2 /Height exch def
- dup read1
- dup 128 ge /GlobalColor exch def
- dup -4 bitshift 7 and 1 add /BitsPerPixel exch def %***BOGUS?***
- dup 8 and 0 ne /PaletteSorted exch def
- 7 and 1 add dup /BitsPerPixel exch def
- 1 exch bitshift /PaletteSize exch def
- dup read1 /BackgroundIndex exch def
- dup read1 15 add 64 div /AspectRatio exch def
- GlobalColor
- { PaletteSize 3 mul string readstring pop
- /GlobalPalette exch def
- } if
- currentdict end
- } bind def
-
-/readGIFimageHeader % <file> readGIFimageHeader <dict>
- % Note: GIF header must be on dict stack
- { 10 dict begin
- { dup read1
- dup (!) 0 get ne { exit } if pop % extension
- dup read1 pop
- { dup read1 dup 0 eq { pop exit } if { dup read1 pop } repeat
- } loop
- } loop
- (,) 0 get ne
- { (Not a GIF image.\n) print stop
- } if
- dup read2 /Left exch def
- dup read2 /Top exch def
- dup read2 /Width exch def
- dup read2 /Height exch def
- dup read1
- dup 128 ge /LocalColor exch def
- dup 64 and 0 ne /Interlaced exch def
- LocalColor
- { 7 and 1 add /BitsPerPixel exch def
- 1 BitsPerPixel bitshift 3 mul string readstring pop
- /Palette exch def
- }
- { pop pop /Palette GlobalPalette def
- }
- ifelse
- currentdict end
- } bind def
-
-/imageGIF % <imagedict> imageGIF
- { /ImageOut where
- { pop
- % We know BitsPerComponent = 8, Decode = [0 255].
- % and there is only a single data source which is
- % either a filter or a string whose size is exactly
- % the width of the row.
- dup /DataSource get dup type /stringtype eq
- { ImageOut exch writestring
- }
- { pop dup /Width get string
- 1 index /Height get
- { 1 index /DataSource get 1 index readstring pop
- ImageOut exch writestring
- }
- repeat pop pop
- }
- ifelse
- }
- { image
- }
- ifelse
- } bind def
-
-/viewGIF % <file|string> viewGIF -
- { save 20 dict begin
- /saved exch def
- dup type /stringtype eq { (r) file } if
- /F exch def
- /ImageOutFile where { /ImageOut ImageOutFile (w) file def } if
- F readGIFheader /Header exch def
- currentdict Header end begin begin
- VGIFDEBUG { Header { exch == == } forall (----------------\n) print flush } if
- F readGIFimageHeader /ImageHeader exch def
- currentdict ImageHeader end begin begin
- VGIFDEBUG { ImageHeader { exch == == } forall (----------------\n) print flush } if
- /D F
- << /InitialCodeLength F read1
- /FirstBitLowOrder true
- /BlockData true
- /EarlyChange 0
- >> /LZWDecode filter def
-
- [/Indexed /DeviceRGB 1 BitsPerPixel bitshift 1 sub Palette] setcolorspace
- matrix currentmatrix
- 0 1 3 { 2 copy get dup 0 ne { dup abs div } if 3 copy put pop pop } for
- setmatrix
- << /ImageType 1
- /ImageMatrix [1 0 0 -1 0 Height]
- /BitsPerComponent 8
- /Decode [0 255]
- Interlaced
- { /Width Width /Height 1
- /row Width string def
- /DataSource row
- >> /I exch def
- /inter % <num> <denom> inter -
- { /denom exch def /num exch def
- gsave
- /lines Height denom 1 sub add num sub denom idiv def
- 0 1 lines 1 sub {
- Height exch denom mul num add sub
- I /ImageMatrix get 5 3 -1 roll put
- D row readstring pop pop
- I imageGIF
- } for
- grestore
- }
- bind def
- 0 8 inter
- 4 8 inter
- 2 4 inter
- 1 2 inter
- }
- { /Width Width /Height Height
- /DataSource D
- >> imageGIF
- }
- ifelse
- saved end end end restore
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/viewjpeg.ps b/Master/tlpkg/tlgs/lib/viewjpeg.ps deleted file mode 100644 index 10282a8fe44..00000000000 --- a/Master/tlpkg/tlgs/lib/viewjpeg.ps +++ /dev/null @@ -1,159 +0,0 @@ -%! viewjpeg.ps Copyright (C) 1994 Thomas Merz <tm@pdflib.com>
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: viewjpeg.ps 6300 2005-12-28 19:56:24Z giles $
-% View JPEG files with Ghostscript
-%
-% This PostScript code relies on level 2 features.
-%
-% Only JPEG baseline, extended sequential, and progressive files
-% are supported. Note that Adobe PostScript level 2 does not include
-% progressive-JPEG support. Ghostscript with IJG JPEG v6 or later
-% will decode progressive JPEG, but only if you edit gsjmorec.h to
-% enable that feature.
-%
-% Author's address:
-% ------------------------------+
-% {(pstack exec quit) = flush } | Thomas Merz, Munich
-% pstack exec quit | voice +49/89/29160728
-% ------------------------------+ tm@muc.de http://www.muc.de/~tm/
-%
-% $Id: viewjpeg.ps 6300 2005-12-28 19:56:24Z giles $
-% Updated by L. Peter Deutsch 20-May-1997:
-% move the usage example to the beginning
-% Updates by Tom Lane 6-Sep-1995
-
-% Usage example:
-% (jpeg-6/testimg.jpg) viewJPEG
-
-/languagelevel where {pop languagelevel 2 lt}{true} ifelse {
- (JPEG needs PostScript Level 2!\n) print flush stop
-} if
-
-/JPEGdict 20 dict def
-JPEGdict begin
-
-/NoParamMarkers [ % JPEG markers without additional parameters
- 16#D0 16#D1 16#D2 16#D3 16#D4 16#D5 16#D6 16#D7 16#D8 16#01
-] def
-
-/NotSupportedMarkers [ % JPEG markers not supported by PostScript level 2
- 16#C3 16#C5 16#C6 16#C7 16#C8 16#C9 16#CA 16#CB 16#CD 16#CE 16#CF
-] def
-
-% Names of color spaces
-/ColorSpaceNames << /1 /DeviceGray /3 /DeviceRGB /4 /DeviceCMYK >> def
-
-% read one byte from file F
-% - ==> int --or-- stop context
-/NextByte {
- F read not { (Read error in ViewJPEG!\n) print flush stop } if
-} bind def
-
-/SkipSegment { % read two bytes and skip that much data
- NextByte 8 bitshift NextByte add 2 sub { NextByte pop } repeat
-} bind def
-
-% read width, height, and # of components from JPEG markers
-% and store in dict
-/readJPEGmarkers { % - ==> dict --or-- stop context
- 5 dict begin
-
- { % loop: read JPEG marker segments until we find SOFn marker or EOF
- NextByte
- 16#FF eq { % found marker
- /markertype NextByte def
- % Is it S0F0=baseline, SOF1=extended sequential, SOF2=progressive ?
- markertype dup 16#C0 ge exch 16#C2 le and {
- NextByte pop NextByte pop % segment length
- % Ghostscript and Adobe PS accept only data precision 8
- NextByte 8 ne {
- (Error: not 8 bits per component!\n) print flush stop
- } if
-
- % Read crucial image parameters
- /height NextByte 8 bitshift NextByte add def
- /width NextByte 8 bitshift NextByte add def
- /colors NextByte def
-
- VJPGDEBUG { currentdict { exch == == } forall flush } if
- exit
- } if
-
- % detect several segment types which are not compatible with PS
- NotSupportedMarkers {
- markertype eq {
- (Marker ) print markertype ==
- (not supported!\n) print flush stop
- } if
- } forall
-
- % Skip segment if marker has parameters associated with it
- true NoParamMarkers { markertype eq {pop false exit} if } forall
- { SkipSegment } if
- } if
- } loop
-
- currentdict dup /markertype undef
- end
-} bind def
-
-end % JPEGdict
-
-% read image parameters from JPEG file and display the image
-/viewJPEG { % <file|string> ==> -
- save
- JPEGdict begin
- /saved exch def
- /scratch 1 string def
- dup type /stringtype eq { (r) file } if
- /F exch def
-
- readJPEGmarkers begin
- F 0 setfileposition % reset file pointer
-
- % We use the whole clipping area for the image (at least in one dimension)
- gsave clippath pathbbox grestore
- /ury exch def /urx exch def
- /lly exch def /llx exch def
-
- llx lly translate
- width height scale
-
- % use whole width or height, whichever is appropriate
- urx llx sub width div ury lly sub height div
- 2 copy gt { exch } if pop % min
- dup scale
- ColorSpaceNames colors scratch cvs get setcolorspace
-
- % prepare image dictionary
- << /ImageType 1
- /Width width
- /Height height
- /ImageMatrix [ width 0 0 height neg 0 height ]
- /BitsPerComponent 8
- % If 4-component (CMYK), assume data is inverted per Adobe Photoshop
- colors 4 eq {
- /Decode [ colors { 1 0 } repeat ]
- } {
- /Decode [ colors { 0 1 } repeat ]
- } ifelse
- /DataSource F /DCTDecode filter
- >> image
-
- end % image parameter dictionary
-
- saved end restore
-} bind def
diff --git a/Master/tlpkg/tlgs/lib/viewmiff.ps b/Master/tlpkg/tlgs/lib/viewmiff.ps deleted file mode 100644 index cdc42c474ab..00000000000 --- a/Master/tlpkg/tlgs/lib/viewmiff.ps +++ /dev/null @@ -1,124 +0,0 @@ -% Copyright (C) 1998 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: viewmiff.ps 6300 2005-12-28 19:56:24Z giles $
-% viewmiff.ps
-% Display a MIFF file. You would think the 'display' command would do this,
-% but many versions of 'display' either core-dump or require unacceptably
-% large amounts of memory.
-
-% Recognize MIFF keywords.
-/miffwords mark
- /class { cvn /class exch def }
- /colors { cvi /colors exch def }
- /columns { cvi /Width exch def }
- /compression { cvn /compression exch def }
- /depth { cvi /depth exch def }
- /packets { cvi /packets exch def }
- /rows { cvi /Height exch def }
-.dicttomark readonly def
-
-% Recognize MIFF image classes.
-/miffclasses mark
- /DirectClass {
- /DeviceRGB setcolorspace
- /BitsPerComponent depth def
- /Decode [ 0 1 0 1 0 1 ] def
- }
- /PseudoClass {
- [ /Indexed
- % The MIFF documentation lies about the size of pixels
- % for this case: the pixel size is determined only by
- % the number of colors, and is not affected by the image
- % depth. Specifically, if there are 256 or fewer colors
- % but the depth (of color map entries) is 16, each pixel
- % is still only 1 byte, not 2.
- currentdict /colors known {
- /DeviceRGB colors 1 sub
- /BitsPerComponent colors 256 le { 8 } { 16 } ifelse def
- colors 3 mul string depth 8 eq {
- f exch readstring pop
- } {
- % 16-bit color map entries: take only the high-order byte.
- 0 1 2 index length 1 sub {
- f read pop 2 index 3 1 roll put f read pop pop
- } for
- } ifelse
- } {
- /colors 256 def
- /DeviceGray 255
- 256 string 0 1 255 { 1 index exch dup put } for
- } ifelse
- ] setcolorspace
- /Decode [ 0 1 BitsPerComponent bitshift 1 sub ] def
- }
-.dicttomark readonly def
-
-% Recognize MIFF compression methods.
-/rlstring 768 string def
-/rlread {
- % packets is not reliable -- disregard it.
- dup rlstring 0 3 getinterval readstring {
- pop read pop 3 mul 3 3 2 index {
- rlstring exch rlstring 0 3 getinterval putinterval
- } for
- rlstring 0 3 -1 roll 3 add getinterval
- } {
- pop pop ()
- } ifelse
-} bind def
-/miffcompress mark
- /Uncompressed { f }
- /RunLengthEncoded { { f rlread } }
- /Zip { [ f /FlateDecode filter cvlit /rlread cvx ] cvx }
-.dicttomark readonly def
-
-% Read a MIFF file and display the image.
-/viewmiff { % <filename> viewmiff -
- 50 dict begin
- /fname 1 index def
- /f exch (r) file def
- % Set defaults.
- /ImageType 1 def
- /class /DirectClass def
- /compression /Uncompressed def
- /depth 8 def
- /packets 16#7fffffff def
- % Read and parse the header.
- { f token pop
- dup (:) eq { pop exit } if
- dup type /nametype eq {
- .namestring (=) search {
- exch pop miffwords exch .knownget { exec } { pop } ifelse
- } {
- pop % who knows?
- } ifelse
- } {
- pop % probably a comment in braces
- } ifelse
- } loop
- % Read and display the image.
- miffclasses class get exec
- /DataSource miffcompress compression get exec def
- /ImageMatrix [Width 0 0 Height neg 0 Height] def
- currentpagedevice /PageSize get
- dup 0 get exch 1 get scale
- gsave 0.8 setgray 0 0 1 1 rectfill grestore % provide background
- currentdict image
- showpage
- % Clean up.
- f closefile
- end
-} bind def
diff --git a/Master/tlpkg/tlgs/lib/viewpbm.ps b/Master/tlpkg/tlgs/lib/viewpbm.ps deleted file mode 100644 index 2811eac3eb5..00000000000 --- a/Master/tlpkg/tlgs/lib/viewpbm.ps +++ /dev/null @@ -1,184 +0,0 @@ -% Copyright (C) 1992, 1995, 1996, 1998, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: viewpbm.ps 6300 2005-12-28 19:56:24Z giles $
-% viewpbm.ps
-% Display a PBM/PGM/PPM file.
-% Requires the Level 2 `image' operator (to handle variable pixel widths).
-% If SCALE is defined, maps input pixels to output pixels with that scale;
-% if SCALE is undefined, scales the image to fit the page.
-
-/s 100 string def
-/readmaxv { % <file> readmaxv -
- 10 string readline pop cvx exec /maxv exch def
-} bind def
-/readrow { % <file> <row> readrow <row>
- 0 1 2 index length 1 sub {
- 1 index exch 3 index token pop put
- } for exch pop
-} bind def
-/read01 { % <file> <count> read01 <byte>
- 0 exch {
- 1 index read pop 48 xor dup 1 le { exch dup add add } { pop } ifelse
- } repeat
-} bind def
-/readrow01 { % <file> <row> readrow01 <row>
- 0 1 w 8 idiv {
- 1 index exch 3 index 8 read01 put
- } for
- wrem 0 ne {
- dup rsize 1 sub wrem read01 8 wrem sub bitshift put
- } if
- exch pop
-} bind def
-/readwh { % <file> readwh <w> <h>
- dup s readline pop % check for comment
- (#) anchorsearch {
- pop pop dup s readline pop
- } if
- cvx exec
-} bind def
-/pbmtypes mark
-% The procedures in this dictionary are called as
-% <file> Pn <w> <h> <readproc>
-/P1 { % ASCII 1-bit white/black
- /bpc 1 def /maxv 1 def /rsize w 7 add 8 idiv def
- /wrem w 8 mod def
- /ncomp 1 def /invert true def /DeviceGray setcolorspace
- readwh
- { readrow01 }
-} bind
-/P2 { % ASCII 8-bit gray
- readwh
- /bpc 8 def 2 index readmaxv /rsize 2 index def
- /ncomp 1 def /invert false def /DeviceGray setcolorspace
- { readrow }
-} bind
-/P3 { % ASCII 8-bit RGB
- readwh
- /bpc 8 def 2 index readmaxv /rsize 2 index 3 mul def
- /ncomp 3 def /invert false def /DeviceRGB setcolorspace
- { readrow }
-} bind
-/P4 { % Binary 1-bit white/black
- readwh
- /bpc 1 def /maxv 1 def /rsize 2 index 7 add 8 idiv def
- /ncomp 1 def /invert true def /DeviceGray setcolorspace
- { readstring pop }
-} bind
-/P5 { % Binary 8-bit gray
- readwh
- /bpc 8 def 2 index readmaxv /rsize 2 index def
- /ncomp 1 def /invert false def /DeviceGray setcolorspace
- { readstring pop }
-} bind
-/P6 { % Binary 8-bit RGB
- readwh
- /bpc 8 def 2 index readmaxv /rsize 2 index 3 mul def
- /ncomp 3 def /invert false def /DeviceRGB setcolorspace
- { readstring pop }
-} bind
-.dicttomark readonly def
-/pbmsetup { % <file> <w> <h> <readproc> runpbm -
- /readproc exch def
- /h exch def
- /w exch def
- /f exch def
- 20 dict begin % image dictionary
- /ImageType 1 def
- /Width w def
- /Height h def
- /ImageMatrix [w 0 0 h neg 0 h] def
- /BitsPerComponent bpc def
- /Decode [ 0 255 maxv div invert { exch } if ncomp 1 sub { 2 copy } repeat ] def
- /DataSource [ f rsize string /readproc load /exec load ] cvx def
- currentdict end
-} def
-/imagescale { % <imagedict> imagescale -
- begin
- /SCALE where {
- pop
- % Map pixels SCALE-for-1. Assume orthogonal transformation.
- Width 1 0 dtransform add abs div SCALE mul
- Height 0 1 dtransform add abs div SCALE mul
- } {
- % Scale the image (uniformly) to fit the page.
- clippath pathbbox pop pop translate
- pathbbox .min exch pop exch pop ceiling
- dup Height Width gt {
- Width mul Height div exch
- } {
- Height mul Width div
- } ifelse
- }
- ifelse scale
- end
-} def
-
-% Image a PBM file page by page.
-/viewpbm { % <filename> viewpbm -
- 20 dict begin
- (r) file /pf exch def {
- pf token not { exit } if
- pbmtypes exch get pf exch exec pbmsetup
- dup imagescale image showpage
- } loop
- end
-} def
-
-% Reassemble a composite PBM file from the CMYK separations.
-/viewpsm {
- 20 dict begin
- /fname exch def
- /sources [ 0 1 3 {
- /plane exch def
- /pf fname (r) file def
- pf pbmtypes pf token pop get exec
- % Stack: pf w h readproc
- plane {
- /readproc exch def /h exch def /w exch def pop
- /row rsize string def
- h { pf row readproc pop } repeat
- pf pbmtypes pf token pop get exec
- } repeat
- pbmsetup
- } for ] def
- /datas [ sources { /DataSource get 0 get } forall ] def
- /decode sources 0 get /Decode get
- dup 0 get exch 1 get add cvi 0 exch
- 2 copy 4 copy 8 array astore def
- sources 0 get
- dup /MultipleDataSources true put
- dup /DataSource datas put
- dup /Decode decode put
- /DeviceCMYK setcolorspace
- dup imagescale image showpage
- end
-} def
-
-% If the program was invoked from the command line, run it now.
-[ shellarguments
- { counttomark 1 ge
- { ] { viewpbm } forall
- }
- { cleartomark
- (Usage: gs [--] viewpbm.ps filename.p*m ...\n) print
- ( e.g.: gs [--] viewpbm.ps my.ppm another.ppm\n) print flush
- }
- ifelse
- }
- { pop
- }
-ifelse
diff --git a/Master/tlpkg/tlgs/lib/viewpcx.ps b/Master/tlpkg/tlgs/lib/viewpcx.ps deleted file mode 100644 index b2b7789b07d..00000000000 --- a/Master/tlpkg/tlgs/lib/viewpcx.ps +++ /dev/null @@ -1,150 +0,0 @@ -% Copyright (C) 1996, 1999 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: viewpcx.ps 6300 2005-12-28 19:56:24Z giles $
-% viewpcx.ps
-% Display a PCX file.
-% Requires the Level 2 `image' operator (to handle variable pixel widths).
-% If SCALE is defined, maps input pixels to output pixels with that scale;
-% if SCALE is undefined, scales the image to fit the page.
-% ****NOTE: does not handle multi-plane images with palette.
-
-/pcxbytes [
- 0 1 255 {
- 64 string exch 0 1 63 {
- 3 copy exch put pop
- } for pop
- } for
-] readonly def
-/readpcx { % - readpcx <str>
- f % gets replaced
- dup read not {
- pop ()
- } {
- dup 192 lt {
- ( ) dup 0 4 -1 roll put exch pop
- } {
- 192 sub //pcxbytes 3 -1 roll read pop get exch 0 exch getinterval
- } ifelse
- } ifelse
-} def
-/get2 % <string> <index> get2 <int>
- { 2 copy get 3 1 roll 1 add get 8 bitshift add
- } bind def
-/dsproc
- { df s readstring pop % s gets filled in
- s1 () ne { df s1 readstring pop pop } if % discard padding bytes
- } def % don't bind, must be writable
-/viewpcx % <filename> viewpcx -
- { 100 dict begin
- /fname 1 index def
- /f exch (r) file def
- % Read and unpack the header.
- /header f 128 string readstring pop def
- /version header 1 get def
- /bpp header 3 get def
- /w header 8 get2 header 4 get2 sub 1 add def
- /h header 10 get2 header 6 get2 sub 1 add def
- /nplanes header 65 get def
- /bpl header 66 get2 def
- /palinfo header 68 get2 def
- /nbits bpp nplanes mul def
- version 5 eq
- { nbits 8 le
- { /cspace
- [/Indexed /DeviceRGB 1 bpp bitshift 1 sub
- f fileposition
- 1 nbits bitshift 3 mul string
- fname status pop pop pop exch pop
- 1 index length sub f exch setfileposition
- f exch readstring pop
- exch f exch setfileposition
- ] def
- /decode [0 cspace 2 get] def
- }
- { /cspace /DeviceRGB def
- /decode [0 1 0 1 0 1] def
- }
- ifelse
- }
- { /cspace
- [/Indexed /DeviceRGB 1 bpp bitshift 1 sub
- header 16 1 nbits bitshift 16 .min 3 mul getinterval
- ] def
- /decode [0 cspace 2 get] def
- }
- ifelse
- % Set up scaling.
- /SCALE where
- { pop
- % Map pixels SCALE-for-1. Assume orthogonal transformation.
- w 1 0 dtransform add abs div SCALE mul
- h 0 1 dtransform add abs div SCALE mul
- }
- { % Scale the image (uniformly) to fit the page.
- clippath pathbbox pop pop translate
- pathbbox .min exch pop exch pop ceiling
- dup h w gt { w mul h div exch } { h mul w div } ifelse
- }
- ifelse scale
- % Since the number of bytes per line is always even,
- % it may not match the width specification.
- /wbpl w bpp mul 7 add 8 idiv def
- % Define the data source procedure.
- /s1 bpl wbpl sub string def
- /df /readpcx load copyarray dup 0 f put cvx bind readonly
- 0 () /SubFileDecode filter def
- /dsource [ nplanes
- { /dsproc load copyarray
- dup 1 wbpl string put
- cvx bind readonly
- }
- repeat ] def
- % Construct the image dictionary.
- 20 dict begin % image dictionary
- /ImageType 1 def
- /Width w def
- /Height h def
- /ImageMatrix [w 0 0 h neg 0 h] def
- /BitsPerComponent bpp def
- /Decode decode def
- /DataSource dsource dup length 1 gt
- { /MultipleDataSources true def }
- { 0 get }
- ifelse def
- currentdict end
- % Finally, display the image.
- cspace setcolorspace
- image
- showpage
- df closefile
- f closefile
- end
- } bind def
-
-% If the program was invoked from the command line, run it now.
-[ shellarguments
- { counttomark 1 ge
- { ] { viewpcx } forall
- }
- { cleartomark
- (Usage: gs -- viewpcx.ps filename.pcx ...\n) print
- ( e.g.: gs -- viewpcx.ps my.pcx another.pcx\n) print flush
- }
- ifelse
- }
- { pop
- }
-ifelse
diff --git a/Master/tlpkg/tlgs/lib/viewps2a.ps b/Master/tlpkg/tlgs/lib/viewps2a.ps deleted file mode 100644 index f20a2fb0636..00000000000 --- a/Master/tlpkg/tlgs/lib/viewps2a.ps +++ /dev/null @@ -1,32 +0,0 @@ -% Copyright (C) 1995 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: viewps2a.ps 6300 2005-12-28 19:56:24Z giles $
-% Display a file produced by ps2ascii with no switch or with -dCOMPLEX.
-% This is just a procset to read in before the file to display.
-
-/init { 0.1 0.1 scale } bind def
-init
-/next { currentfile token pop } bind def
-/F { next next pop next exch selectfont } bind def
-/P { showpage init } bind def
-/S
- { next next moveto
- next dup stringwidth pop next exch div
- gsave 1 scale show grestore
- } bind def
-/C { next next next setrgbcolor } bind def
-/I { next next next next gsave 0.75 setgray rectfill grestore } bind def
-/R { next next next next rectfill } bind def
diff --git a/Master/tlpkg/tlgs/lib/wftopfa.ps b/Master/tlpkg/tlgs/lib/wftopfa.ps deleted file mode 100644 index df0451f9f4f..00000000000 --- a/Master/tlpkg/tlgs/lib/wftopfa.ps +++ /dev/null @@ -1,303 +0,0 @@ -% Copyright (C) 1995, 1996 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: wftopfa.ps 6300 2005-12-28 19:56:24Z giles $
-% wftopfa.ps
-% Convert a Wadalab base font to .PFA (or .PFB) format.
-
-(gs_ksb_e.ps) runlibfile
-(wrfont.ps) runlibfile
-
-/wftopfa_dict 100 dict def
-wftopfa_dict begin
-
-/KanjiSubEncoding dup .findencoding def
-
-% Initialize parameters.
-/init % - init -
- { /chars 256 dict def
- /version (001.001) def
- /highcode 0 def
- /StdHW [32] def
- /StdVW [32] def
- /UniqueID 20000000 def
- /FontBase (Wadalab) def
- /StdEncMode false def
- /CustomEncMode false def
- /Binary false def
- /Encrypt true def
- } bind def
-
-% Read definitions.
-/rdstring 5000 string def
-/readdefs % <filename> readdefs -
- { (r) file
- { dup rdstring readline not { pop exit } if
- dup length 15 ge
- { dup dup length 7 sub 7 getinterval (> CompD) eq
- { token pop exch token pop exch pop
- dup 0 get /highcode exch def
- exch chars 3 1 roll put
- }
- { pop
- }
- ifelse
- }
- { pop
- }
- ifelse
- }
- loop closefile
- } bind def
-
-% Write out the final font.
-/writepfa
- { 4 string highcode 16#1000 add 16 2 index cvrs 0 (.r) putinterval
- FontBase exch concatstrings /fullname exch def
- UniqueID 20000000 eq { /UniqueID 4990000 highcode add def } if
- /encoding CustomEncMode
- { KanjiSubEncoding }
- { StdEncMode { StandardEncoding } { ISOLatin1Encoding } ifelse }
- ifelse def
-
- /Font 30 dict def
- Font begin
- /FontInfo 20 dict def
- FontInfo begin
-
- % Write the clear text part.
-
- /CreationDate (%Calendar%) currentdevparams
- dup /Weekday get {(Sun )(Mon )(Tue )(Wed )(Thu )(Fri )(Sat )} exch get
- 1 index /Month get 1 sub
- {(Jan)(Feb)(Mar)(Apr)(May)(Jun)(Jul)(Aug)(Sep)(Oct)(Nov)(Dec)} exch get
- concatstrings
- {{/Day ( )} {/Hour ( )} {/Minute (:)} {/Second (:)} {/Year ( )}}
- { dup 1 get 3 -1 roll exch concatstrings exch
- 0 get 2 index exch get
- dup 10 lt { =string cvs (0) exch concatstrings } { =string cvs } ifelse
- concatstrings
- }
- forall exch pop readonly def
- /VMusage 100000 def
- /version version readonly def
- /Notice (No copyright on this font. Original available from moe.ipl.t.u-tokyo.ac.jp:/Font. Converted by wftopfa.ps (Aladdin Enterprises).) readonly def
- /FullName fullname readonly def
- /FamilyName FontBase readonly def
- /Weight (Regular) readonly def
- /ItalicAngle 0 def
- /isFixedPitch true def
- /UnderlinePosition 0 def
- /UnderlineThickness 0 def
-
- end % FontInfo
-
- /FontName fullname cvn def
- /Encoding encoding def
- /PaintType 0 def
- /FontType 1 def
- /FontMatrix [.001 0 0 .001 0 -0.16] readonly def
- /UniqueID UniqueID def
- /FontBBox [0 0 1000 1000] readonly def
-
- /Private 20 dict def
- Private begin
-
- /-| {string currentfile exch readstring pop} readonly def
- /|- {readonly def} readonly def
- /| {readonly put} readonly def
- /BlueValues [] readonly def
- /OtherBlues [] readonly def
- /MinFeature {16 16} readonly def
- /StdHW StdHW def
- /StdVW StdVW def
- /ForceBold false def
- /password 5839 def
- /UniqueID UniqueID def
- /OtherSubrs [] readonly def
- /Subrs [
- (\020\2771p|\020\024\020=-\223D\\\342R) readonly
- (\020\2771py\274\366Uz) readonly
- (\020\2771py\275\304\236i) readonly
- (\020\2771p\371) readonly
- (\020\2771p~\266+6\034\3446z) readonly
- ] readonly def
-
- end % Private
-
- /CharStrings 256 dict def
- chars
- { exch =string cvs
- dup 0 get highcode eq
- { 1 get encoding exch get exch CharStrings 3 1 roll put }
- { pop pop }
- ifelse
- }
- forall
-
- end % Font
-
- Font /FontName get Font definefont setfont
- (%stdout) (w) file writefont
- } bind def
-
-% Scan the command line and process files.
-/options mark
- /version { 2 copy get /version exch def 1 add } bind
- /StdHW { 2 copy get cvx exec /StdHW exch def 1 add } bind
- /StdVW { 2 copy get cvx exec /StdVW exch def 1 add } bind
- /UniqueId { 2 copy get cvi /UniqueID exch def 1 add } bind
- /UniqueID 1 index
- /FontBase { 2 copy get /FontBase exch def 1 add } bind
- /StdEnc { /StdEncMode true def } bind
- /CustomEnc { /CustomEncMode true def } bind
- /Binary { /Binary true def } bind
- /noEncrypt { /Encrypt false def } bind
-.dicttomark def
-/wftopfa % [(arg1) ...] wftopfa -
- { init dup 0
- { dup 2 index length ge { exit } if
- 2 copy get exch 1 add exch
- options 1 index .knownget { exch pop exec } { readdefs } ifelse
- }
- loop pop pop
- wrfont_dict /binary_CharStrings Binary put
- wrfont_dict /eexec_encrypt Encrypt put
- wrfont_dict /name_all_Encodings CustomEncMode put
- writepfa
- } bind def
-
-end % wftopfa_dict
-
-/wftopfa
- { mark exch wftopfa_dict begin /saved save def { wftopfa } exec false%stopped
- { cleartomark true } { cleartomark false } ifelse
- saved end restore { stop } if
- } bind def
-
-[ shellarguments
- { ] wftopfa }
- { pop }
-ifelse
-
-% ---------------- Root font ---------------- %
-
-% Define the Encoding for the root font.
-/wfrootencoding
-% \x00-\x3F
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
- 0 1 2 3 4 5 6 7 8 0 0 0 0 0 0 0
- 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
-% \x40-\x7F
- 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
- 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56
- 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72
- 73 74 75 76 77 0 0 0 0 0 0 0 0 0 0 0
-% \x80-\xFF
-128 copy
-256 packedarray def
-
-% Define the template for the root font dictionary.
-/wfrootfontdict mark
- /FontType 0
- /FontMatrix [1 0 0 1 0 0]
- /FMapType 2
- /Encoding wfrootencoding
-.dicttomark def
-
-% Define a dummy (placeholder) Type 1 font for the FDepVector.
-/type1dummyfont % <fontname> type1dummyfont <font>
- { mark /FontName 3 -1 roll
- /FontType 1
- /FontMatrix [.001 0 0 .001 0 0]
- /FontBBox [0 0 1000 1000]
- /Encoding /KanjiSubEncoding findencoding
- /CharStrings 0 dict
- /Private mark /BlueValues [] /password 5839 .dicttomark
- .dicttomark dup /FontName get exch definefont
- } bind def
-
-% Write a root font. Again, wrfont.ps does most of the work.
-/makerootfont % <rootname> makerootfont <font>
- { wfrootfontdict dup length 4 add % FontName, FDepVector, PrefEnc, FID
- dict copy begin
- cvlit /FontName exch def
- 4 dict begin
- /len FontName length def
- /str len 4 add string def
- FontName str cvs pop
- str len (.r) putinterval
- /FDepVector [ 16#21 1 16#74
- { dup wfrootencoding exch get 0 eq
- { pop
- }
- { 16 str len 2 add 2 getinterval cvrs pop
- str cvn type1dummyfont
- }
- ifelse
- }
- for end counttomark -1 roll dup counttomark 2 roll
- ] def
- FontName currentdict end definefont
- } bind def
-/writerootfont % <rootname> writerootfont -
- { save exch makerootfont setfont (%stdout) (w) file writefont restore
- } bind def
-
-% ---------------- Converting entire fonts ---------------- %
-
-% Define the directory where the Wadalab fonts are stored.
-/wfdir (/home/ghost/kanji/w) def
-
-% Convert an entire Wadalab font.
-/writeentirefont % <fontname> <template*> writeentirefont -
- { 2 dict begin
- /templates exch def
- /fontname exch def
- [ templates
- { wfdir (/) concatstrings exch concatstrings { copystring }
- 8192 string filenameforall
- }
- forall
- wfdir (/wadalab-sym/*.ps) concatstrings { copystring }
- 8192 string filenameforall
- ]
- (%!\n) print
- { /currentuserparams where
- { pop currentuserparams /VMReclaim get -2 vmreclaim { vmreclaim } }
- { { } }
- ifelse
- } == (exec\n) print
- (/KanjiSubEncoding ) print /KanjiSubEncoding findencoding ==
- (readonly def\n) print
- { (%stderr) (w) file dup 2 index write== flushfile
- mark exch (CustomEnc) (Binary) (noEncrypt)
- (FontBase) fontname counttomark -1 roll ] wftopfa
- }
- forall
- fontname cvn writerootfont
- (exec\n) print
- end
- } def % don't bind, so we can print the procedure
-
-% Convert the Wadalab JIS 1&2 SaiMincho font.
-% To invoke this from the command line,
-% gs -dNODISPLAY -q wftopfa.ps -c writeSaiMincho0 flush quit >wmin0.ps
-% To make the resulting font loadable on demand, add to the Fontmap file:
-% /Wadalab-SaiMincho (wmin0.ps) ;
-/writeSaiMincho0
- { (Wadalab-SaiMincho) [ (wadalab-mincho-0-8/*.ps) ] writeentirefont
- } bind def
diff --git a/Master/tlpkg/tlgs/lib/winmaps.ps b/Master/tlpkg/tlgs/lib/winmaps.ps deleted file mode 100644 index a386f5a4647..00000000000 --- a/Master/tlpkg/tlgs/lib/winmaps.ps +++ /dev/null @@ -1,106 +0,0 @@ -% Copyright (C) 1993 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: winmaps.ps 6855 2006-06-14 21:03:34Z giles $
-% winmaps.ps - make maps between PostScript encodings and Windows
-% character sets.
-
-% Define the two Windows encodings.
-
-/ANSIEncoding
- ISOLatin1Encoding 256 array copy
- dup 16#90 /.notdef put
- 16#93 1 16#9f { 2 copy /.notdef put pop } for
-def
-
-/OEMEncoding [
- /.notdef /.notdef /.notdef /heart /diamond /club /spade /bullet
- 8 { /.notdef } repeat
- /.notdef /.notdef /.notdef /.notdef /paragraph /section /.notdef /.notdef
- /arrowup /arrowdown /arrowright /arrowleft /.notdef /arrowboth /.notdef /.notdef
- StandardEncoding 32 96 getinterval aload pop
- /Ccedilla /udieresis /eacute /acircumflex /adieresis /agrave /aring /ccedilla
- /ecircumflex /edieresis /egrave /idieresis /igrave /Adieresis /Aring
- /Eacute /ae /AE /ocircumflex /odieresis /ograve /ucircumflex /ugrave
- /ydieresis /Odieresis /Udieresis /cent /sterling /yen /.notdef /florin
- /aacute /iacute /oacute /uacute /ntilde /Ntilde /ordfeminine /ordmasculine
- /questiondown /.notdef /logicalnot /onehalf /onequarter /exclamdown /guillemotleft /guillemotright
- 48 { /.notdef } repeat
- /alpha /beta /Gamma /Pi /Sigma /sigma /mu /tau
- /Phi /Theta /Omega /delta /infinity /phi /element /intersection
- /equivalence /plusminus /greaterequal /lessequal /integraltp /integralbt /divide /.notdef
- /degree /dotmath /periodcentered /radical /.notdef /twosuperior /.notdef /.notdef
-] def
-
-% Utility procedures
-
-/invertencoding % <array> invertencoding <dict>
- { 256 dict exch dup length 1 sub -1 0
- { % stack: dict array index
- 2 copy get /.notdef ne
- { 2 copy get exch 3 index 3 1 roll put }
- { pop }
- ifelse
- } for
- pop
- } def
-
-/pmarray 256 array def
-/printmap % <chars> <decode> printmap -
- { mark 3 1 roll exch
- { 2 copy known { 1 index exch get } { pop 0 } ifelse exch
- }
- forall pop
- pmarray 0 counttomark 2 sub getinterval astore
- ([) print dup length =only 0 exch (] = {\n ) exch
- { exch print =only
- 1 add 15 and dup 0 eq { (,\n ) } { (, ) } ifelse
- }
- forall pop pop (\n};\n) print pop
- } def
-
-/decodeStd StandardEncoding invertencoding def
-/decodeISO ISOLatin1Encoding
- % Remove the redundant characters
- dup length array copy
- [8#222 8#225 8#230 8#233 8#240] { 2 copy /.notdef put pop } forall
-invertencoding def
-/decodeSym SymbolEncoding invertencoding def
-
-/decodeANSI ANSIEncoding invertencoding def
-/decodeOEM OEMEncoding invertencoding def
-
-% Construct the map from Symbol to OEM.
-
-(\nprivate const byte far_data gs_map_symbol_to_oem) print
-SymbolEncoding decodeOEM printmap
-
-% Construct the map from ISOLatin1 to OEM.
-
-(\nprivate const byte far_data gs_map_iso_to_oem) print
-ISOLatin1Encoding decodeOEM printmap
-
-% Construct the map from Standard to ISOLatin1.
-
-(\nprivate const byte far_data gs_map_std_to_iso) print
-StandardEncoding decodeISO printmap
-
-% Construct the map from ISOLatin1 to Standard.
-% The Windows driver doesn't need this, but the X11 driver does.
-
-(\nprivate const byte far_data gs_map_iso_to_std) print
-ISOLatin1Encoding decodeStd printmap
-
-quit
diff --git a/Master/tlpkg/tlgs/lib/wrfont.ps b/Master/tlpkg/tlgs/lib/wrfont.ps deleted file mode 100644 index 5d062143863..00000000000 --- a/Master/tlpkg/tlgs/lib/wrfont.ps +++ /dev/null @@ -1,665 +0,0 @@ -% Copyright (C) 1991, 1995, 1996, 2002 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: wrfont.ps 6300 2005-12-28 19:56:24Z giles $
-% wrfont.ps
-% Write out a Type 1 font in readable, reloadable form.
-% Note that this does NOT work on protected fonts, such as Adobe fonts
-% (unless you have loaded unprot.ps first, in which case you may be
-% violating the Adobe license).
-
-% ****** NOTE: This file must be kept consistent with gs_pfile.ps.
-
-/wrfont_dict 100 dict def
-wrfont_dict begin
-
-% ------ Options ------ %
-
-% Define whether to use eexec encryption for the font.
-% eexec encryption is only useful for compatibility with Adobe Type Manager
-% and other programs; it only slows Ghostscript down.
- /eexec_encrypt false def
-
-% Define whether to write out the CharStrings in binary or in hex.
-% Binary takes less space on the file, but isn't guaranteed portable.
- /binary_CharStrings false def
-
-% Define whether to use binary token encodings when possible.
-% Binary tokens are smaller and load faster, but are a Level 2 feature.
- /binary_tokens false def
-
-% Define whether to encrypt the CharStrings on the file. (CharStrings
-% are always encrypted in memory.) Unencrypted CharStrings load about
-% 20% slower, but make the files compress much better for transport.
- /encrypt_CharStrings true def
-
-% Define whether the font must provide standard PostScript language
-% equivalents for any facilities it uses that are provided in Ghostscript
-% but are not part of the standard PostScript language.
- /standard_only true def
-
-% Define the value of lenIV to use in writing out the font.
-% use_lenIV = 0 produces the smallest output, but this may not be
-% compatible with old Adobe interpreters. use_lenIV = -1 means
-% use the value of lenIV from the font.
- /use_lenIV -1 def
-
-% Define whether to produce the smallest possible output, relying
-% as much as possible on Ghostscript-specific support code.
-% Taking full advantage of this requires the following settings:
-% binary_CharStrings = true, binary_tokens = true, standard_only = false.
- /smallest_output false def
-
-% Define whether to write out all currently known Encodings by name,
-% or only StandardEncoding and ISOLatin1Encoding.
- /name_all_Encodings false def
-
-% ---------------- Runtime support ---------------- %
-
-/.packedfilefilter where
- { pop }
- { (gs_pfile.ps) runlibfile }
-ifelse
-
-% ------ Output utilities ------ %
-
-% By convention, the output file is named psfile.
-
-% Define some utilities for writing the output file.
- /wtstring 2000 string def
- /wb {psfile exch write} bind def
- /wnb {/wb load repeat} bind def
- /w1 {psfile exch write} bind def
- /ws {psfile exch writestring} bind def
- /wl {ws (\n) ws} bind def
- /wt {wtstring cvs ws ( ) ws} bind def
- /wd % Write a dictionary.
- { dup length wo {dict dup begin} wol { we } forall
- {end} wol
- } bind def
- /wld % Write a large dictionary more efficiently.
- % Ignore the readonly attributes.
- { dup length wo {dict dup begin} wol
- 0 exch
- { exch wo wo () wl
- 1 add dup 200 eq
- { wo ({def} repeat) wl 0 }
- if
- }
- forall
- dup 0 ne
- { wo ({def} repeat) wl }
- { pop }
- ifelse
- (end) ws
- } bind def
- /we % Write a dictionary entry.
- { exch wo wo /def cvx wo (\n) ws
- } bind def
- /wcs % Write a CharString (or Subrs entry)
- { dup type /stringtype eq
- { 4330 exch changelenIV 0 ge
- { % Add some leading garbage bytes.
- wtstring changelenIV 2 index length getinterval
- .type1decrypt exch pop
- wtstring exch 0 exch length changelenIV add getinterval
- }
- { % Drop some leading garbage bytes.
- wtstring .type1decrypt exch pop
- changelenIV neg 1 index length 1 index sub getinterval
- }
- ifelse
- binary_tokens encrypt_CharStrings and
- { % Suppress recognizing the readonly status of the string.
- 4330 exch dup .type1encrypt exch pop wo
- }
- { encrypt_CharStrings
- { 4330 exch dup .type1encrypt exch pop
- } if
- smallest_output
- { wo
- }
- { readonly dup length wo
- binary_tokens not { ( ) ws } if
- readproc ws wx
- }
- ifelse
- }
- ifelse
- }
- { wo % PostScript procedure
- }
- ifelse
- } bind def
-
-% Construct the inversion of the system name table.
- (\210\001) token pop exch pop 1 eq { % i.e., do we have binary tokens?
- /snit 256 dict def
- 0 1 255 {
- (\221 ) dup 1 3 index put
- { token } stopped {
- pop pop
- } {
- % Stack: char () token true
- pop exch pop exch snit 3 1 roll put
- } ifelse
- } for
- } {
- /snit 1 dict def
- } ifelse
-
-% Write an object, using binary tokens if requested and possible.
- /woa % write in ascii
- { psfile exch write==only
- } bind def
-
- % Lookup table for ASCII output.
-
- /intbytes % int nbytes -> byte*
- { { dup 255 and exch -8 bitshift } repeat pop
- } bind def
- /wotta 10 dict dup begin
- { /booleantype /integertype }
- { { ( ) ws woa } def }
- forall
- % Iterate over arrays so we can print operators.
- /arraytype
- { dup xcheck {(}) ({)} {(]) ([)} ifelse ws exch dup wol exch ws wop
- } bind def
- /dicttype
- { ( ) ws wd } def
- /nametype
- { dup xcheck { ( ) ws } if woa
- } bind def
- % Map back operators to their names,
- % so we can write procedures.
- /nulltype
- { pop ( null) ws
- } bind def
- /operatortype
- { wtstring cvs cvn cvx wo
- } bind def
- % Convert reals to integers if possible.
- /realtype
- { dup cvi 1 index eq { cvi wo } { ( ) ws woa } ifelse
- } bind def
- % == truncates strings longer than 200 characters!
- /stringtype
- { (\() ws dup
- { dup dup 32 lt exch 127 ge or
- { (\\) ws dup -6 bitshift 48 add w1
- dup -3 bitshift 7 and 48 add w1
- 7 and 48 add
- }
- { dup dup -2 and 40 eq exch 92 eq or {(\\) ws} if
- }
- ifelse w1
- }
- forall
- (\)) ws wop
- } bind def
- /packedarraytype
- { ([) ws dup { wo } forall
- encodingnames 1 index known
- % This is an encoding, but not one of the standard ones.
- % Use the built-in encoding only if it is available.
- { encodingnames exch get wo
- ({findencoding}stopped{pop) ws
- (}{counttomark 1 add 1 roll cleartomark}ifelse)
- }
- { pop ()
- }
- ifelse
- (/packedarray where{pop counttomark packedarray exch pop}{]readonly}ifelse) ws
- wl
- }
- def
- end def
-
- % Lookup table for binary output.
-
- /wottb 8 dict dup begin
- wotta currentdict copy pop
- /integertype
- { dup dup 127 le exch -128 ge and
- { 136 wb 255 and wb }
- { dup dup 32767 le exch -32768 ge and
- { 134 wb 2 intbytes wb wb }
- { 132 wb 4 intbytes wb wb wb wb }
- ifelse
- }
- ifelse
- } bind def
- /nametype
- { dup snit exch known
- { dup xcheck { 146 } { 145 } ifelse wb
- snit exch get wb
- }
- { wotta /nametype get exec
- }
- ifelse
- } bind def
- /stringtype
- { dup dup length dup 255 le { 142 2 } { 2 intbytes 143 3 } ifelse wnb
- ws wop
- } bind def
- end def
-
- /wop % Write object protection
- { wcheck not { /readonly cvx wo } if
- } bind def
- /wo % Write an object.
- { dup type binary_tokens { wottb } { wotta } ifelse
- exch get exec
- } bind def
- /wol % Write a list of objects.
- { { wo } forall
- } bind def
-
-% Write a hex string for Subrs or CharStrings.
- /wx % string ->
- { binary_CharStrings
- { ws
- }
- { % Some systems choke on very long lines, so
- % we break up the hexstring into chunks of 50 characters.
- { dup length 25 le {exit} if
- dup 0 25 getinterval psfile exch writehexstring (\n) ws
- dup length 25 sub 25 exch getinterval
- } loop
- psfile exch writehexstring
- } ifelse
- } bind def
-
-% ------ CharString encryption utilities ------ %
-
-/enc_dict 20 dict def
-1 dict begin
-/bind { } def % make sure we can print out the procedures
-enc_dict begin
-
-(type1enc.ps) runlibfile
-enc_dict /.type1decrypt undef % we don't need this
-
-end end
-
-enc_dict { 1 index where { pop pop pop } { def } ifelse } forall
-
-% ------ Other utilities ------ %
-
-% Test whether two values are equal (for default dictionary entries).
- /valueeq % <obj1> <obj2> valueeq <bool>
- { 2 copy eq
- { pop pop true }
- { % Special hack for comparing FontMatrix values
- dup type /arraytype eq 2 index type /arraytype eq and
- { dup length 2 index length eq
- { true 0 1 3 index length 1 sub
- { % Stack: arr1 arr2 true index
- 3 index 1 index get 3 index 3 -1 roll get eq not
- { pop false exit }
- if
- }
- for 3 1 roll pop pop
- }
- { pop pop false
- }
- ifelse
- }
- { pop pop false
- }
- ifelse
- }
- ifelse
- } bind def
-
-% ------ The main program ------ %
-
-% Define the dictionary of keys to skip because they are treated specially.
-/.fontskipkeys mark
- /CharStrings dup
- /Encoding dup
- /FDepVector dup
- /FID dup
- /FontInfo dup
- /Metrics dup
- /Metrics2 dup
- /Private dup
-.dicttomark def
-/.minfontskipkeys mark
- .fontskipkeys { } forall
- /FontName dup
- /UniqueID dup
-.dicttomark def
-/.privateskipkeys mark
- /ND dup
- /NP dup
- /RD dup
- /Subrs dup
-.dicttomark def
-/.minprivateskipkeys mark
- .privateskipkeys { } forall
- /MinFeature dup
- /Password dup
- /UniqueID dup
-.dicttomark def
-
-% Define the procedures for the Private dictionary.
-% These must be defined without `bind',
-% for the sake of the DISKFONTS feature.
-4 dict begin
- /-! {string currentfile exch readhexstring pop} def
- /-| {string currentfile exch readstring pop} def
- /|- {readonly def} def
- /| {readonly put} def
-currentdict end /encrypted_procs exch def
-4 dict begin
- /-! {string currentfile exch readhexstring pop
- 4330 exch dup .type1encrypt exch pop} def
- /-| {string currentfile exch readstring pop
- 4330 exch dup .type1encrypt exch pop} def
- /|- {readonly def} def
- /| {readonly put} def
-currentdict end /unencrypted_procs exch def
-
-% Construct an inverse dictionary of encodings.
-/encodingnames mark
- StandardEncoding /StandardEncoding
- ISOLatin1Encoding /ISOLatin1Encoding
- SymbolEncoding /SymbolEncoding
- DingbatsEncoding /DingbatsEncoding
- /resourceforall where
- { pop (*) { cvn dup findencoding exch } 100 string /Encoding resourceforall }
- if
-.dicttomark def
-
-% Invert the standard encodings.
-.knownEncodings length 256 mul dict begin
- 0 .knownEncodings
- { { currentdict 1 index known { pop } { 1 index def } ifelse
- 1 add
- }
- forall
- }
- forall pop
-currentdict end /inverseencodings exch def
-
-/writefont % <psfile> writefont - (writes the current font)
- { /psfile exch def
- /Font currentfont def
- /FontInfo Font /FontInfo .knownget not { 0 dict } if def
- /FontType Font /FontType get def
- /hasPrivate Font /Private known def
- /Private hasPrivate { Font /Private get } { 0 dict } ifelse def
- /readproc binary_CharStrings { (-| ) } { (-! ) } ifelse def
- /privateprocs
- encrypt_CharStrings binary_tokens not and
- { encrypted_procs } { unencrypted_procs } ifelse
- def
- /addlenIV false def
- /changelenIV use_lenIV 0 lt
- { 0 }
- { use_lenIV Private /lenIV .knownget not
- { 4 /addlenIV use_lenIV 4 ne def } if sub }
- ifelse def
- /minimize
- smallest_output
- FontType 1 eq and
- Font /UniqueID known and
- def
- (%!FontType) ws FontType wtstring cvs ws (-1.0: ) ws
- currentfont /FontName get wt
- FontInfo /version .knownget not { (001.001) } if wl
- FontInfo /CreationDate .knownget { (%%Creation Date: ) ws wl } if
- FontInfo /VMusage .knownget
- { (%%VMusage: ) ws dup wt wtstring cvs wl }
- if
- (systemdict begin) wl
-
-% If we're going to use eexec, create the filters now.
- /realpsfile psfile def
- eexec_encrypt
- { /eexecfilter psfile binary_CharStrings not
- { pop /bxstring 35 string def
- { pop dup length 0 ne
- { realpsfile exch writehexstring realpsfile (\n) writestring }
- { pop }
- ifelse bxstring
- }
- /NullEncode filter dup /hexfilter exch def
- }
- if 55665 /eexecEncode filter def
- }
- if
-
-% Turn on binary tokens if relevant.
- binary_tokens { (currentobjectformat 1 setobjectformat) wl } if
-
-% If the file has a UniqueID, write out a check against loading it twice.
- minimize
- { Font /FontName get wo
- Font /UniqueID get wo
- Private length addlenIV { 1 add } if wo
- Font length 1 add wo % +1 for FontFile
- ( .checkexistingfont) wl
- }
- { Font /UniqueID known
- { ({} FontDirectory) ws Font /FontName get dup wo ( known) wl
- ( {) ws wo ( findfont dup /UniqueID known) wl
- ( { dup /UniqueID get) ws Font /UniqueID get wo ( eq exch /FontType get 1 eq and }) wl
- ( { pop false } ifelse) wl
- ( { pop save /restore load } if) wl
- ( } if) wl
- }
- if
- }
- ifelse
-
-% If we are writing unencrypted CharStrings for a standard environment,
-% write out the encryption procedures.
- privateprocs unencrypted_procs eq standard_only and
- { (systemdict /.type1encrypt known) wl
- ( { save /restore load } { { } } ifelse) wl
- (userdict begin) wl
- enc_dict { we } forall
- (end exec) wl
- }
- if
-
-% Write out the creation of the font dictionary and FontInfo.
- minimize not
- { Font length 1 add wo {dict begin} wol % +1 for FontFile
- }
- if
- (/FontInfo ) ws FontInfo wd {readonly def} wol
-
-% Write out the other fixed entries in the font dictionary.
- Font begin
- Font
- { minimize
- { .minfontskipkeys 2 index known
- { pop pop
- }
- { //.compactfontdefault 2 index .knownget
- { 1 index valueeq { pop pop } { we } ifelse }
- { we }
- ifelse
- }
- ifelse
- }
- { .fontskipkeys 2 index known { pop pop } { we } ifelse
- }
- ifelse
- } forall
- /Encoding
- encodingnames Encoding known
- name_all_Encodings
- Encoding StandardEncoding eq or
- Encoding ISOLatin1Encoding eq or and
- { encodingnames Encoding get cvx }
- { Encoding }
- ifelse
- dup /StandardEncoding cvx eq minimize and
- { pop pop }
- { we }
- ifelse
-
-% Write the FDepVector, if any.
- Font /FDepVector .knownget
- { {/FDepVector [} wol
- { /FontName get wo {findfont} wol () wl } forall
- {] readonly def} wol
- }
- if
-
-% Write out the Metrics, if any.
- Font /Metrics .knownget
- { (/Metrics ) ws wld {readonly def} wol
- }
- if
- Font /Metrics2 .knownget
- { (/Metrics2 ) ws wld {readonly def} wol
- }
- if
-
-% Start the eexec-encrypted section, if applicable.
- eexec_encrypt
- { {currentdict currentfile eexec} wol () wl
- /psfile eexecfilter store
- (\000\000\000\000) ws {begin} wol
- }
- if
-
-% Create and initialize the Private dictionary, if any.
- hasPrivate
-{
- Private
- minimize
- { begin {Private dup begin}
- }
- { dup length privateprocs length add dict copy begin
- privateprocs { readonly def } forall
- /Private wo
- currentdict length 1 add wo {dict dup begin}
- }
- ifelse wol () wl
- currentdict
- { 1 index minimize { .minprivateskipkeys } { .privateskipkeys } ifelse
- exch known
- { pop pop }
- { 1 index /lenIV eq use_lenIV 0 ge and { pop use_lenIV } if we }
- ifelse
- } forall
- addlenIV { /lenIV use_lenIV we } if
-}
-if
-
-% Write the Subrs entries, if any.
- currentdict /Subrs known
- { (/Subrs[) wl
- Subrs
- { dup null ne
- { wcs minimize not { () wl } if }
- { pop /null cvx wo }
- ifelse
- } forall
- {] dup {readonly pop} forall readonly def} wol () wl
- }
- if
-
-% Wrap up the Private dictionary.
- hasPrivate
- { end % Private
- minimize
- { {end readonly pop} } % Private
- { {end readonly def} } % Private in font
- ifelse wol
- }
- if
-
-% Write the CharStrings entries.
-% Detect identical (eq) entries, which bdftops produces.
- currentdict /CharStrings known
-{
- /CharStrings wo CharStrings length wo
- minimize
- { encrypt_CharStrings not wo ( .readCharStrings) wl
- CharStrings length dict
- CharStrings
- { exch inverseencodings 1 index .knownget not { dup } if wo
- % Stack: vdict value key
- 3 copy pop .knownget { wo pop pop } { 3 copy put pop wcs } ifelse
- } forall
- }
- { {dict dup Private begin begin} wol () wl
- CharStrings length dict
- CharStrings
- { 2 index 1 index known
- { exch wo 1 index exch get wo {load def} wol () wl
- }
- { 2 index 1 index 3 index put
- exch wo wcs ( |-) wl
- }
- ifelse
- } forall
- {end end} wol
- }
- ifelse
- pop
- { readonly def } % CharStrings in font
- wol
-}
-if
-
-% Terminate the output.
- end % Font
- eexec_encrypt
- { {end mark currentfile closefile} wol () wl
- eexecfilter dup flushfile closefile % psfile is eexecfilter
- binary_CharStrings not { hexfilter dup flushfile closefile } if
- /psfile realpsfile store
- 8
- { (0000000000000000000000000000000000000000000000000000000000000000)
- wl
- }
- repeat {cleartomark} wol
- }
- if
- { FontName currentdict end definefont pop
- }
- wol
- Font /UniqueID known { /exec cvx wo } if
- binary_tokens { /setobjectformat cvx wo } if
- ( end) wl % systemdict
-
- } bind def
-
-% ------ Other utilities ------ %
-
-% Prune garbage characters and OtherSubrs out of the current font,
-% if the relevant dictionaries are writable.
-/prunefont
- { currentfont /CharStrings get wcheck
- { currentfont /CharStrings get dup [ exch
- { pop dup (S????00?) .stringmatch not { pop } if
- } forall
- ] { 2 copy undef pop } forall pop
- }
- if
- } bind def
-
-end % wrfont_dict
-
-/writefont { wrfont_dict begin writefont end } def
diff --git a/Master/tlpkg/tlgs/lib/xlatmap b/Master/tlpkg/tlgs/lib/xlatmap deleted file mode 100644 index f5369e426ce..00000000000 --- a/Master/tlpkg/tlgs/lib/xlatmap +++ /dev/null @@ -1,49 +0,0 @@ -% xlatmap - the map of translation tables for various kinds of fonts.
-%
-% It specifies Decoding resources to be used with FAPI-handled fonts.
-% If a font contains multiple character mapping tables, this gives
-% priorities for choosing a specific table from the font according to
-% the order of entries of this map.
-
-% This file is intended to be customized by users. Please keep the
-% obvious format of this file. Strings and names must not be empty
-% and must not contain null ('\0') characters.
-
-% $Id: xlatmap 6797 2006-05-23 07:13:03Z leonardo $
-
-% The map contains entries for each kind of font being handled by
-% any font rendering plugin. The key of an entry is the font type
-% and the value is array of pairs.
-% The first element of pair is a string which encodes identifier of
-% character mapping table. The format of the first element depends
-% on the font type, and should be recognized by the font rendering
-% plugins. The second element is name of the Decoding resource. If
-% that resource is not available, definefont will fail. Note that
-% currently we supply insufficient decoding resources, as well as
-% insufficient entries in this map.
-
-/TrueType
-[ % Each entry is pair :
- % a string PlatformID.SpecificID and a name of Decoding resource.
- (3.0) /Symbol % Symbol
- (3.1) /Unicode % Unicode
- (3.2) /ShiftJIS % Japanese
- (3.3) /PRC % Simplified Chinese, GB2312
- (3.4) /Big5 % Traditional Chinese
- (3.5) /Wansung % Korean
- (3.6) /Johab % Korean
- % todo : add more entries
-]
-
-/PostScript
-[ % Since PostScript fonts were designed especially for PostScript,
- (*) /Unicode % fixme : other charsets
-]
-
-/Intellifont
-[ (*) /FCO_Unicode % fixme : other charsets
-]
-
-/Microtype
-[ (*) /FCO_Unicode % FCOfontmap may may overwrite this for a specific font.
-]
diff --git a/Master/tlpkg/tlgs/lib/zeroline.ps b/Master/tlpkg/tlgs/lib/zeroline.ps deleted file mode 100644 index 848774e22ab..00000000000 --- a/Master/tlpkg/tlgs/lib/zeroline.ps +++ /dev/null @@ -1,100 +0,0 @@ -%!
-% Copyright (C) 1994 Aladdin Enterprises. All rights reserved.
-%
-% This software is provided AS-IS with no warranty, either express or
-% implied.
-%
-% This software is distributed under license and may not be copied,
-% modified or distributed except as expressly authorized under the terms
-% of the license contained in the file LICENSE in this distribution.
-%
-% For more information about licensing, please refer to
-% http://www.ghostscript.com/licensing/. For information on
-% commercial licensing, go to http://www.artifex.com/licensing/ or
-% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
-% San Rafael, CA 94903, U.S.A., +1(415)492-9861.
-
-% $Id: zeroline.ps 6300 2005-12-28 19:56:24Z giles $
-% zeroline.ps
-% Test file to determine how other PostScript implementations handle
-% filling zero-width lines under a variety of conditions.
-
-% Add a small "fan" of zero-width lines at different angles to the path.
-/fan
- { currentpoint 100 0 rlineto
- 2 copy moveto 100 20 rlineto
- 2 copy moveto 100 100 rlineto
- 2 copy moveto 20 100 rlineto
- moveto 0 100 rlineto
- } def
-
-% Append a rectangle to the current path.
-/rectappend
- { 4 -2 roll moveto 1 index 0 rlineto 0 exch rlineto
- neg 0 rlineto closepath
- } def
-% Fill a rectangle.
-/rectfill
- { gsave newpath rectappend fill grestore
- } def
-% Stroke a rectangle.
-/rectstroke
- { gsave newpath rectappend stroke grestore
- } def
-% Clip to a rectangle. Unlike the real rectclip,
-% this clear the current path.
-/rectclip
- { newpath rectappend clip newpath
- } def
-
-40 40 translate
-
-% Display fans of different colors on different backgrounds.
-gsave
-0 setgray
-0 0 120 120 rectstroke
-10 10 moveto fan fill
-140 0 translate
-0 setgray
-0 0 120 120 rectstroke
-0.8 setgray
-10 10 moveto fan fill
-140 0 translate
-0 setgray
-0 0 120 120 rectfill
-1 setgray
-10 10 moveto fan fill
-grestore
-0 140 translate
-
-% Display rectangles with two edges coincident.
-gsave
-newpath
-0 setgray
-0 0 40 40 rectappend
-0 0 20 20 rectappend
-eofill
-60 0 translate
-0 0 40 40 rectappend
-40 0 -20 20 rectappend
-fill
-grestore
-0 60 translate
-
-% Display superimposed lines.
-gsave
-/super
- { currentpoint fan
- 2 copy moveto 20 0 rmoveto 50 0 rlineto
- 2 copy moveto 20 4 rmoveto 50 10 rlineto
- 2 copy moveto 20 20 rmoveto 50 50 rlineto
- 2 copy moveto 4 20 rmoveto 10 50 rlineto
- moveto 0 20 rmoveto 0 50 rlineto
- } def
-0 setgray
-0 0 moveto super fill
-140 0 translate 0 0 moveto super eofill
-grestore
-0 140 translate
-
-showpage
|