Debian Codegraph @

doc/sphinx/olddocs/old/ja/sfdformat.html

raw symbols SCIP
1 <HTML>
2 <HEAD>
3 <!-- Created with AOLpress/2.0 -->
4 <!-- AP: Created on: 7-Dec-2000 -->
5 <!-- AP: Last modified: 14-Jun-2006 -->
6 <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
7 <!--<TITLE>Spline Font Database File Format</TITLE>-->
8 <TITLE>スプラインフォントデータベースファイルフォーマット</TITLE>
9 <LINK REL="icon" href="../../_static/fftype16.png">
10 <LINK REL="stylesheet" TYPE="text/css" HREF="FontForge.css">
11 </HEAD>
12 <BODY>
13 <DIV id="in">
14 <H1 ALIGN=Center>
15 <!--Spline Font Database-->
16 スプラインフォントデータベース
17 </H1>
18 <P>
19 <!--
20 <FONT COLOR="Red"><STRONG>This page is often grievously out of date. It was
21 a fair approximation to reality on 13 December 2005.</STRONG></FONT> Even
22 if out of date it should be helpful, but if you really need to know the current
23 format look at
24 <A HREF="http://cvs.sourceforge.net/viewcvs.py/fontforge/fontforge/fontforge/sfd.c">sfd.c</A>
25 and see what it parses. Some descriptions of esoteric features are not complete,
26 but I hope they give you enough hints that you can figure the format out
27 (especially after looking it up in sfd.c) -->
28 <FONT COLOR="Red"><STRONG>このページは悲しくなるほど時代遅れです。これは2005年12月13日に事実だったことの大まかな近似です。</STRONG></FONT>時代遅れであっても、これは役に立つでしょうが、現在のフォーマットについて本当に知りたい場合は <A HREF="http://cvs.sourceforge.net/viewcvs.py/fontforge/fontforge/fontforge/sfd.c">sfd.c</A> を参照して、それがどのように読み込みを行うかを調べてください。いくつかの秘教めいた機能の説明は完全ではありませんが、あなたが (とくに sfd.c を調べた後に) フォーマットを記述できるようになるためのヒントとなることを私は望んでいます。
29 <P>
30 <!--
31 FontForge's <A HREF="sfd.html">sfd</A> files are ASCII files (so they can
32 be copied easily across the internet and so that diffs are somewhat meaningful).
33 They contain a full description of your font. -->
34 FontForge の <A HREF="sfd.html">sfd</A> ファイルは ASCII ファイルです (なのでそれらは Internet を介して簡単にコピーでき、diff を取ることには何らかの異義があります。それにはあなたのフォントの完全な記述が含まれます。
35 <P>
36 <!--
37 They are vaguely modeled on bdf files. The first few lines contain general
38 font properties, then there's a section for each character, then a section
39 for each bitmap font. -->
40 それらはかすかに BDF ファイルから範をとっています。最初のごくわずかな行にフォント全体の属性が含まれ、それに続いて各文字のセクションが続き、最後に各ビットマップフォントのセクションがきます。
41 <UL>
42 <LI>
43 <!-- <A HREF="sfdformat.html#Font-Header">Font Header</A>-->
44 <A HREF="sfdformat.html#Font-Header">フォントヘッダ</A>
45 <LI>
46 <!-- <A HREF="sfdformat.html#Outline-Char-Data">Outline Character Data</A> -->
47 <A HREF="sfdformat.html#Outline-Char-Data">アウトライン文字データ</A>
48 <LI>
49 <!-- <A HREF="sfdformat.html#Bitmap-Fonts">Bitmap Fonts</A>-->
50 <A HREF="sfdformat.html#Bitmap-Fonts">ビットマップフォント</A>
51 <LI>
52 <!-- <A HREF="sfdformat.html#CID-keyed-fonts">CID keyed fonts</A>-->
53 <A HREF="sfdformat.html#CID-keyed-fonts">CID キー指定フォント</A>
54 <LI>
55 <!-- <A HREF="sfdformat.html#Multiple-Master-fonts">Multiple Master fonts</A>-->
56 <A HREF="sfdformat.html#Multiple-Master-fonts">マルチプルマスターフォント</A>
57 <LI>
58 <!-- <A HREF="sfdformat.html#Autosave-Format">AutoSave Format</A>-->
59 <A HREF="sfdformat.html#Autosave-Format">自動保存フォーマット</A>
60 </UL>
61 <P>
62 <!--
63 <FONT COLOR="Red"><STRONG><BIG>WARNING: </BIG></STRONG></FONT>It is tempting
64 to cut and paste information from one sfd file to another. This is usually
65 ok, but there are a couple of cases than need to be avoided: -->
66 <FONT COLOR="Red"><STRONG><BIG>警告: </BIG></STRONG></FONT>ある SFD ファイルから他のファイルへ情報をカット&amp;ペーストしたいという誘惑を覚えます。これは大抵の場合は問題ありませんが、これを避けなければならない場合が 2 つあります:
67 <UL>
68 <LI>
69 <!-- If you copy a glyph with truetype instructions, those instructions may call
70 subroutines defined in the old font but not the new. Unexpected things may
71 happen when the glyph is grid fit (including system crashes) -->
72 TrueType 命令を含むグリフをコピーした場合、それらの命令が古いフォントには定義されていても新しいフォントには未定義のサブルーチンを呼んでいる可能性があります。グリフがグリッド合わせを行ったとき、予想外の事柄 (システムクラッシュを含む) が起こる可能性があります。
73 <LI>
74 <!-- If you copy a substitution (ligature, kern, contextual chaining, ...) item
75 from one font to another, the substitution contains an index into a table
76 of script/languages maintained by the font. Bad things (FontForge crashes)
77 can happen if these tables do not match. -->
78 置換 (合字、カーニング、連鎖型文脈依存、…) をあるフォントから別のフォントにコピーしたときには、置換にはフォントに保存されているスクリプト/言語テーブル内のインデックスが保存されています。それらのテーブルが一致していなければ、悪い事 (FontForge のクラッシュ) が起こるかもしれません。
79 <LI>
80 <!-- If you copy a glyph containing references these are done by glyph index (which
81 is probably different from font to font). You may end up refering to the
82 wrong glyph. -->
83 グリフインデックス (これはフォント語とに異なります) によって指定された参照を含むグリフをコピーすると、間違ったグリフを参照する結果となるでしょう。
84 </UL>
85 <H3>
86 <!--<A NAME="Font-Header">Font Header</A>-->
87 <A NAME="Font-Header">フォントヘッダ</A>
88 </H3>
89 <P>
90 <!--
91 Here is an example of what the first few lines look like (order is largely
92 irrelevant within this section): -->
93 ここに示すのは、最初のごく僅かな行がどのような感じかを示す例です (このセクションでは、順番はほとんど意味をもちません):
94 <BLOCKQUOTE>
95 <PRE>SplineFontDB: 1.0
96 FontName: Ambrosia
97 FullName: Ambrosia
98 FamilyName: Ambrosia
99 Weight: Medium
100 Copyright: Copyright (C) 1995-2000 by George Williams
101 Comments: This is a funny font.
102 Version: 001.000
103 ItalicAngle: 0
104 UnderlinePosition: -133
105 UnderlineWidth: 20
106 Ascent: 800
107 Descent: 200
108 DisplaySize: -24
109 AntiAlias: 1
110 WinInfo: 64 16 4
111 FitToEm: 1
112 XUID: 3 18 21
113 Encoding: unicode
114 Order2: 1
115 OnlyBitmaps: 0
116 MacStyle: 0
117 TeXData: 1 10485760 0 269484 134742 89828 526385 1048576 89828
118 </PRE>
119 </BLOCKQUOTE>
120 <P>
121 <!--
122 The first line just identifies the file as an sfd file. The next few lines
123 give the various different names that postscript allows fonts to have. Then
124 some fairly self-explanatory items (if they don't make sense, look them up
125 in the <A HREF="fontinfo.html">font info</A> dlg). A few things need some
126 explanation: -->
127 最初の行は、単にこのファイルが SFD ファイルであることを示すだけのものです。その下の 3 行は、PostScript でフォントに設定することができる各種の異なる名前を示しています。それに続く項目群は、まったくその名の通りに用いられます (意味が分からない場合は、<A HREF="fontinfo.html">フォント情報</A>ダイアログで調べてみてください)。2, 3 の項目にはちょっと説明が必要でしょう:
128 <DL>
129 <DT>
130 TeXData
131 <DD>
132 <!-- These are the TeX font parameters (and some similar info). The first number
133 is 1,2 or 3 and indicates that the font is a text, math or math ext font.
134 The next number is the design pointsize (times (1&lt;&lt;20)). Then follow
135 the font parameters. These values are usually in TeX fix_word format where
136 there is a binary point after the first 20 binary digits (so to get the number
137 divide by (1&lt;&lt;20)). -->
138 これらは TeX のフォントパラメータ (およびいくつかの同種の情報) です。最初の数値は 1, 2 または 3 で、フォントがテキスト、数学または数学拡張フォントのどれであるかを示します。次の数値はデザインポイントサイズ (×(1&lt;&lt;20)) です。その後にフォントパラメータが続きます。これらの数値は通常 TeX の fix_word フォーマットで表されます。このフォーマットでは 2 進数で先頭 20 桁目に小数点が来ます (ですから、実際の数値を得るためには (1&lt;&lt;20) で割ってください)。
139 <DT>
140 DisplaySize
141 <DD>
142 <!-- This is the number of pixels per em that will be used by default to display
143 the font in fontviews (it may be changed of course). Negative numbers mean
144 to rasterize the display from the outlines, positive numbers mean to use
145 a prebuilt bitmap font of that size. -->
146 これは、フォントビュー内でフォントを表示する際のデフォルトとして用いられる、1 em あたりのピクセル数です (もちろん変更可能です)。負の数字は、アウトラインをラスタライズして表示することを意味し、正の数字は、そのサイズに一致する作成済みのビットマップを使用することを意味します。
147 <DT>
148 AntiAlias
149 <DD>
150 <!-- Whether the fontview should display the font as antialiased or black and
151 white. (AntiAliased looks better, but will be slower) -->
152 フォントビューで、フォントをアンチエイリアス表示するか、白黒表示するか。(アンチエイリアスの方がきれいに表示されますが、遅くなります)
153 <DT>
154 FitToEm
155 <DD>
156 <!-- Controls whether Fit to Em is checked by default in a fontview that displays
157 this font. -->
158 このフォントを表示するフォントビューで、<CODE>表示を全角に固定(<U>F</U>)</CODE> にデフォルトでチェックを入れておくか。
159 <DT>
160 WinInfo
161 <DD>
162 <!-- Has three pieces of data on the default display of windows containing this
163 font. The first datum says that the window should be scrolled so that glyph
164 at encoding 64 should be visible, the second that the window should have
165 16 character columns horizontally, and the last that there should be 4 character
166 rows vertically. -->
167 このフォントを表示するウィンドウのデフォルト画面を表す 3 つの値です。最初の値は、ウィンドウは符号位置 64 にあるグリフが見えるようにスクロールするかを表し、2 番目の値は、ウィンドウが横幅 16 文字分の欄をもつかどうかを、最後の値は建てに 4 文字分の欄を持つかどうかを表します。
168 <DT>
169 Encoding
170 <DD>
171 <!-- For normal fonts this will be one of the names (or a close approximation
172 thereto) that appears in the Encoding pulldown list. CID keyed fonts will
173 not have encodings. Instead they'll have something like: -->
174 普通のフォントでは、これは <CODE>エンコーディング(<U>E</U>)</CODE> プルダウンリストに表示される名前のどれかと同じ (か、それに非常に近い) ものとなるでしょう。CID キー指定フォントは、Encoding 行を含まず、以下のようなものが含まれるでしょう。
175 </DL>
176 <BLOCKQUOTE>
177 <PRE>Registry: Adobe
178 Ordering: japan1
179 Supplement: 4
180 CIDVersion: 1.2
181 </PRE>
182 </BLOCKQUOTE>
183 <P>
184 <!--
185 Some fonts will have some TrueType information in them too (look at the
186 <A HREF="http://www.microsoft.com/typography/tt/tt.htm">truetype spec</A>
187 for the meanings of these, they usually live in the OS/2, hhea, or vhea tables). -->
188 フォントによっては、いくつかの TrueType 情報もここに含まれるでしょう (それらの意味については <A HREF="http://www.microsoft.com/typography/tt/tt.htm">TrueType の仕様書</A>を参照してください。それらは大抵 OS/2, hhea, vhea テーブルのいずれかにあるはずです。
189 <BLOCKQUOTE>
190 <PRE>FSType: 4
191 PFMFamily: 17
192 TTFWeight: 400
193 TTFWidth: 5
194 Panose: 2 0 5 3 0 0 0 0 0 0
195 LineGap: 252
196 OS2LineGap: 252
197 VLineGap: 0
198 OS2Vendor: 'PfEd'
199 OS2FamilyClass: 2050
200 </PRE>
201 </BLOCKQUOTE>
202 <P>
203 <!--
204 These items also come from the OS/2 and hhea tables but are slightly more
205 complex. The keywords are paired, so <CODE>HheadAscent</CODE> and
206 <CODE>HheadAOffset</CODE> work together. If the offset keyword is 1 (true)
207 then the other keyword is treated as a value relative to what FontForge thinks
208 should be the correct value, FontForge will calculate what it thinks the
209 value should be and then will add the value specified in the keyword. So
210 in the example below, FF will figure out what it thinks
211 <CODE>HheadAscent</CODE> should be and then add "0" to it to get the value
212 stored in a truetype font's OS/2 table. However if the Offset flag is set
213 to 0 (false) then the Ascent would be used exactly as specified. -->
214 以下の項目は OS/2 および hhea テーブルからも取得されますが、それらは僅かにより複雑です。それらのキーワードは対になっているので <CODE>HheadAscent</CODE> と <CODE>HheadAOffset</CODE> は一緒に動作します。*Offset キーワードが 1 (真) である場合、もう片方のキーワードは、FontForge が正しい値として認識する値を基準とした相対値として扱われます。その場合 FontForge は適切と思われる値を計算して、それにキーワードで指定された値を加えます。ですから以下の例では、FF は TrueType フォントの OS/2 テーブルに格納された値を得るために <CODE>HheadAscent</CODE> に“0”を加えるべきと考えます。その一方、Offset フラグが 0 (偽) に設定されている場合、アセントの値は指定されたとおりの物が使用されます。
215 <BLOCKQUOTE>
216 <PRE>HheadAscent: 0
217 HheadAOffset: 1
218 HheadDescent: 0
219 HheadDOffset: 1
220 OS2TypoAscent: 0
221 OS2TypoAOffset: 1
222 OS2TypoDescent: 0
223 OS2TypoDOffset: 1
224 OS2WinAscent: 0
225 OS2WinAOffset: 1
226 OS2WinDescent: 0
227 OS2WinDOffset: 1
228 </PRE>
229 </BLOCKQUOTE>
230 <P>
231 <!--
232 The OS/2 table contains information on the position of subscripts, superscripts
233 and strike throughs: -->
234 OS/2 テーブルには下付き文字、上付き文字および取り消し線の位置情報が含まれています:
235 <BLOCKQUOTE>
236 <PRE>OS2SubXSize: 1351
237 OS2SubYSize: 1228
238 OS2SubXOff: 0
239 OS2SubYOff: -446
240 OS2SupXSize: 1351
241 OS2SupYSize: 1228
242 OS2SupXOff: 0
243 OS2SupYOff: 595
244 OS2StrikeYSize: 143
245 OS2StrikeYPos: 614
246 </PRE>
247 </BLOCKQUOTE>
248 <P>
249 <!--
250 The MacStyle field (if present) indicates whether the font is bold, italic,
251 condensed, extended, etc. -->
252 MacStyle フィールドは、(存在すれば) そのフォントがボールド、イタリック、コンデンスト、エクステンディドなどに該当するかどうかを示します。
253 <P>
254 <!--
255 Some fonts will have Postscript specific information contained in the Private
256 dictionary -->
257 一部のフォントは、Private 辞書に含まれる PostScript 固有の情報をもっています。
258 <BLOCKQUOTE>
259 <PRE>BeginPrivate: 1
260 BlueValues 23 [-19 0 502 517 750 768]
261 EndPrivate
262 </PRE>
263 </BLOCKQUOTE>
264 <P>
265 <!--
266 If the font has any opentype features it will have a list of
267 <A HREF="charinfo.html#ScriptLang">script language</A> entries: -->
268 フォントに OpenType 機能が含まれているならば、<A HREF="charinfo.html#ScriptLang">用字系・言語</A>項目のリストもあるはずです:
269 <BLOCKQUOTE>
270 <PRE>ScriptLang: 3
271 1 latn 1 ROM
272 1 latn 4 DEU ROM VIT dflt
273 3 cyrl 1 dflt grek 1 dflt latn 5 DEU ROM TRK VIT dflt
274 </PRE>
275 </BLOCKQUOTE>
276 <P>
277 <!--
278 The first line says that there are 3 sets of script lang entries and they
279 follow on the next three lines. The next line says that this entry is only
280 active for one script ('latn') and then only if the language is 'ROM '. The
281 next line says the entry is again only active for one script, but that this
282 time any of the four languages 'DEU ', 'ROM ', 'VIT ' or the default language
283 apply to it. And the last line gives an example of an entry that is active
284 for several scripts with several languages. -->
285 最初の行は、用字系・言語項目が 3 セット存在することを示し、その後の 3 行にそれらの項目が含まれます。2 行目は、この項目が有効になるのがただ 1 個の用字系 (&lsquo;latn&rsquo;) のみで、なおかつ言語が&lsquo;ROM &rsquo;であるときに限られることを示します。その次の行も 1 個の用字系のみに対して有効であることを示しますが、今度は 4 個の言語 (&lsquo;DEU &rsquo;,&lsquo;ROM &rsquo;,&lsquo;VIT &rsquo;またはデフォルト言語) に対して適用されることを表します。最後の行では、複数の用字系と複数の言語において有効となる項目の例を示しています。
286 <P>
287 <!--
288 OpenType features are stored with an index into this list. If a feature has
289 index "0" then that feature is only active for the latin script in the Romanian
290 language. If it has index 2 it will be active for cyrillic, greek and latin
291 scripts. A special script index of 65535 is used to mean that this feature
292 is "Nested", that is it is never activated by itself, but its activation
293 is controlled by a contextual or contextual chaining lookup (which in turn
294 will have its own script language index). -->
295 OpenType 機能はこのリスト内のインデックスを用いて格納されます。この場合、ある機能がインデックス“0”であるならば、その機能はルーマニア語のラテン文字表記のときにのみ有効になります。インデックスが 2 であるならば、その機能はキリル文字・ギリシャ文字およびラテン文字に対して有効になるわけです。その機能が「入れ子」になった物であることを表すための特別な用字系インデックスとして、65535 を使っています。これはそれ自体で起動されることは決してなく、文脈依存または文脈依存連鎖の照合 (これ自体は、独自の用字系・言語インデックスを備えています) によって起動が制御されるものです。
296 <P>
297 <!--
298 If your font has any kerning classes -->
299 フォントに何らかのカーニングクラスが含まれていれば、
300 <BLOCKQUOTE>
301 <PRE>KernClass: 31 64 2 0
302 1 F
303 41 L Lacute glyph78 Lcommaaccent Ldot Lslash
304 1 P
305 ...
306 6 hyphen
307 5 space
308 ...
309 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 0 0 0 0 0 0 0 0 0 0 0 0 0 0
310 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -152 -195 -152 -225 0 0 0 0 0 0 0 0 0 0 0 0 0 -145 -145 -130
311 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -130 0 0 0 0 0 0 0 0 0 0 -145 0 -115 0 0 0 0 -65 0 -140 -120 -120
312 ...
313 </PRE>
314 </BLOCKQUOTE>
315 <P>
316 <!--
317 The first line says that this Kerning Class has 31 different classes for
318 the first character, and 64 for the second. It is active for entry 2 in the
319 script lang list above. The <A HREF="charinfo.html#lookup-flags">OpenType
320 flags </A>will be 0. The next line says that the first character class of
321 the first character (numbered 1, class 0 is reserved and usually is not defined)
322 consists of only one character "F" (the number in front is the string length
323 of the line. It speeds up processing the sfd file but has no semantic content).
324 The next line is for class 2 of the first character, it has more characters
325 in it and a longer string length. After 30 entries we start on the classes
326 for the second character. They look exactly like classes for the first character.
327 After all the second character classes have been defined we have an array
328 of numbers, &lt;char1 class cnt&gt;*&lt;char2 class cnt&gt; of them in fact.
329 This specifies the amount of kerning that should be placed between a characters
330 of the given classes of left and right characters (ie. if char1 was in left
331 class 2 and char2 was in right class 4 then we would index this array with
332 3*&lt;char2 class cnt&gt; + 4). -->
333 最初の行は、このカーニングクラスに含まれる先頭文字のクラスが 31 種類存在し、第二文字のクラスが 64 種類存在することを表しています。これは、上記の用字系・言語リストの項目 2 に対して有効になります。<A HREF="charinfo.html#lookup-flags">OpenType フラグ</A> は 0 となります。次の行は、最初の文字 (クラス 0 は予約済みで、通常は定義する必要がないので、この番号は 1 となります) の先頭文字クラスは文字“F”1 文字からなることを表します (“F”の前にある数字は行の文字数です。これは SFD ファイルの処理速度の向上に役立ちますが、それ自体で意味を持つ情報ではありません)。次の行は、先頭文字のクラス 2 で、より多くの文字を含んでいるため文字列長も長くなっています。30 個の項目が続いた後に、第二文字のクラスが始まります。これは、先頭文字のクラスと全く同様です。第二文字のクラスを全部定義し終わった後に、多数(正確には &lt;先頭文字クラスの個数×第二文字クラスの個数&gt;) の数値からなる 1 個の配列が来ます。これは、該当するクラスの対における左右の文字間に施されるカーニングの量を指定しています (例えば、文字1 が先頭文字クラス 2 に属し、文字2 が第二文字クラス 4 に属している場合、この配列のインデックス 3×&lt;文字2 のクラス番号&gt; + 4 で指定することになります)
334 <P>
335 <!--
336 If your fontforge has been configured with device table support you may find
337 <A HREF="#device-table">device</A> tables interspersed among the kerning
338 offsets array: -->
339 お使いの FontForge がデバイステーブルサポートつきの設定でコンパイルされている場合、<A HREF="#device-table">デバイス</A>テーブルがカーニングオフセット配列の間に組み込まれているのが見つかるでしょう:
340 <BLOCKQUOTE>
341 <PRE>...
342 0 {} 0 {} 0 {} ...
343 -145 {12-13 -1,1} -145 {} -130 {8-9 -1,-1} ...
344 </PRE>
345 </BLOCKQUOTE>
346 <P>
347 <!--
348 The order of opentype features within GPOS/GSUB tables may be stored: -->
349 GPOS/GSUB テーブルに含まれる OpenType 機能の順番も保存することができます:
350 <BLOCKQUOTE>
351 <PRE>TableOrder: GPOS 4
352 'subs'
353 'sinf'
354 'mark'
355 'kern'
356 TableOrder: GSUB 2
357 'frac'
358 'nutf'
359 </PRE>
360 </BLOCKQUOTE>
361 <P>
362 <!--
363 If the font contains ttf hinting, then the file may contain unparsed truetype
364 tables (understanding ttf hinting is beyond FontForge's abilities, but it
365 can at least preserve the data): -->
366 フォントに TTF のヒント情報が含まれている場合、ファイルには TrueType テーブルを解析しないで格納することができます (TTF のヒントを理解することは FontForge の能力を超えていますが、少なくともデータを保存することはできます):
367 <BLOCKQUOTE>
368 <PRE>TtfTable: prep 4360
369 5S;o3()It?eJ8r@H[HSJH[H^@!b&amp;BQ*?Vcm@'XSh+1MACZ&gt;Up/\,o1+Ca't2!&lt;ocH+Wn2p"@,t&amp;
370 +Wo+[()Is6G8:u7D/^7,*,KO/(E=N5!=s)LCMjn,:Mp3:DSL&amp;j05dG#cY`hLCN"!&lt;CBO$@s(_ZX
371 ...
372 </PRE>
373 </BLOCKQUOTE>
374 <P>
375 <!--
376 The first line says that the 'prep' table is 4360 bytes long. Subsequent
377 lines will provide 4360 bytes of data, packed in
378 <A HREF="#ASCII85Encode">ASCII85Encode<SUP>1</SUP></A> (which takes binary
379 data and packs it into ASCII without too much expansion. See the PostScript
380 Reference Manual (3rd edition, pages 131-132) for a description of this packing,
381 or <CODE>$&nbsp;man&nbsp;btoa</CODE>). -->
382 最初の行は、&lsquo;prep&rsquo;テーブルの長さが 4360 バイトであることを表します。後ろに続く行には、4360 バイトのデータが <A HREF="#ASCII85Encode">ASCII85Encode<SUP>1</SUP></A> (入力されたバイナリデータをあまりサイズを大きくしないで ASCII にパックします。この方式の説明は、PostScript リファレンスマニュアル (第3版、原書 131〜132 ページ) を参照するか、<CODE>$&nbsp;man&nbsp;btoa</CODE> で調べてください) にパックされて納められています。
383 <P>
384 <!--
385 The <CODE>LangName</CODE> entries represent the TrueType name table: the
386 number represents the language and is followed by a list of strings encoded
387 in UTF-7. The first string corresponds to ID=0 (Copyright), the second to
388 ID=1 (Family), ... trailing empty strings will be omitted. In the American
389 English language (1033) section, if one of these names exactly matches the
390 equivalent postscript item then that name will be omitted (this makes it
391 easier to handle updates, users only have to change the copyright in one
392 place) -->
393 TrueType の name テーブルは複数の <CODE>LangName</CODE> 項目によって表されます: 数字は言語を表し、その後ろに続くのは UTF-7 で符号化された文字列のリストです。最初の文字列は ID=0 (著作権) に対応し、2 番目は ID=1 (ファミリー) に対応し、…という具合で、末尾にある空文字列はすべて省略されます。アメリカ英語 (1033) のセクションでは、これらの名前のどれかが、等価な PostScript 項目と正確に一致している場合、その名前は省略されます (これにより更新の取扱いが簡単になり、ユーザは 1 箇所で著作権表示を変更するだけでよくなります)。
394 <BLOCKQUOTE>
395 <PRE>LangName: 1033 "" "" "Regular" "GWW:Caliban Regular: Version 1.0" "" "Version 1.0"
396 LangName: 1032 "" "" "+A5oDsQ09A78DvQ05A7oDrAAA"
397 </PRE>
398 </BLOCKQUOTE>
399 <P>
400 <!--
401 If your font has any anchor classes: -->
402 フォントに何らかのアンカークラスが含まれている場合:
403 <BLOCKQUOTE>
404 <PRE>AnchorClass: "top" mark 4 7 1 "bottom" mark 4 7 1 "Anchor-2" mark 4 7 1 "Anchor-3" mark 4 7 2 "Anchor-4" mark 4 7 2 "Anchor-5" mark 4 7 3 "Anchor-6" mark 4 7 4
405 </PRE>
406 </BLOCKQUOTE>
407 <P>
408 <!--
409 There is an Anchor Class named "top" which has feature tag 'mark', opentype
410 flags 4, a script lang index of 7, and it should be merged with other anchor
411 classes marked with "1". The next class is named "bottom", the next "Anchor-2"
412 and so forth. (Anchor class names are output in UTF7) -->
413 ここには“top”という名前で、機能タグ“mark”を含み、OpenType フラグが 4 で、用字系/言語インデックスが 7 であるアンカークラスが存在し、これが“1”と印づけられた他のアンカークラスと併合すべきであることを示します。次のクラスは“bottom”という名前で、その次は“Anchor-2”という名前で、以下同様に続きます。(アンカークラス名は UTF-7 で出力されます)
414 <P>
415 <!--
416 Contextual or contextual chaining lookups are also stored in the font header.
417 The are introduced by one of the keywords: "ContextPos", "ContextSub",
418 "ChainPos", "ChainSub" and "ReverseChain", and are ended by "EndFPST". Contextual
419 chaining lookups may check previous glyphs (called backtracking), current
420 glyphs and lookahead glyphs, while Contextual lookups only check for a string
421 of current glyphs. There are four formats:<BR> -->
422 文脈依存または文脈依存連鎖の照合も、フォントヘッダに格納されます。それらはキーワード“ContextPos”,“ContextSub”,“ChainPos”,“ChainSub”または“ReverseChain”で始まり、キーワード“ENDFPST”で終了します。文脈依存の照合は現在位置にあるグリフ列を所定の文字列群と照合することしかできませんが、文脈依存連鎖の照合は現在のグリフ、および先読みグリフだけでなく先行するグリフをチェックすることができます (これをバックトラックといいます)。このフォーマットには 4 種類あります。<BR>
423 <!-- By coverage tables -->
424 適用範囲テーブルによる方法
425 <BLOCKQUOTE>
426 <PRE>ChainSub: coverage 0 0 'abvs' 0 0 0 1
427 1 1 0
428 Coverage: 7 uni0C40
429 BCoverage: 8 glyph388
430 1
431 SeqLookup: 0 '0013'
432 EndFPST
433 </PRE>
434 </BLOCKQUOTE>
435 <P>
436 <!--
437 This defines a simple context chaining substitution by coverage class. The
438 opentype flags are 0, script/lang index is 0, the feature tag is 'abvs'.
439 There are no classes, no backtracking classes and no lookahead classes defined
440 (it's by coverage table). There is one rule. (For a greater explanation of
441 these cryptic comments see the OpenType specs on contextual lookups). -->
442 これは適用範囲クラスによる単純文脈連鎖依存の置換を定義しています。OpenType フラグは 0, 用字系/言語インデックスは 0 で、機能タグは&lsquo;abvs&rsquo;です。クラスもバックトラッククラスも先読みクラスも定義されていません (適用範囲テーブルで指定しています)。ルールが 1 個あります (これらの暗号のようなコメントのより詳しい説明については、OpenType 仕様書の、文脈依存照合 (contextual lookup) について述べた箇所を調べてください)。
443 <P>
444 <!--
445 Then follows the first rule. The first line, "1 1 0", says how many coverage
446 tables there are in the normal list (1), how many in the backtrack list (1)
447 and how many in the lookahead list (0). Then we get the one normal coverage
448 table, which describes a single glyph (uni0C40). Then one backtracking coverage
449 table which also defines one glyph (glyph388). Finally there is one sequence
450 lookup, at normal position 0, we should apply the substitution named '0013'. -->
451 その後に最初のルールが続きます。1 行目の“1 1 0”というのは、何個の適用範囲テーブルが通常リスト (1 個)、バックトラックリスト (1 個) および先読みリスト (0 個) が含まれているかを表します。その次にあるのが 1 個の通常適用範囲テーブルで、これは 1 個のグリフ (uni0C40) を記述しています。続いて 1 個のバックトラック適用範囲テーブルがあり、これも 1 個のグリフ (glyph388) を定義しています。最後にあるのが 1 個の連鎖型照合で、通常位置 0 において&lsquo;0013&rsquo;という名前の置換を適用する必要があることを表します。
452 <P>
453 <!--
454 That is to say: If we find the glyph stream "glyph388 uni0C40", then it will
455 match this lookup and we should apply substitution '0013' (found elsewhere)
456 to uni0C40. -->
457 一言で言うとこうなります: グリフの連鎖“glyph388 uni0C40”が見つかったら、それはこの照合に一致し、その時は (よそで定義されている) 置換&lsquo;0013&rsquo;を uni0C40 に適用すること。
458 <P>
459 <!--
460 By classes -->
461 クラスによる方法
462 <BLOCKQUOTE>
463 <PRE>ChainSub: class 0 0 'calt' 3 3 0 1
464 Class: 52 b o v w b.high o.high v.high w.high r.alt.high r.alt
465 Class: 43 a c d e f g h i j k l m n p q r s t u x y z
466 BClass: 52 b o v w b.high o.high v.high w.high r.alt.high r.alt
467 BClass: 43 a c d e f g h i j k l m n p q r s t u x y z
468 1 1 0
469 ClsList: 2
470 BClsList: 1
471 FClsList:
472 1
473 SeqLookup: 0 'high'
474 EndFPST
475 </PRE>
476 </BLOCKQUOTE>
477 <P>
478 <!--
479 This defines a context chaining substitution, by classes. The format of the
480 first line is the same as described above. Here we have three classes for
481 the normal match and three for the backtracking match, and one rule. The
482 next 4 lines define the classes. As with kerning by classes, class 0 does
483 not need to be explicitly defined, it is implicitly defined to be "any glyph
484 not defined in another class". So we define class 1 to be "b,o,v,..." and
485 class 2 to be "a,c,d,e,...". And then we define the backtracking classes
486 (which here happen to be the same as the classes for the normal match, but
487 that isn't always the case). -->
488 これは、クラスによる文脈連鎖型置換を 1 つ定義しています。最初の行のフォーマットは上で説明したのと同じです。ここでは通常の一致に対する 3 つのクラスとバックトラックによる一致に対する 3 つのクラスが定義されています。その後ろの 4 行はクラスを定義しています。クラスによるカーニングの場合と同じく、クラス 0 は明示的に定義する必要はなく、「他のクラスのどれにも定義されていない任意のグリフ」として暗黙に定義されます。そこで、クラス 1 を“b,o,v,…”と定義し、クラス 2 を“a,c,d,e,…”と定義することになります。次に、クラス群のバックトラックを定義します(ここでは通常の一致のためのクラスとたまたま同じですが、常にそうであるわけではありません)。
489 <P>
490 <!--
491 The one rule says that if we get something in normal class 2 following something
492 in backtracking class 1 (that is, if we get something like "ba" or "oc")
493 then apply substitution 'high' -->
494 ルールの 1 つでは、通常クラス 2 に含まれる何かの後にバックトラッククラス 1 が来た場合 (つまり、“ba”や“oc”のような何らかの文字列がある場合) 置換&lsquo;high&rsquo;を適用しています。
495 <P>
496 <!--
497 By glyphs -->
498 グリフによる方法
499 <BLOCKQUOTE>
500 <PRE>ChainSub: glyph 0 1 'calt' 0 0 0 1
501 String: 1 D
502 BString: 3 c b
503 FString: 1 e
504 1
505 SeqLookup: 0 'rigl'
506 EndFPST
507 </PRE>
508 </BLOCKQUOTE>
509 <P>
510 <!--
511 Again we have one rule. That rule says that if we get the sequence of glyphs
512 "c b D e" then we should apply substitution 'rig1' to glyph "D". -->
513 この例でも 1 個のルールが定義されています。このルールでは、グリフの連鎖“c b D e”が存在した場合、置換&lsquo;rig1&rsquo;をグリフ“D”に適用するように指示しています。
514 <P>
515 <!--
516 And finally by reverse coverage tables -->
517 最後は、逆順の適用範囲テーブルによる方法です。
518 <BLOCKQUOTE>
519 <PRE>ChainSub: revcov 0 0 'foo ' 0 0 0 1
520 1 1 0
521 Coverage: 7 uni0C40
522 BCoverage: 8 glyph388
523 1
524 Replace: 11 uni0C40.alt
525 EndFPST
526 </PRE>
527 </BLOCKQUOTE>
528 <P>
529 <!--
530 Which says that when glyph388 precedes uni0C40 then uni0C40 should be replaced
531 by uni0C40.alt -->
532 これは、グリフ 388 の前に uni0C40 が来た場合、uni0C40 を uni0C40.alt に置き換えるべきであることを表しています。
533 <P>
534 <!--
535 There may be apple state machines. These are introduced by one of the keywords:
536 "MacIndic", "MacContext", "MacInsert" and "MacKern", and they are terminated
537 with "EndASM". -->
538 Apple 状態機械を含めることができます。それはキーワード“MacIndic”,“MacContext”,“MacInsert”または“MacKern”で始まり、“EndASM”で終了します。
539 <BLOCKQUOTE>
540 <PRE>MacContext: 2,2 16384 9 5
541 Class: 320 yehhamzaabovearabic beharabic teharabic theharabic jeemarabic haharabic khaharabic seenarabic sheenarabic sadarabic dadarabic taharabic zaharabic ainarabic ghainarabic feharabic qafarabic kafarabic lamarabic meemarabic noonarabic heharabic alefmaksuraarabic yeharabic peharabic tteharabic tcheharabic veharabic gafarabic
542 Class: 227 noonghunnaarabic alefmaddaabovearabic alefhamzaabovearabic wawhamzaabovearabic alefhamzabelowarabic alefarabic tehmarbutaarabic dalarabic thalarabic reharabic zainarabic wawarabic ddalarabic rreharabic jeharabic yehbarreearabic
543 Class: 201 shaddakasraarabic shaddakasratanarabic shaddafathaarabic shaddadammaarabic shaddadammatanarabic fathatanarabic dammatanarabic kasratanarabic fathaarabic dammaarabic kasraarabic shaddaarabic sukunarabic
544 Class: 13 tatweelarabic
545 Class: 17 ttehinitialarabic
546 0 0 ~ ~
547 0 0 ~ ~
548 0 0 ~ ~
549 0 0 ~ ~
550 2 32768 ~ ~
551 ...
552 3 32768 'M002' 'M003'
553 ...
554 EndASM
555 </PRE>
556 </BLOCKQUOTE>
557 <P>
558 <!--
559 The state machine begins with a line defining what mac feature,setting invokes
560 it, some mac flags, the number of classes, and number of states in the machine.
561 The first four states on the mac are predefined, so we start with class 4
562 (yehhamzaabovearabic...). Finally there will be &lt;number of
563 classes&gt;*&lt;number of states&gt; lines describing transitions. We begin
564 with the transition for state 0, class 0, then the transition for state 0,
565 class 1, ... -->
566 状態機械は、どの Mac 機能/設定の対によって呼び出されるかの定義と、いくつかの Mac フラグおよび機械に含まれる状態の個数を含む行から始まります。
567 Mac 上の最初の 4 状態は定義済みなので、クラス 4 (yehhamzaabovearabic) から始まることになります。最後に、状態遷移を表す行が &lt;クラスの個数&gt;×&lt;状態の個数&gt; だけの行数にわたって続きます。状態 0, クラス 0 の定義が最初にあり、続いて状態 0, クラス 1 …と続きます。
568 <P>
569 <!--
570 Each transition contains the next state to go to, a set of flags. There may
571 also be other arguments depending on the type of the state machine. -->
572 各状態遷移には、次に移る状態と、一連のフラグが含まれます。そのほかの、状態機械のタイプに依存する引数も置くことができます。
573 <TABLE BORDER CELLPADDING="2">
574 <TR>
575 <TD VALIGN="Top">MacIndic</TD>
576 <!-- <TD>This format has no additional arguments</TD>-->
577 <TD>このフォーマットには追加の引数はありません</TD>
578 </TR>
579 <TR>
580 <TD VALIGN="Top">MacContext</TD>
581 <!-- <TD>This format potentially contains the names of two substitutions. One
582 to be applied to the marked glyph, one to be applied to the current glyph
583 (the special substitution "~" means do nothing and is used as a place holder).
584 See above.</TD> -->
585 <TD>このフォーマットは 2 個の置換の名前を潜在的に含みます。1 個はマーク付きグリフに適用される物で、もう 1 個は現在のグリフに適用される物です (特殊な置換“~”は何もしないことを意味し、プレースホルダとして用いられます。</TD>
586 </TR>
587 <TR>
588 <TD VALIGN="Top">MacInsert</TD>
589 <!-- <TD>This format contains two glyph lists, each preceded by a number indicating
590 how many bytes follow. -->
591 <TD>このフォーマットには 2 個のグリフリストが含まれ、それぞれの前には、後ろに何バイト続くかを表す数値が置かれます。</TD>
592 <BLOCKQUOTE>
593 <PRE>2 0 <B>0 3 a b</B>
594 0 32768 <B>4 fi q 0</B>
595 </PRE>
596 </BLOCKQUOTE>
597 <P>
598 <!-- The first line indicates that no characters should be insert at the marked
599 glyph but that "a" and "b" should be insert at the current glyph. The second
600 line indicates that "fi" and "q" should be insert at the marked glyph and
601 no characters at the current glyph. The flags determine whether characters
602 are insert before or after the glyph.</TD> -->
603 最初の行は、マーク付きグリフの箇所には挿入する物がなにも無いが、現在グリフの位置には“a”と“b”を挿入することを表しています。2 行目は“fi”と“q”はマーク付きグリフの位置に挿入され、現在グリフの位置には何も挿入しないことを表します。グリフの前に文字を挿入するか、後ろに挿入するかはフラグによって決まります。</TD>
604 </TR>
605 <TR>
606 <TD VALIGN="Top">MacKern</TD>
607 <!-- <TD>This format contains a list of kerning offsets. First is a count field
608 saying how many numbers follow, then a list of numbers which adjust the kerning
609 for glyphs that have previously been pushed on the kerning stack.</TD> -->
610 <TD>このフォーマットはカーニングオフセットのリストを含みます。最初にあるのは個数フィールドで、後ろに何個の数値が続くかを表しており、それに続いて、あらかじめカーニングスタックにプッシュされたグリフのカーニングを調整する数値のリストが置かれます。</TD>
611 </TR>
612 </TABLE>
613 <P>
614 <!--
615 The GenTags entry describes a list of feature tags that FontForge has generated
616 itself -->
617 項目 GenTags は、FontForge が自分で生成した機能タグのリストを記述します。
618 <BLOCKQUOTE>
619 <PRE>GenTags: 1 sb'rigl'
620 </PRE>
621 </BLOCKQUOTE>
622 <P>
623 <!--
624 This line says that FontForge has generated 1 tag, the generated tag is used
625 for a substitution lookup (sb=&gt;substitution), and the tag is 'rig1'. -->
626 この行は、FontForge が 1 個のタグを生成しており、生成されたタグは置換参照に用いられ (sb⇒substitution)、そのタグ名が&lsquo;rig1&rsquo;であることを表しています。
627 <P>
628 <!--
629 There may be a list of Mac Feature/Setting names -->
630 Mac の機能/設定の名前リストを置くことができます。
631 <BLOCKQUOTE>
632 <PRE>MacFeat: 0 0 0
633 MacName: 0 0 24 "All Typographic Features"
634 MacSetting: 0
635 MacName: 0 0 12 "All Features"
636 MacFeat: 1 0 0
637 MacName: 0 0 9 "Ligatures"
638 MacSetting: 0
639 MacName: 0 0 18 "Required Ligatures"
640 MacSetting: 2
641 MacName: 0 0 16 "Common Ligatures"
642 MacFeat: 2 1 2
643 </PRE>
644 </BLOCKQUOTE>
645 <P>
646 <!--
647 There may be a Grid entry near the top of the font, this specifies the splines
648 to be drawn in the grid layer for the font, <A HREF="#splineset">see below
649 for a description of the splineset format</A>: -->
650 フォントの先頭近くに項目 Grid を置くことができます。これはフォントのグリッドレイヤに描画されるスプラインを指定します。<A HREF="#splineset">スプラインセットのフォーマットの説明については以下を参照してください</A>:
651 <BLOCKQUOTE>
652 <PRE>Grid
653 678 -168 m 5
654 -40 -168 l 5
655 -678 729 m 1
656 1452 729 l 1
657 -678 525 m 1
658 1452 525 l 1
659 EndSplineSet
660 </PRE>
661 </BLOCKQUOTE>
662 <H3>
663 <!--<A NAME="Outline-Char-Data">Outline Character Data</A>-->
664 <A NAME="Outline-Char-Data">アウトライン文字データ</A>
665 </H3>
666 <P>
667 <!--
668 Then for non-CID fonts you should find a line like: -->
669 その次に、非 CID フォントでは、以下のような行が現れます:
670 <BLOCKQUOTE>
671 <PRE>BeginChars: 285 253
672 </PRE>
673 </BLOCKQUOTE>
674 <P>
675 <!--
676 This means that the font's encoding has room for 285 characters and that
677 there are a total of 253 glyphs defined (usually control characters are not
678 defined). A character looks like: -->
679 これは、フォントのエンコーディングには 285 文字ぶんの場所が取られており、全部で 253 個が定義済みであることを表します (通常、制御文字は定義されません)。文字は以下のように表現されます:
680 <BLOCKQUOTE>
681 <PRE>StartChar: exclam
682 Encoding: 33 33 3
683 Width: 258
684 Flags:
685 HStem: 736 13&lt;39 155&gt; -14 88&lt;162 180&gt;
686 VStem: 71 84&lt;49 396&gt;
687 Fore
688 195 742 m 0
689 195 738 193 736 189 736 c 0
690 175 736 155 743 155 682 c 0
691 155 661 130 249 130 131 c 0
692 130 100 96 99 96 131 c 0
693 96 149 71 662 71 682 c 0
694 71 731 51 736 37 736 c 0
695 33 736 31 738 31 742 c 0
696 31 748 36 747 38 749 c 1
697 188 749 l 1
698 190 747 195 748 195 742 c 0
699 80 32 m 0
700 81 53 95 75 116 74 c 0
701 137 73 150 53 150 32 c 0
702 150 10 137 -14 115 -14 c 0
703 93 -14 79 10 80 32 c 0
704 EndSplineSet
705 EndChar
706 </PRE>
707 </BLOCKQUOTE>
708 <P>
709 <!--
710 The first line names the character, the next line gives the encoding, first
711 in the current font, then in unicode, and finally the original position (GID).
712 Then the advance width. -->
713 最初の行では文字名を定義しています。次の行では文字符号を定義していて、最初に現在のフォント内の符号値があり、次に Unicode での符号値がきて、最後にフォント独自の位置 (GID) が来ます。それから、次の行に送り幅が来ます。
714 <P>
715 <!--
716 Then a set of flags (there are currently five flags: "H" =&gt; the character
717 has been changed since last hinted, "M" the character's hints have been adjusted
718 manually, "W" the width has been set explicitly, "O" =&gt; the character
719 was open when last saved, and "I" the character's instructions are out of
720 date). -->
721 その次の行にフラグ文字を並べた文字列が来ます (現在 5 つのフラグが定義されています:“H”⇒ 最後にヒント付けを行って以降文字が変更された、“M”⇒ 文字のヒントが手動で調整された、“W”⇒ 幅がユーザの指定で設定された、および“O”⇒ 最後に保存したときにその文字が開いていた、“I”⇒その文字の命令が最新の状態と一致しない)
722 <P>
723 <!--
724 Then horizontal and vertical (postscript) stem hints (set of several two
725 number pairs, the first number in the pair is the location of the stem, the
726 next number is the width of the stem, the numbers in brokets (&lt;&gt;) indicate
727 where the hint is valid). -->
728 次に水平および垂直方向の (PostScript) ステムヒントが来ます (いくつかの 2 個の数値対の集まりで、対の最初の数値はステムの位置を表し、次の数値がステムの幅を表し、角括弧 (&lt;&gt;) で囲まれた数値対はそのヒントがどこで有効かを表します)。
729 <P>
730 <!--
731 For fonts with vertical metrics there may also be a -->
732 縦書きメトリックを含むフォントでは、縦書きの送り幅を指定する
733 <BLOCKQUOTE>
734 <PRE>VWidth: 1000
735 </PRE>
736 </BLOCKQUOTE>
737 <P>
738 <!--
739 specifying the vertical advance width. -->
740 という定義を置くことができます。
741 <P>
742 <!--
743 The entry <CODE>Fore</CODE> starts the foreground
744 <A NAME="splineset">splines</A>, they are encoded as postscript commands
745 with moveto abbreviated to m, curveto to c and lineto to l (lower case el).
746 The digit after after the letter is a set of flags whose bits have the following
747 meanings: -->
748 項目 <CODE>Fore</CODE> は前面<A NAME="splineset">スプライン</A>の始まりを指定します。それらは PostScript コマンドで表されますが、moveto を m に、curveto を c に、lineto を l (小文字エル) に省略しています。文字の後ろに来る数値はフラグの組で、各ビットには以下のような意味があります。
749 <TABLE CELLPADDING="2">
750 <TR>
751 <!-- <TH>mask</TH>-->
752 <TH>マスク</TH>
753 <!-- <TH>meaning</TH>-->
754 <TH>意味</TH>
755 </TR>
756 <TR>
757 <TD>0x3</TD>
758 <!-- <TD>indicates whether the point is curve (0), corner (1) or tangent (2).</TD> -->
759 <TD>その点が曲線上の点 (0) か、角の点 (1) か曲線の開始点 (2) であるかを示します。</TD>
760 </TR>
761 <TR>
762 <TD>0x4</TD>
763 <!-- <TD>point selected</TD>-->
764 <TD>この点は選択されている</TD>
765 </TR>
766 <TR>
767 <TD>0x8</TD>
768 <!-- <TD>point has default next control point</TD>-->
769 <TD>この点に、デフォルトの次の制御点が存在する</TD>
770 </TR>
771 <TR>
772 <TD>0x10</TD>
773 <!-- <TD>pont has default prev control point</TD>-->
774 <TD>この点に、デフォルトの前の制御点が存在する</TD>
775 </TR>
776 <TR>
777 <TD>0x20</TD>
778 <!-- <TD>point is to be rounded in x (truetype hinting. doesn't really work)</TD>-->
779 <TD>この点は x 方向に丸められる必要がある (TrueType のヒントづけです。実際には動作しません)</TD>
780 </TR>
781 <TR>
782 <TD>0x40</TD>
783 <!-- <TD>point is to be rounded in y (truetype hinting. doesn't really work)</TD>-->
784 <TD>この点は y 方向に丸められる必要がある (TrueType のヒントづけです。実際には動作しません)</TD>
785 </TR>
786 <TR>
787 <TD>0x80</TD>
788 <!-- <TD>point was interpolated between two control points (when<BR>
789 read from a ttf file) and so has no point number of its own</TD> -->
790 <TD>この点は (TTF ファイルからの読み込み時に) 2 個の制御点の中点に<BR>補間されたので、独自の点番号が存在しない</TD>
791 <TR>
792 <TD>0x100</TD>
793 <!-- <TD>point should never be interpolated</TD> -->
794 <TD>この点は決して補間してはならない</TD>
795 </TR>
796 </TABLE>
797 <P>
798 <!--
799 Splines for a truetype font will have two additional numbers after the flags.
800 These are the truetype point numbers for the point itself and for the subsequent
801 control point. If the value is -1 then this point has no number. -->
802 TrueType フォント用のスプラインには、フラグの後ろに 2 個の追加の数値が存在します。
803 点それ自身と、引き続く制御点に対しては TrueType 点番号が振られています。値が -1 の場合は、その点には番号が振られていないことを表します。
804 <P>
805 <!--
806 Splines for a font with hint substitution will have a hint mask after any
807 point before which hint substitution occurs, -->
808 ヒント置換を含むフォントのスプラインは、ヒント置換が発生する全ての点の前にヒントマスクが存在します:
809 <BLOCKQUOTE>
810 <PRE>459 422 m 1xc0
811 339 442 l 1xa0
812 312 243 l 1
813 </PRE>
814 </BLOCKQUOTE>
815 <P>
816 <!--
817 So the first two points have hint masks "xc0" and "xa0", these masks may
818 be (almost) arbitrarily long, depending on the number of hints in the glyph.
819 "xc0" means that the first two hints are active (0x80 &amp; 0x40) while "xa0"
820 means that the first and third are (0x80 and 0x20). -->
821 ここでは最初の 2 個の点はヒントマスク“xc0”および“xa0”を含みます。これらのマスクはグリフ内のヒントの個数に応じて (ほとんど) 任意の長さを持つことができます。“xc0”は、最初の 2 個のヒント (0x80 と 0x40) が有効になっていることを示し、“xa0”は、最初と 3 番目 (0x80 と 0x20) が有効であることを意味します。
822 <P>
823 <!--
824 A set of splines in the background is similar, it will be introduced by a
825 <CODE>Back</CODE> entry. -->
826 背景に置かれる一連のスプラインもこれ同様ですが、項目 <CODE>Back</CODE> で始まります。
827 <P>
828 <!--
829 While a background image is stored in the following horrible format: -->
830 一方、背景イメージは以下の恐ろしげなフォーマットで格納されます:
831 <BLOCKQUOTE>
832 <PRE>StartChar: A
833 ...
834 Image: 167 301 0 21 2 1 23 753 2.53892 2.53892
835 J:N0SYd"0-qu?]szzz!!#7`s7cQozzz!!!!(s8Viozzzz"98E!zzzz!!3-"rVuouzzz!!!'"
836 s8N'!zzz!!!!$s8W,7zzzz"98E$huE`WzJ+s!Dz!"],0s6p!g!!!!"s8W-!n,NFg!!!Q0s8Vio
837 z5QCc`s82is!!!!`s8W,gz!WW3"s8W&amp;uzJ,fQKp](9o!!iQ(s8W-!z!&lt;&lt;*!s7cQo!!",@s8W-!
838 ...
839 EndImage
840 EndChar
841 </PRE>
842 </BLOCKQUOTE>
843 <P>
844 <!--
845 Where the numbers on the image line mean respectively: width (of image in
846 pixels), height, image type (0=&gt;mono, 1=&gt;indexed, 2=&gt;true), bytes
847 per line, number of color entries in the color table, the index in the color
848 table of the transparent color (or for true color images the transparent
849 color itself), the x and y coordinates of the upper left corner of the image,
850 the x and y scale factors to convert image pixels into character units. Then
851 follows a bunch of binary data encoded using Adobe's Encode85 filter (See
852 the PostScript Reference manual for a description). These data contain all
853 the colors in the color table followed by a dump of the image pixel data. -->
854 ここで、Image: 行の各数値はそれぞれ以下の意味をもちます: (画像の) 幅 (ピクセル単位)、高さ、画像のタイプ (0⇒単色、1⇒インデックスカラー、2⇒トゥルーカラー)、1 行あたりのバイト数、カラーテーブル内のカラー項目の個数、カラーテーブル内の透明色のインデックス (トゥルーカラー画像においては透明色そのもの)、画像の左上の x 座標および y 座標、画像ピクセルを文字ユニットに変換するための x, y 方向の拡大率です。それから Adobe の Encode85 フィルタによるバイナリデータの束が続きます (この説明は PostScript リファレンスマニュアルを参照してください)。これらのデータはカラーテーブルに含まれる全ての値と、それに続く画像ピクセルデータのダンプです。
855 <P>
856 <!--
857 Bitmap data will be compressed by run length encoding. I'm not going to go
858 into that in detail, if you want to understand it I suggest you look at the
859 file sfd.c and search for image2rle to see how it is done. The image is
860 compressed using rle and then output as above, only now there is one more
861 parameter on the "Image:" line which gives the number of bytes to be read
862 from the data stream. -->
863 ビットマップデータはランレングスエンコーディングで圧縮されます。これの詳細を説明するつもりはありませんので、それを理解する必要がある場合はファイル sfd.c から image2rle を検索して、どう処理を行っているかを調べることをお勧めします。画像はランレングスエンコーディング (RLE) で圧縮され、上記の形式で出力されます。この場合のみ、“Image:”にはデータストリームから読み込まれるバイト数を表すもう 1 つのパラメータが必要となります。
864 <P>
865 <!--
866 A character need not contain any splines: -->
867 文字には、必ずしも何らかのスプラインが含まれないとならないわけではありません。
868 <BLOCKQUOTE>
869 <PRE>StartChar: semicolon
870 Encoding: 59 59
871 Width: 264
872 Flags:
873 HStem:
874 VStem:
875 Refer: 33 44 N 1 0 0 1 0 0 1
876 Refer: 35 46 N 1 0 0 1 0 414 2
877 EndChar
878 </PRE>
879 </BLOCKQUOTE>
880 <P>
881 <!--
882 Above is one with just references to other characters (a semi-colon is drawn
883 here by drawing a comma and stacking a period on top of it). The first number
884 is the glyph index of the character being refered to (in the current font
885 of course), the next number is the unicode code point, the N says the reference
886 is not selected (An "S" indicates it is selected), the following 6 numbers
887 are a postscript transformation matrix, the one for comma (unicode 44) is
888 the identity matrix, while the one for period (unicode 46) just translates
889 it vertically 414 units. The final number is a set of truetype flags: -->
890 上の例は、他の文字への参照のみを含んでいる一例です (セミコロンを、カンマを描画して、その上にピリオドを載せることによって描画しています)。最初の数値は参照先の文字のグリフインデックス (当然、現在のフォント内での) です。2 番目の数値は Unicode の符号位置で、N は、参照が選択されていないことを表し、それに続く 6 個の数値は PostScript の変換行列を表します。カンマ (Unicode 44) の行列は恒等行列で、ピリオド (Unicode 46) に対する行列は垂直方向に 414 ユニット平行移動しています。最後の数値は TrueType フラグの集合です:
891 <UL>
892 <LI>
893 <!-- 1 =&gt; Use My Metrics -->
894 1 ⇒ メトリックで使用
895 <LI>
896 <!-- 2 =&gt; Round to Grid -->
897 2 ⇒ グリッドに合わせて丸める
898 <LI>
899 <!-- 4 =&gt; Position reference by point match (rather than by offset)<BR>
900 If this is set there will be two additional numbers, the first indicating
901 the point number in the base glyph, and the second the point number in the
902 current reference. -->
903 4 ⇒ (オフセットでなく) 点の一致による位置参照<BR>
904 このフラグがセットされている場合、2 個の数字が追加されます。最初の数字は基底グリフ内の点番号で、2 番目の数字は現在の参照における点番号です。
905 <BLOCKQUOTE>
906 <PRE>Ref: 33 44 N 1 0 0 1 0 0 1
907 Ref: 35 46 N 1 0 0 1 0 414 6 3 7 O
908 </PRE>
909 </BLOCKQUOTE>
910 <P>
911 <!-- The bottom line indicates that point 3 and point 7 will be positioned together.
912 The optional "O" is a flag which indicates that this information is out of
913 date. -->
914 最後の行は、点 3 と点 7 が一緒には位置されることを示しています。最後の省略可能な “O”は、この情報が最新の状態と一致しないことを表します。
915 </UL>
916 <P>
917 <!--
918 Old versions of sfd files will use the format: -->
919 古い版の SFD ファイルは以下のフォーマットを使っていました:
920 <BLOCKQUOTE>
921 <PRE>Ref: 44 44 N 1 0 0 1 0 0
922 Ref: 46 46 N 1 0 0 1 0 414
923 </PRE>
924 </BLOCKQUOTE>
925 <P>
926 <!--
927 Where the first number gives the refered components' encoding. -->
928 この最初の数値は、被参照要素の符号位置を指定しています。
929 <P>
930 <!--
931 A postscript glyph may also contain countermasks: -->
932 PostScript のグリフにはカウンタマスクを含めることもできます:
933 <BLOCKQUOTE>
934 <PRE>StartChar: m
935 Encoding: 109 109 77
936 Width: 785
937 HStem: 0 18&lt;28 224 292 488 566 752&gt; 445 27&lt;280 296 542 558&gt;
938 VStem: 98 56&lt;45 376&gt; 362 56&lt;45 378&gt; 626 56&lt;45 378&gt;
939 CounterMasks: 1 38
940 ...
941 EndChar
942 </PRE>
943 </BLOCKQUOTE>
944 <P>
945 <!--
946 The CounterMasks line in this example declares one counter group (first
947 argument). The "38" (and any other values following it) is a bitmask, given
948 in hex, that describes a group. The size of the bitmask is always a multiple
949 of eight (i.e. always an even number of hex digits). The highest-order bit
950 in the mask specifies whether the first stem hint is present (1) or absent
951 (0) in the counter group. The second-highest-order bit does the same for
952 the second hint, and so on. Any extra low-order bits not corresponding to
953 any hint are ignored. (I know, starting from the high bit instead of the
954 low bit seems strange, but that was Adobe's design decision.) Here, the third
955 (0x20), fourth (0x10) and fifth (0x08) stem hints (i.e. the three vertical
956 stems) are in the group, yielding a counter mask of 0x38. If we were to add
957 four more VStem hints to the glyph, making nine hints in all, then the mask
958 would have to be given as 0x3800 (because two bytes are needed to accommodate
959 nine bits).-->
960 この例では、CounterMasks: 行は 1 個のカウンタグループを (最初の引数で) 宣言しています。“38”(およびそれに続く他のすべての値) は、16 進表記のビットマスクで、グループを表しています。ビットマスクのサイズは常に 8 の倍数です (つまり、16 進数は常に偶数桁となります)。マスク内の最上位ビットは、最初のステムヒントが存在する(1) か存在しない(0) かを表します。2 番目の上位ビットは同様に 2 番目のヒントに相当し、以下同様です。どのヒントにも対応しない余計な下位ビットはすべて無視されます。(最下位ビットでなく最上位ビットから始めるのは奇妙だと私も知っていますが、これは Adobe の技術的決定です)。ここでは、3 番目 (0x20), 4 番目 (0x10) および 5 番目 (0x08) のステムヒントがグループ内に存在し、カウンタマスク値は 0x38 となっています。グリフに 4 個の VSTEM ヒントを追加した場合、全部でヒントは 9 個となるので、マスクは 0x3800 となります (9 ビットを格納するには 2 バイト必要だからです)。
961 <P>
962 <!--
963 If a font has been loaded from a truetype file it may containing hinting
964 information (FontForge does not attempt to understand truetype hints, just
965 to preserve them) -->
966 フォントが TrueType ファイルから読み込まれた場合、ヒント情報を含めることができます (FontForge は TrueType ヒントを理解しようとは試みず、単に保持するだけです)。
967 <BLOCKQUOTE>
968 <PRE>TtfInstrs: 107
969 5Xtqo&amp;gTLA(_S)TQj!Kq"UP8&lt;!&lt;rr:&amp;$QcW!"K,K&amp;kWe?(^pl]#mUY&lt;!s\f7"U&gt;G:!%\s-3WRec
970 $pP.r$uZOWNsl$t"H&gt;'?EW%CM&amp;Cer:&amp;f3P&gt;eEnad5&lt;Qq=rQYuk3AE2g&gt;q7E*
971 EndTtf
972 </PRE>
973 </BLOCKQUOTE>
974 <P>
975 <!--
976 This is 107 bytes of ASCII85Encode encoded binary data. -->
977 これは ASCII85Encode で符号化された 107 バイトのバイナリデータです。
978 <P>
979 <!--
980 If the character contains Anchor Points these will be included: -->
981 文字がアンカーポイントを含んでいれば、それらは以下のように取り込まれます:
982 <BLOCKQUOTE>
983 <PRE>AnchorPoint: "bottom" 780 -60 basechar 0
984 AnchorPoint: "top" 803 1487 basechar 0
985 </PRE>
986 </BLOCKQUOTE>
987 <P>
988 <!--
989 the point names the anchor class it belongs to (in UTF-7), its location,
990 what type of point it is (basechar, mark, baselig, basemark, entry, exit),
991 and for ligatures a number indicating which ligature component it refers
992 to. If you have configured fontforge with support for device tables, you
993 may also see: -->
994 アンカークラスが所属する点の名前 (UTF-7 で)、位置、点のタイプが (基底文字、マーク、基底合字、基底マーク、始筆、収筆のうち) どれであるか、そして合字については、それがどの合字要素を参照しているかを示す番号です。デバイステーブルをサポートする設定でコンパイルされた FontForge を使用している場合、以下のような記述が含まれているかもしれません:
995 <BLOCKQUOTE>
996 <PRE>AnchorPoint: "bottom" 780 -60 basechar 0 {12-13 -1,-1} {8-14 1,0,-1,-1,-2,-2,-2}
997 </PRE>
998 </BLOCKQUOTE>
999 <P>
1000 <!--
1001 Where the items in braces are horizontal/vertical
1002 <A NAME="device-table">device</A> tables. The first indicates that the
1003 (horizontal) device table applies to pixel sizes 12 through 13 with pixel
1004 adjustments of -1 pixel each. The second indicates a vertical device table
1005 applies to pixel sizes 8 through 14 with pixel adjustments of 1, 0, -1, -1,
1006 -2, -2, -2 pixels. -->
1007 ここで、波括弧内の項目は水平/垂直<A NAME="device-table">デバイス</A>テーブルです。最初の括弧は、(水平) デバイステーブルが 12〜13 ピクセルの範囲のサイズで、それぞれ -1 ピクセルの補正を施すことを表しています。2 番目は、垂直デバイステーブルが 8〜14 ピクセルの範囲においてでそれぞれ 1, 0, -1, -1, -2, -2, -2 ピクセルの補正を施すことを表します。
1008 <P>
1009 <!--
1010 Finally a TrueType font may position an anchor point based on a normal point
1011 within the glyph (if this is done a device table may not be present). -->
1012 最後に、TrueType フォントは 1 個のアンカーポイントをグリフ内の 1 個の基準点に基づいて配置することができます (これが行われる場合、デバイステーブルを置くことはできません)。
1013 <BLOCKQUOTE>
1014 <PRE>AnchorPoint: "bottom" 780 -60 basechar 0 23
1015 </PRE>
1016 </BLOCKQUOTE>
1017 <P>
1018 <!--
1019 Indicates that this anchor point will be positioned at the same location
1020 (which is normally 780,-60 but which might be moved by an instruction) as
1021 truetype point 23. -->
1022 は、このアンカーポイントが TrueType グリフの点番号 23 と同じ位置 (通常は (780,-60) ですが、命令によって移動することができます) に配置されることを表しています。
1023 <P>
1024 <!--
1025 If the user has set the glyph class -->
1026 ユーザがグリフクラスを設定している場合、
1027 <BLOCKQUOTE>
1028 <PRE>GlyphClass: 2
1029 </PRE>
1030 </BLOCKQUOTE>
1031 <P>
1032 <!--
1033 Where the number is 1 more than the 'GDEF' glyph class it represents. (so
1034 the 2 above means a base glyph (class 1)). -->
1035 この番号は、それが表す&lsquo;GDEF&rsquo;グリフクラスよりも 1 つ大きい値になっています (ですから、この例の 2 はベースグリフ (クラス 1) を意味します)
1036 <P>
1037 <!--
1038 If the character is the first in any kern pairs (not a pair defined by a
1039 kern class, however) -->
1040 その文字がカーニングペアのどれか (ただし、カーニングクラスに定義されているペアを除く) の先頭文字である場合:
1041 <BLOCKQUOTE>
1042 <PRE>KernsSLIFO: 60 -100 1 0 {12-13 -1,-1} 63 -92 1 0 70 -123 1 0 45 -107 1 0 76 -107 1 0
1043 </PRE>
1044 </BLOCKQUOTE>
1045 <P>
1046 <!--
1047 Where each kern pair is represented by 4 numbers (and an optional
1048 <A HREF="sfdformat.html#device-table">device</A> table, see above). The first
1049 is the original position of the second character (in the current font), the
1050 next is the horizontal kerning amount, then the script lang index, and finally
1051 the open type flags. Then we start over with the next kernpair. -->
1052 ここでは各カーニングペアは 4 個の数値 (および省略可能な<A HREF="sfdformat.html#device-table">デバイス</A>テーブル。上記参照) で表されます。最初に来るのは 2 番目の文字の (現在のフォント内での) 位置で、次に来るのは横書きのカーニング量で、スクリプト・言語インデックスがその次に置かれ、最後に OpenType のフラグが来ます。それから、次のカーニングペアの記述が始まります。
1053 <P>
1054 <!--
1055 Old sfd files may contain a slightly different format:-->
1056 古い SFD ファイルは以下の僅かに異なるフォーマットの行を含んでいるかもしれません:
1057 <BLOCKQUOTE>
1058 <PRE>KernsSLIF: 114 -100 1 0 {12-13 -1,-1} 117 -92 1 0 101 -123 1 0 97 -107 1 0 111 -107 1 0
1059 </PRE>
1060 </BLOCKQUOTE>
1061 <P>
1062 <!--
1063 where the first number is the encoding of the second glyph in the kern pair. -->
1064 ここで、最初の数値はカーニングペアの 2 番目のグリフの符号位置です。
1065 <P>
1066 <!--
1067 Data that are to go into other GPOS, GSUB or GDEF sub-tables are stored like
1068 this: -->
1069 その他の GPOS, GSUB または GDEF サブテーブルに送られるデータは、以下のような形で格納されます:
1070 <BLOCKQUOTE>
1071 <PRE>Position: 12 0 'sinf' dx=0 dy=-900 dh=0 dv=0
1072 PairPos: 12 0 'dist' B dx=0 dy=0 dh=0 dv=0 dx=-10 dy=0 dh=0 dv=0
1073 Ligature: 12 0 'frac' one slash four
1074 Substitution: 12 3 'smcp' agrave.sc
1075 AlternateSubs: 12 0 'swsh' glyph490 A.swash
1076 MultipleSubs: 12 0 'ccmp' a grave
1077 Ligature: 12 4 'liga' f f
1078 LCarets: 0 0 ' ' 1 650
1079 </PRE>
1080 </BLOCKQUOTE>
1081 <P>
1082 <!--
1083 In most of these lines the first two numbers provide a script lang index
1084 and a set of opentype flags (except for LCarets where they are ignored).
1085 This is followed by an opentype tag (also ignored for ligature carets). A
1086 simple position change is expressed by the amount of movement of the glyph
1087 and of the glyph's advance width. A ligature contains the names of the characters
1088 of two adjacent glyphs (kerning is a special case of this). A ligature contains
1089 the names of the characters that make it up. A simple substitution contains
1090 the name of the character that it will become. An alternate sub contains
1091 the list of characters that the user may choose from. A multiple substitution
1092 contains the characters the current glyph is to be decomposed into. A ligature
1093 caret contains a count of the number of carets defined, and the a list of
1094 the locations of those carets. -->
1095 これらの行のほとんどは、最初の 2 個の数値では用字系/言語インデックスと、一連の OpenType フラグの情報を提供しています (LCaret は例外で、それらは無視されます)。その後ろに OpenType が来ます (合字キャレットではこれらも無視されます)。単純位置変更はグリフの移動量とグリフの送り幅によって表現されます。ペア単位の位置指定は 2 個の隣り合うグリフの位置を指定します (カーニングはこの特殊な場合です)。合字には、それを構成する各文字の名前が含まれます。単純置換には、それが置き換えられる文字の名前が含まれます。選択型置換には、ユーザが選ぶ文字のリストが含まれます。複数置換は現在のグリフが分解される文字群が含まれます。合字キャレットには、定義されるキャレットの個数と、それらのキャレットの位置のリストが含まれます。
1096 <P>
1097 <!--
1098 A glyph may have an arbitrary comment associated with it, this will be output
1099 in UTF-7 -->
1100 グリフには、それに付随する任意のコメント (UTF-7 で出力されます) や、
1101 <BLOCKQUOTE>
1102 <PRE>Comment: Hi
1103 </PRE>
1104 </BLOCKQUOTE>
1105 <P>
1106 <!--
1107 or a color -->
1108 または色をもたせることができます。
1109 <BLOCKQUOTE>
1110 <PRE>Colour: ff0000
1111 </PRE>
1112 </BLOCKQUOTE>
1113 <H4>
1114 <!--Outline character extensions for multilayered fonts (type3)-->
1115 複数レイヤフォント (Type3) のためのアウトラインフォントの拡張
1116 </H4>
1117 <P>
1118 <!--
1119 (these are only supported if FontForge has been configured for multi-layered
1120 editing) -->
1121 これらは、FontForge の複数レイヤ編集機能が有効な設定のときのみにサポートされます。
1122 <P>
1123 <!--
1124 Instead of having a single "Fore"ground layer, multilayered fonts have
1125 (potentially) several layers, each one introduced by a Layer line which specifies
1126 things like filling and stroking info for this layer, within each layer are
1127 a splineset, a list of references and a list of images (any or all may be
1128 omitted). The syntax for these is the same as in the normal case above. -->
1129 複数レイヤフォントは“Fore”で前面レイヤを 1 個定義するだけでなく、複数のレイヤをもつ (ことが可能な) もので、各レイヤには、そのレイヤの塗りつぶしや太線のような物を指定する Layer: 行が存在し、各レイヤにはスプラインセット、参照のリストや画像のリストが含まれます (これらの任意の物を省略することができます)。これらの構文は、上で説明した通常の場合と同じです。
1130 <BLOCKQUOTE>
1131 <PRE>LayerCount: 3
1132 Layer: 1 1 1 1 #fffffffe 1 #fffffffe 1 40 round round [1 0 0 1] []
1133 SplineSet
1134 ...
1135 EndSplineSet
1136 Layer: 2 1 0 1 #00ff00 1 #0000ff 1 19 miter butt [0.5 0 0 1] [10 5]
1137 SplineSet
1138 ...
1139 EndSplineSet
1140 </PRE>
1141 </BLOCKQUOTE>
1142 <P>
1143 <!--
1144 The LayerCount line gives the number of layers in the glyph (the background
1145 layer is layer 0, so this number is one more than the number of layers that
1146 will actually be specified -- the background layer is still specified the
1147 way it was before, but is included in this count). This line is not required,
1148 if omitted (or wrong) FontForge will figure that out. -->
1149 LayerCount: 行は、グリフ内のレイヤの個数を指定します (背景レイヤはレイヤ 0 なので、この個数は実際に指定されている個数より 1 多くなります——背景レイヤは通常フォントと同様の方法で格納されますが、個数の勘定には入ります)。この行は必須ではなく、省略された (または間違いの) 場合、FontForge は自分で個数を算定します。
1150 <P>
1151 <!--
1152 The Layer line contains too much information. First is a number saying which
1153 layer, next are three booleans, the first specifies whether to fill the splineset
1154 (or use an imagemask for images), the second whether to stroke the splineset,
1155 the third is currently pretty much meaningless. Next follows the RGB value
1156 of the fill color (the special value of #fffffffe means the color is
1157 inherited), then the opacity (the special value -1 means inherited), then
1158 the stroke color and opacity. Then the stroke width (again -1 means inherited),
1159 the linejoin type (miter, round, bevel, inherited), the linecap type (butt,
1160 round,square,inherited), the transformation matrix to be applied to the pen
1161 and finally the dash array. -->
1162 Layer: 行にはあまりにも多量すぎる情報を含んでいます。最初は何番目のレイヤかを表す数字です。その次には 3 個のブール値があり、1 個目はスプラインセットを塗り潰すかどうかを表し、2 番目はスプラインセットをストロークとして描くかどうかを表し、3 番目は現在のところ全く無意味です。その次に、塗り潰し色の RGB 値が続き (特別な値 #fffffffe は、色が継承されることを意味します)、次に透明度 (特別な値 -1 は、継承を意味します)。次にストロークの色と透明度が続きます。それからストロークの太さ (この場合も -1 が継承されることを表します)、線の結びのタイプ (miter, round, bevel, inherited のいずれか), 線端のタイプ (butt, round, square, inherited のいずれか)、ペンに適用される変換行列が来て、最後に、破線を表す配列が来ます。
1163 <P>
1164 <!--
1165 Any SplineSet, Ref, Images between this Layer and the next (or the end of
1166 the character) are part of this layer. -->
1167 この Layer 行から次の Layer 行 (またはこの文字の終り) までに来るすべての SplineSet, Ref, Images はこのレイヤの一部であるとして扱われます。
1168 <H3>
1169 <!--<A NAME="Bitmap-Fonts">Bitmap Fonts</A> -->
1170 <A NAME="Bitmap-Fonts">ビットマップフォント</A>
1171 </H3>
1172 <P>
1173 <!--
1174 After all the outline characters have been described there is an EndChars
1175 entry and then follow any bitmap fonts: -->
1176 アウトライン文字の記述がすべて終った後、項目 EndChars が 1 個あり、ビットマップフォントはすべてその後に出現します。
1177 <BLOCKQUOTE>
1178 <PRE>EndChars
1179 BitmapFont: 12 285 10 2 1
1180 BDFStartProperties: 2
1181 COMMENT 0 "This is a bdf comment property"
1182 FONT_DESCENT 18 2
1183 BDFEndProperties
1184 Resolution: 75
1185 BDFChar: 32 3 0 0 0 0
1186 z
1187 BDFChar: 3 33 3 0 1 0 9
1188 ^d(.M5X7S"!'gMa
1189 </PRE>
1190 </BLOCKQUOTE>
1191 <P>
1192 <!--
1193 The bitmap font line contains the following numbers: the pixelsize of the
1194 font, the number of potential characters in the font, the ascent and the
1195 descent of the font and the depth of font (number of bits in a pixel). -->
1196 BitmapFont: 行には以下の数値が含まれます: フォントのピクセルサイズ、フォント内の可能な文字の個数、フォントの高さおよび深さおよび諧調 (1 ピクセルあたりのビット数) です。
1197 <P>
1198 <!--
1199 Optionally there may be a set of BDF properties. If there are any properties
1200 there will be a line "BDFStartProperties:" with a count of properties. There
1201 should be that many property lines, and then a "BDFEndProperties" line. Each
1202 property is of the form:<BR> -->
1203 そこには省略可能な BDF の属性値を書き込むことができます。何らかの属性がある場合には、“BDFStartProperties:”の後に属性の個数を並べた行が置かれます。指定した個数だけの属性行を並べ、最後に“BDFEndProperties”という行がくる必要があります。各属性は以下のような形で指定します:<BR>
1204 <CODE>&lt;NAME&gt; &lt;TYPE&gt; &lt;VALUE&gt;</CODE><BR>
1205 <!--
1206 Where &lt;NAME&gt; is the property name, &lt;TYPE&gt; is 0 for a string,
1207 1 for an atom, 2 for an int, 3 for an unsigned int. In addition
1208 &lt;TYPE&gt; may have a 16 ored to one of the above values indicating the
1209 line is a true property (rather than information from somewhere else in the
1210 BDF header). &lt;VALUE&gt; will either be a quoted string or an integer. -->
1211 ここで &lt;NAME&gt; は属性名、&lt;TYPE&gt; は 0: 文字列・1: アトム、2: 整数、3: 符号なし整数を表します。さらに、それらの値が (BDF ヘッダの他のどこかから持ってきた値ではなく) 真の設定値を表す場合に &lt;TYPE&gt; の値は 16 との論理和を取った値を格納します。&lt;VALUE&gt; は引用符で囲った文字列か整数かのいずれかです。
1212 <P>
1213 <!--
1214 Optionally there may be a resolution line, which specifies the design resolution
1215 of the font. -->
1216 フォントのデザイン解像度を指定する“Resolution:”行 (省略可能) を最後に置くことができます。
1217 <P>
1218 <!--
1219 This is followed by a list of bitmap characters, the bitmap character line
1220 contains the following numbers: the original position, the encoding (local),
1221 the width, the minimum x value, the minimum y value, the maximum x value
1222 and the maximum y value. If the bitmap font has vertical metrics there will
1223 also be a vwidth. This is followed by another set of binary data encoded
1224 as above. There will be (ymax-ymin+1)* ((xmax-xmin)/(8/depth)+1) (unencoded)
1225 bytes, there is no color table here (the high order bit comes first in the
1226 image, set bits should be colored black, clear bits transparent). -->
1227 これに続き、ビットマップ文字のリストが続きます。BDFChar: 行には以下の数値が含まれます: 元の位置、(フォント内での) 符号位置、幅、x 座標の最小値、y 座標の最小値、x 座標の最大値および y 座標の最大値です。もし、ビットマップに縦書メトリックが存在する場合、縦方向の送り幅が追加されます。この後ろには、上記の例のようにエンコードされた 1 組のデータがさらに続き、このデータの (エンコード前の) サイズは (ymax-ymin-1)*((xmax-xmin+8)/8) バイトになります。ここにはカラーテーブルはありません (上位ビットが画像の最初に来て、1 になっているビットが黒く塗られ、0 のビットが透明になります)。
1228 <P>
1229 <!--
1230 A bitmap font is ended by: -->
1231 ビットマップフォントは次のようにして終了します:
1232 <BLOCKQUOTE>
1233 <PRE>EndBitmapFont
1234 BitmapFont: 17 285 14 3 1
1235 BDFChar: 0 17 0 0 0 0
1236 z
1237 ...
1238 EndBitmapFont
1239 EndSplineFont
1240 </PRE>
1241 </BLOCKQUOTE>
1242 <H3>
1243 <!--<A NAME="CID-keyed-fonts">CID keyed fonts</A>-->
1244 <A NAME="CID-keyed-fonts">CID キー指定フォント</A>
1245 </H3>
1246 <P>
1247 <!--
1248 A CID font is saved slighlty differently. It begins with the normal font
1249 header which contains the information in the top level CID font dictionary.
1250 As mentioned above this will include special keys that specify the CID charset
1251 (registry, ordering, supplement). It will also include: -->
1252 CID フォントはわずかに異なる形で保存されます。それは通常のフォントヘッダで始まりますが、そこにはトップレベルの CID フォント辞書に含まれる情報が格納されます。上で述べたように、これには CID 文字集合 (登録簿、順序づけ、補遺番号) を指定する特別なキーを含んでいるでしょう。そこには以下のような行も含まれるはずです:
1253 <BLOCKQUOTE>
1254 <PRE>CIDVersion: 2.0
1255 BeginSubFonts: 5 8318
1256 </PRE>
1257 </BLOCKQUOTE>
1258 <P>
1259 <!--
1260 The <CODE>CIDVersion</CODE> is self-explanatory. The
1261 <CODE>BeginSubFonts</CODE> line says that there are 5 subfonts the largest
1262 of which contains slots for 8318 characters (again some of these may not
1263 be defined). This will be followed by a list of the subfonts (dumped out
1264 just like normal fonts) and their characters. Only the top level font will
1265 contain any bitmap characters, anchor classes, etc. -->
1266 <CODE>CIDVersion</CODE> はその名の通りです。<CODE>BeginSubFonts</CODE> 行では、 5 個のサブフォントが存在し、そのうちの最大のものは 8318 文字ぶんのスロットが含まれることを示します (この場合も、そのうちのいくつかは定義できません)。これに続きサブフォントのリスト (通常のフォントと同じ形で出力されます) と、それらに含まれる文字が続きます。トップレベルフォントのみがビットマップ文字、アンカークラスなどを含むことができます。
1267 <H3>
1268 <!--<A NAME="Multiple-Master-fonts">Multiple Master fonts</A>-->
1269 <A NAME="Multiple-Master-fonts">マルチプルマスターフォント</A>
1270 </H3>
1271 <P>
1272 <!--
1273 Multiple master fonts start with a different style of file header, and are
1274 followed by a set of sub fonts. If the mm font has 4 instances then there
1275 will be 5 subfonts (one for each instance, and one for the blended font).
1276 The font header looks like: -->
1277 マルチプルマスターフォントは異なるスタイルのファイルヘッダから始まり、それに続いて一連のサブフォントの置かれます。マルチプルマスターフォントに 4 個のインスタンスがある場合は、5 個のサブフォントが存在します (各インスタンスにつき 1 個、混ぜ合わせたフォントにもう 1 個)。フォントヘッダは以下のような形です:
1278 <BLOCKQUOTE>
1279 <PRE>SplineFontDB: 1.0
1280 MMCounts: 4 2 0 0
1281 MMAxis: Weight Width
1282 MMPositions: 0 0 1 0 0 1 1 1
1283 MMWeights: 0.31502 0.13499 0.38499 0.16499
1284 MMAxisMap: 0 2 0=&gt;50 1=&gt;1450
1285 MMAxisMap: 1 2 0=&gt;50 1=&gt;1450
1286 MMCDV:
1287 {
1288 1 index 1 2 index sub mul 3 1 roll
1289 1 2 index sub 1 index mul 3 1 roll
1290 1 index 1 index mul 3 1 roll
1291 pop pop
1292 0 1 1 3 {index add} for 1 exch sub 4 1 roll
1293 }
1294 EndMMSubroutine
1295 MMNDV:
1296 {
1297 exch 50 sub 1400 div
1298 exch 50 sub 1400 div
1299 }
1300 EndMMSubroutine
1301 BeginMMFonts: 5 0
1302 </PRE>
1303 </BLOCKQUOTE>
1304 <P>
1305 <!--
1306 The "MMCounts" line gives the number of instances (4) and the number of axes
1307 (2) in this font also whether it is an apple distortable font (0) and if
1308 so the number of named styles (0) in that font. The "MMAxis" line gives the
1309 names of the axes. The MMPositions line is an array of real numbers (with
1310 instance_count*axis_count elements) describing the coordinates of each instance
1311 along each axis. The MMWeights line provides the weights (blends) of the
1312 instance fonts to which, when interpolated, yield the default font. There
1313 will be one AxisMap line for each axis, it provides the mapping from design
1314 space to normalized space. The first line -->
1315 "MMCounts" 行 では、このフォントに含まれるインスタンスの個数 (4) と軸の本数 (2) に加え、これが Apple 変形可能フォントであるか (0) と、その場合、そのフォントに含まれる名前つきスタイルの個数 (0) を指定します。"MMAxis" 行は、軸の名前を指定します。MMPositions 行は (インスタンスの個数×軸の本数 個の要素からなる) 実数の配列で、各インスタンスの各軸に沿った座標を記述します。MMWeights 行は、補間を行ったときにデフォルトフォントとなるインスタンスフォントのウェイト (混ぜ合わせ) を記述します。AxisMap 行が各軸ごとに 1 個存在し、これは、デザイン空間から正規化された空間への対応づけを提供します。最初の行
1316 <BLOCKQUOTE>
1317 <PRE>MMAxisMap: 0 2 0=&gt;50 1=&gt;1450
1318 </PRE>
1319 </BLOCKQUOTE>
1320 <P>
1321 <!--
1322 says that axis 0 has two mapping points. One is at normalized position 0
1323 and corresponds to design position 50, the other is at normalized position
1324 1 and corresponds to design position 1450. There are two subroutines stored
1325 here, both are simple postscript. The first is the /NormalizeDesignVector
1326 routine and the second is the /ConvertDesignVector routine. -->
1327 では、軸 0 には 2 箇所の点の対応づけが存在することを表します。片方は正規化された位置 0 で、デザイン位置 50 に該当し、もう片方は正規化された位置 1 でデザイン位置 1450 に該当します。ここに格納された 2 個のサブルーチンが存在し、どちらも単純な PostScript です。最初は /NormalizeDesignVector ルーチンで、2 番目は /ConvertDesignVector ルーチンです。
1328 <P>
1329 <!--
1330 Finally we have the actual instance fonts. -->
1331 最後に、実際のインスタンスフォントが来ます。
1332 <HR>
1333 <P>
1334 <!--
1335 Fonts with information for Apple's '*var' tables ('fvar', 'gvar', 'avar'
1336 and 'cvar') have a slightly different format: -->
1337 Apple の&lsquo;*var&rsquo;テーブル群 (&lsquo;fvar&rsquo;,&lsquo;gvar&rsquo;,&lsquo;avar&rsquo;および&lsquo;cvar&rsquo;) の情報を含むフォントはわずかにフォーマットが異なります。
1338 <BLOCKQUOTE>
1339 <PRE>MMCounts: 8 2 1 10
1340 MMAxis: Weight Width
1341 MMPositions: 1 0 -1 0 0 1 0 -1 -1 -1 1 -1 1 1 -1 1
1342 MMWeights: 0 0 0 0 0 0 0 0
1343 MMAxisMap: 0 3 -1=&gt;0.479996 0=&gt;1 1=&gt;3.2
1344 MacName: 0 0 6 "Weight"
1345 MacName: 0 1 15 "Type de graisse"
1346 ...
1347 MMAxisMap: 1 3 -1=&gt;0.619995 0=&gt;1 1=&gt;1.3
1348 MacName: 0 0 5 "Width"
1349 MacName: 0 1 7 "Largeur"
1350 ...
1351 MMNamedInstance: 0 3.2 1
1352 MacName: 0 0 5 "Black"
1353 MacName: 0 1 9 "Tr\217s gras"
1354 ...
1355 </PRE>
1356 </BLOCKQUOTE>
1357 <P>
1358 <!--
1359 In Adobe's format coordinates range between [0,1], while in Apple's format
1360 they range [-1,1]. Adobe generally specifies 2 instances per axis (at the
1361 extrema) while Apple expects 3 (the extrema and the default setting at 0).
1362 So a two axis font for Adobe will normally contain 4 instances and a default
1363 version, while one for Apple will contain 8 instances and a default version.
1364 The MMWeights field is irrelevant for Apple. Each axis has a set of names,
1365 for that axis translated into various languages. Finally Apple allows certain
1366 points in design space to be given names, here the point Weight=3.2, Width=1
1367 is named "Black" or "Tr&eacute;s gras". -->
1368 Adobe のフォーマットでは、座標は区間 [0, 1] をとりますが、Apple のフォーマットでは範囲は [-1, 1] となります。Adobe では一般に、軸ごとに 2 個のインスタンスを(極値で) 指定しますが、Apple では 3 つ (極値と、0 におけるデフォルトの設定) を想定しています。ですから Adobe 方式の 2 軸のフォントでは通常 4 個のインスタンスとデフォルトの版を含むことになりますが、Apple 方式のフォントでは 8 個のインスタンスとデフォルトの版を含むことになります。MMWeights フィールドは、Apple では不適切です。各軸には 1 組の名前があり、各種の言語に翻訳されたその軸の名前を表します。最後に、Apple ではデザイン空間上のいくつかの点に名前をつけることができます。ここでは Weight=3.2, Width=1 の点には“Black”または“Tr&eacute;s gras”という名前がつけられています。
1369 <H2>
1370 <!--<A NAME="Autosave-Format">Autosave Format</A>-->
1371 <A NAME="Autosave-Format">自動保存フォーマット</A>
1372 </H2>
1373 <P>
1374 <!--
1375 <A HREF="errrecovery.html">Error recovery</A> files are saved in
1376 ~/.FontForge/autosave, they have quite random looking names and end in .asfd.
1377 They look very similar to .sfd files above. -->
1378 <A HREF="errrecovery.html">エラー回復</A>ファイルは ~/.FontForge/autosave に保存され、それらはランダムに見える名前がついていて最後に .asfd で終ります。これは上記の .sfd ファイルと非常によく似ています。
1379 <P>
1380 <!--
1381 If an asfd file starts with a line: -->
1382 ある asfd ファイルが次の行で始まるとしたら:
1383 <BLOCKQUOTE>
1384 <PRE>Base: /home/gww/myfonts/fontforge/Ambrosia.sfd
1385 </PRE>
1386 </BLOCKQUOTE>
1387 <P>
1388 <!--
1389 Then it is assumed to be a list of changes applied to that file (which may
1390 be an sfd file or a font file). If it does not start with a
1391 "<CODE>Base:</CODE>" line then it is assumed to be a new font. The next line
1392 contains the encoding, as above. The next line is a <CODE>BeginChars</CODE>
1393 line. The number given on the line is not the number of characters in the
1394 file, but is the maximum number that could appear in the font. Then follows
1395 a list of all changed characters in the font (in the format described above). -->
1396 この場合、それはそのファイル (これは SFD ファイルでもフォントファイルでも構いません) に適用された変更のリストであると想定されます。最初の行が "<CODE>Base:</CODE>" でない場合、新しいフォントであると想定されます。次の行には通常と同様の文字符号が含まれます。その次の行が <CODE>BeginChars</CODE> 行です。この行の数値はファイル内の文字数ではなく、フォント内に現れることのできる最大の数値です。その後ろにフォント内の変更された全ての文字のリストが (上で説明したフォーマットで) 続きます。
1397 <P>
1398 <!--
1399 Bitmaps are not preserved. Grid changes are not preserved. -->
1400 ビットマップは保存されません。グリッドの変更は保存されません。
1401 <P>
1402 <P ALIGN=Center>
1403 — <A HREF="src.html">前</A> — <A HREF="overview.html">目次</A> —
1404 <A HREF="bezier.html">次</A> —
1405 <P ALIGN=Left>
1406 <!--
1407 <A NAME="ASCII85Encode"><SUP>1</SUP>ASCII85Encode</A>: an encoding which
1408 takes 4 binary bytes and converts them to 5 ASCII characters between '!'
1409 and 'u'. Suppose we have 4 binary bytes: (b1 b2 b3 b4) then we want to find
1410 (c1 c2 c3 c4 c5) such that: -->
1411 <A NAME="ASCII85Encode"><SUP>1</SUP>ASCII85Encode</A>: 4 バイトのバイナリを&lsquo;!&rsquo;から&lsquo;u&rsquo;までの ASCII 文字 5 文字に変換する符号化方式の一つです。バイナリ 4 バイト (b1 b2 b3 b4) があるとして、それに対して次の条件を満たす (c1 c2 c3 c4 c5) を探すことを考えましょう:
1412 <BLOCKQUOTE>
1413 <PRE><I>b<SUB>1</SUB> * 256<SUP>3</SUP> + b<SUB>2</SUB> * 256<SUP>2</SUP> + b<SUB>3</SUB> * 256 + b<SUB>4</SUB> =</I>
1414 <I> c<SUB>1</SUB> * 85<SUP>4</SUP> + c<SUB>2</SUB> * 85<SUP>3</SUP> + c<SUB>3</SUB> * 85<SUP>2</SUP> + c<SUB>4</SUB> * 85 + c<SUB>5</SUB></I>
1415 </PRE>
1416 </BLOCKQUOTE>
1417 <P>
1418 <!--
1419 The final output is obtained by adding 33 ('!') to each of the
1420 <I>c<SUB>i</SUB></I>. If all four bytes are 0, then rather than writing '!!!!!',
1421 the letter 'z' may be used instead. -->
1422 最終的な出力は、<I>c<SUB>i</SUB></I> のそれぞれの値に 33 (&lsquo;!&rsquo;) を加えることによって得られます。4 つのバイトがすべて 0 の場合、&lsquo;!!!!!&rsquo;を書き出さないで代わりに文字&lsquo;z&rsquo;を使うことができます。
1423 <P>
1424 <!--
1425 Unfortunately, not all streams of binary data have a length divisible by
1426 4. So at the end of the run, assume there are <I>n</I> bytes left over. Append
1427 <I>4-n</I> zero bytes to the data stream, and apply the above transformation
1428 (without the 'z' special case for all zeros), and output <I>n+1 </I>of the
1429 <I>c<SUB>i</SUB></I> bytes. -->
1430 残念ながら、バイナリデータのストリームの長さは必ずしも 4 で割り切れるわけではありません。そこで、一連のデータの最後に <I>n</I> バイトが残っていたとしましょう。その場合、<I>4-n</I> 個のゼロバイトをデータストリームの末尾に付け加え、上記の変換を適用し (すべてゼロの場合に&lsquo;z&rsquo;を出力する特別な処理を除く)、<I>c<SUB>i</SUB></I> のバイト列のうち最初の <I>n+1</I> 個を出力します。
1431 <P>
1432 <!--
1433 So to encode a single 0 byte we would: -->
1434 ですから、1 個のバイト値 0 を変換するした場合には以下のようになります:
1435 <UL>
1436 <LI>
1437 <!-- append 3 additional 0 bytes (n==1 =&gt; add 4-1=3 bytes)-->
1438 3 個の追加の 0 を後ろに追加する (n==1 ⇒ 4-1=3 バイトを追加)
1439 <LI>
1440 <!-- find that all the <I>c<SUB>i</SUB></I> were also zero-->
1441 すべての <I>c<SUB>i</SUB></I> が 0 になる
1442 <LI>
1443 <!-- add '!' to each (all are now '!')-->
1444 それぞれに&lsquo;!&rsquo;を加える (全バイトが&lsquo;!&rsquo;になる)
1445 <LI>
1446 <!-- output two&lsquo;!&rsquo;(n+1 = 2)-->
1447 2 個の&lsquo;!&rsquo;を追加する (n+1 = 2 だから)
1448 </UL>
1449 <P>
1450 </DIV>
1451 </BODY></HTML>