blob: 6d38c4b1a0a032bbe28152868d05ef711b37a71a [file] [log] [blame]
David Turner3475e7f2000-05-17 20:56:01 +00001LATEST_CHANGES
2
David Turner04aa8002000-06-01 03:27:48 +00003 - added the CID-keyed Type 1 driver in "src/cid". Works pretty well for
4 only 13 Kb of code ;-) Doesn't read AFM files though, nor the really
5 useful CMAP files..
6
7 - fixed two bugs in the smooth renderer (src/base/ftgrays.c). Thanks to
8 Boris Letocha for spotting them and providing a fix..
9
David Turner4f99c3c2000-05-29 20:55:13 +000010 - fixed potential "divide by zero" bugs in ftcalc.c.. my god..
11
12 - added source code for the OpenType/CFF driver (still incomplete though..)
13
14 - modified the SFNT driver slightly to perform more robust header
15 checks in TT_Load_SFNT_Header. This prevents certain font files
16 (e.g. some Type 1 Multiple Masters) from being incorrectly "recognized"
17 as TrueType font files..
18
David Turner2e421312000-05-26 22:13:17 +000019 - moved a lot of stuff from the TrueType driver to the SFNT module,
20 this allows greater code re-use between font drivers (e.g. TrueType,
21 OpenType, Compact-TrueType, etc..)
22
23 - added a tiny segment cache to the SFNT Charmap 4 decoder, in order
24 to minimally speed it up..
25
David Turner11187202000-05-26 17:13:23 +000026 - added support for Multiple Master fonts in "type1z". There is also
27 a new file named <freetype/ftmm.h> which defines functions to
28 manage them from client applications.
29
30 The new file "src/base/ftmm.c" is also optional to the engine..
31
32 - various formatting changes (e.g. EXPORT_DEF -> FT_EXPORT_DEF) +
33 small bug fixes in FT_Load_Glyph, the "type1" driver, etc..
34
David Turnerf5dcdd52000-05-23 22:16:27 +000035 - a minor fix to the Type 1 driver to let them apply the font matrix
36 correctly (used for many oblique fonts..)
37
David Turner51179f02000-05-18 16:18:05 +000038 - some fixes for 64-bit systems (mainly changing some FT_TRACE calls
39 to use %p instead of %lx).. Thanks to Karl Robillard
40
David Turner109fcf62000-05-17 23:35:37 +000041 - fixed some bugs in the sbit loader (src/base/sfnt/ttsbit.c) + added
42 a new flag, FT_LOAD_CROP_BITMAP to query that bitmaps be cropped when
43 loaded from a file (maybe I should move the bitmap cropper to the
44 base layer ??).
45
David Turner3475e7f2000-05-17 20:56:01 +000046 - changed the default number of gray levels of the smooth renderer to
47 256 (instead of the previous 128). Of course, the human eye can't
48 see any difference ;-)
49
50 - removed TT_MAX_SUBGLYPHS, there is no static limit on the number of
51 subglyphs in a TrueType font now..
52
53=============================================================================
54OLD CHANGES 16 May 2000
David Turnerefce08d2000-05-11 18:23:52 +000055
David Turner968f0c32000-05-16 23:26:01 +000056 - tagged "BETA-6" in the CVS tree. This one is a serious release candidate
57 even though it doesn't incorporate the auto-hinter yet..
58
59 - various obsolete files were removed, and copyright header updated
60
61 - finally updated the standard raster to fix the monochrome rendering bug
62 + re-enable support for 5-gray levels anti-aliasing (suck, suck..)
63
64 - created new header files, and modified sources accordingly:
David Turnere49ab252000-05-16 23:44:38 +000065
David Turner968f0c32000-05-16 23:26:01 +000066 <freetype/fttypes.h> - simple FreeType types, without the API
67 <freetype/internal/ftmemory.h> - definition of memory-management macros
68
69 - added the "DSIG" (OpenType Digital Signature) tag to <freetype/tttags.h>
70
David Turnerc30aea92000-05-12 15:01:18 +000071 - light update/cleaning of the build system + changes to the sources in
72 order to get rid of _all_ compiler warnings with three compilers, i.e:
73
74 gcc with "-ansi -pedantic -Wall -W", Visual C++ with "/W3 /WX"
75 and LCC
76
77 IMPORTANT NOTE FOR WIN32-LCC USERS:
78 |
79 | It seems the C pre-processor that comes with LCC is broken, it
80 | doesn't recognize the ANSI standard directives # and ## correctly
81 | when one of the argument is a macro. Also, something like:
David Turnere49ab252000-05-16 23:44:38 +000082 |
David Turnerc30aea92000-05-12 15:01:18 +000083 | #define F(x) print##x
David Turnere49ab252000-05-16 23:44:38 +000084 |
David Turnerc30aea92000-05-12 15:01:18 +000085 | F(("hello"))
David Turnere49ab252000-05-16 23:44:38 +000086 |
David Turnerc30aea92000-05-12 15:01:18 +000087 | will get incorrectly translated to:
David Turnere49ab252000-05-16 23:44:38 +000088 |
David Turnerc30aea92000-05-12 15:01:18 +000089 | print "hello")
David Turnere49ab252000-05-16 23:44:38 +000090 |
David Turnerc30aea92000-05-12 15:01:18 +000091 | by its pre-processor. For this reason, you simply cannot build
92 | FreeType 2 in debug mode with this compiler..
93
94
David Turnerbfe2f982000-05-12 12:17:15 +000095 - yet another massive grunt work. I've changed the definition of the
96 EXPORT_DEF, EXPORT_FUNC, BASE_DEF & BASE_FUNC macros. These now take
97 an argument, which is the function's return value type.
David Turnere49ab252000-05-16 23:44:38 +000098
David Turnerbfe2f982000-05-12 12:17:15 +000099 This is necessary to compile FreeType as a DLL on Windows and OS/2.
100 Depending on the compiler used, a compiler-specific keyword like __export
101 or __system must be placed before (VisualC++) or after (BorlandC++)
102 the type..
David Turnere49ab252000-05-16 23:44:38 +0000103
David Turnerbfe2f982000-05-12 12:17:15 +0000104 Of course, this needed a lot of changes throughout the source code
105 to make it compile again... All cleaned up now, apparently..
106
107 Note also that there is a new EXPORT_VAR macro defined to allow the
108 _declaration_ of an exportable public (constant) variable. This is the
109 case of the raster interfaces (see ftraster.h and ftgrays.h), as well
110 as each module's interface (see sfdriver.h, psdriver.h, etc..)
111
112 - new feature: it is now possible to pass extra parameters to font
113 drivers when creating a new face object. For now, this
114 capability is unused. It could however prove to be useful
115 in a near future..
116
117 the FT_Open_Args structure was changes, as well as the internal
118 driver interface (the specific "init_face" module function has now
119 a different signature).
120
121 - updated the tutorial (not finished though).
David Turnerc30aea92000-05-12 15:01:18 +0000122 - updated the top-level BUILD document
David Turnerbfe2f982000-05-12 12:17:15 +0000123
David Turnerc60c61c2000-05-12 15:26:58 +0000124 - fixed a potential memory leak that could occur when loading embedded
125 bitmaps.
126
David Turnerbfe2f982000-05-12 12:17:15 +0000127 - added the declaration of FT_New_Memory_Face in <freetype/freetype.h>, as
128 it was missing from the public header (the implementation was already
129 in "ftobjs.c").
130
131 - the file <freetype/fterrors.h> has been seriously updated in order to
132 allow the automatic generation of error message tables. See the comments
133 within it for more information.
134
David Turnera9c251c2000-05-11 18:36:19 +0000135 - major directory hierarchy re-organisation. This was done for two things:
David Turnere49ab252000-05-16 23:44:38 +0000136
David Turnera9c251c2000-05-11 18:36:19 +0000137 * first, to ease the "manual" compilation of the library by requiring
138 at lot less include paths :-)
David Turnerbfe2f982000-05-12 12:17:15 +0000139
David Turnera9c251c2000-05-11 18:36:19 +0000140 * second, to allow external programs to effectively access internal
141 data fields. For example, this can be extremely useful if someone
142 wants to write a font producer or a font manager on top of FreeType.
143
144 Basically, you should now use the 'freetype/' prefix for header inclusion,
145 as in:
David Turnere49ab252000-05-16 23:44:38 +0000146
David Turnera9c251c2000-05-11 18:36:19 +0000147 #include <freetype/freetype.h>
148 #include <freetype/ftglyph.h>
149
150 Some new include sub-directories are available:
David Turnere49ab252000-05-16 23:44:38 +0000151
David Turnera9c251c2000-05-11 18:36:19 +0000152 a. the "freetype/config" directory, contains two files used to
153 configure the build of the library. Client applications should
154 not need to look at these normally, but they can if they want.
David Turnere49ab252000-05-16 23:44:38 +0000155
David Turnera9c251c2000-05-11 18:36:19 +0000156 #include <freetype/config/ftoption.h>
157 #include <freetype/config/ftconfig.h>
David Turnere49ab252000-05-16 23:44:38 +0000158
David Turnera9c251c2000-05-11 18:36:19 +0000159 b. the "freetype/internal" directory, contains header files that
160 describes library internals. These are the header files that were
161 previously found in the "src/base" and "src/shared" directories.
162
163
164 As usual, the build system and the demos have been updated to reflect
165 the change..
David Turnere49ab252000-05-16 23:44:38 +0000166
David Turnera9c251c2000-05-11 18:36:19 +0000167 Here's a layout of the new directory hierarchy:
David Turnere49ab252000-05-16 23:44:38 +0000168
David Turnera9c251c2000-05-11 18:36:19 +0000169 TOP
170 include/
171 freetype/
172 freetype.h
173 ...
174 config/
175 ftoption.h
176 ftconfig.h
177 ftmodule.h
David Turnere49ab252000-05-16 23:44:38 +0000178
David Turnera9c251c2000-05-11 18:36:19 +0000179 internal/
180 ftobjs.h
181 ftstream.h
182 ftcalc.h
183 ...
David Turnere49ab252000-05-16 23:44:38 +0000184
David Turnera9c251c2000-05-11 18:36:19 +0000185 src/
186 base/
187 ...
David Turnere49ab252000-05-16 23:44:38 +0000188
David Turnera9c251c2000-05-11 18:36:19 +0000189 sfnt/
190 psnames/
191 truetype/
192 type1/
193 type1z/
194
195
196 Compiling a module is now much easier, for example, the following should
David Turner968f0c32000-05-16 23:26:01 +0000197 work when in the TOP directory on an ANSI build:
David Turnere49ab252000-05-16 23:44:38 +0000198
David Turnera9c251c2000-05-11 18:36:19 +0000199 gcc -c -I./include -I./src/base src/base/ftbase.c
200 gcc -c -I./include -I./src/sfnt src/sfnt/sfnt.c
201 etc..
202
203 (of course, using -Iconfig/<system> if you provide system-specific
204 configuration files).
David Turnerefce08d2000-05-11 18:23:52 +0000205
206
207 - updated the structure of FT_Outline_Funcs in order to allow
208 direct coordinate scaling within the outline decomposition routine
209 (this is important for virtual "on" points with TrueType outlines)
210 + updates to the rasters to support this..
211
212 - updated the OS/2 table loading code in "src/sfnt/ttload.c" in order
213 to support version 2 of the table (see OpenType 1.2 spec)
214
215 - created "include/tttables.h" and "include/t1tables.h" to allow
216 client applications to access some of the SFNT and T1 tables of a
217 face with a procedural interface (see FT_Get_Sfnt_Table())
218 + updates to internal source files to reflect the change..
219
220 - some cleanups in the source code to get rid of warnings when compiling
221 with the "-Wall -W -ansi -pedantic" options in gcc.
222
223 - debugged and moved the smooth renderer to "src/base/ftgrays.c" and
224 its header to "include/ftgrays.h"
225
226 - updated TT_MAX_SUBGLYPHS to 96 as some CJK fonts have composites with
227 up to 80 sub-glyphs !! Thanks to Werner
228
229================================================================================
230OLD CHANGES - 14-apr-2000
David Turner77054f22000-04-14 20:49:52 +0000231
232 - fixed a bug in the TrueType glyph loader that prevented the correct
233 loading of some CJK glyphs in mingli.ttf
David Turnere49ab252000-05-16 23:44:38 +0000234
David Turner77054f22000-04-14 20:49:52 +0000235 - improved the standard Type 1 hinter in "src/type1"
David Turnere49ab252000-05-16 23:44:38 +0000236
David Turner77054f22000-04-14 20:49:52 +0000237 - fixed two bugs in the experimental Type 1 driver in "src/type1z"
238 to handle the new XFree86 4.0 fonts (and a few other ones..)
239
240 - the smooth renderer is now complete and supports sub-banding
241 to render large glyphs at high speed. However, it is still located
242 in "demos/src/ftgrays.c" and should move to the library itself
243 in the next beta.. NOTE: The smooth renderer doesn't compile in
244 stand-alone mode anymore, but this should be fixed RSN..
David Turnere49ab252000-05-16 23:44:38 +0000245
David Turner77054f22000-04-14 20:49:52 +0000246 - introduced convenience functions to more easily deal with glyph
247 images, see "include/ftglyph.h" for more details, as well as the
248 new demo program named "demos/src/ftstring.c" that demonstrates
249 its use
250
251 - implemented FT_LOAD_NO_RECURSE in both the TrueType and Type 1
252 drivers (this is required by the auto-hinter to improve its results).
253
254 - changed the raster interface, in order to allow client applications
255 to provide their own span-drawing callbacks. However, only the
256 smooth renderer supports this. See "FT_Raster_Params" in the
257 file "include/ftimage.h"
258
259 - fixed a small bug in FT_MulFix that caused incorrect transform
260 computation !!
261
262 - Note: The tutorial is out-of-date, grumpf.. :-(
263
264================================================================================
265OLD CHANGES - 12-mar-2000
David Turnerc3c7e7f2000-03-13 14:19:31 +0000266
267 - changed the layout of configuration files : now, all ANSI configuration
268 files are located in "freetype2/config". System-specific over-rides
269 can be placed in "freetype2/config/<system>".
David Turnere49ab252000-05-16 23:44:38 +0000270
David Turnerc3c7e7f2000-03-13 14:19:31 +0000271 - moved all configuration macros to "config/ftoption.h"
David Turnere49ab252000-05-16 23:44:38 +0000272
David Turnerc3c7e7f2000-03-13 14:19:31 +0000273 - improvements in the Type 1 driver with AFM support
David Turnere49ab252000-05-16 23:44:38 +0000274
David Turnerc3c7e7f2000-03-13 14:19:31 +0000275 - changed the fields in the FT_Outline structure : the old "flags"
276 array is re-named "tags", while all ancient flags are encoded into
277 a single unsigned int named "flags".
278
279 - introduced new flags in FT_Outline.flags (see ft_outline_.... enums in
280 "ftimage.h").
281
282 - changed outline functions to "FT_Outline_<action>" syntax
283
284 - added a smooth anti-alias renderer to the demonstration programs
285 - added Mac graphics driver (thanks Just)
David Turnere49ab252000-05-16 23:44:38 +0000286
David Turnerc3c7e7f2000-03-13 14:19:31 +0000287 - FT_Open_Face changed in order to received a pointer to a FT_Open_Args
288 descriptor..
David Turnere49ab252000-05-16 23:44:38 +0000289
David Turnerc3c7e7f2000-03-13 14:19:31 +0000290 - various cleanups, a few more API functions implemented (see FT_Attach_File)
291
292 - updated some docs
293
294================================================================================
295OLD CHANGES - 22-feb-2000
David Turner58c10b52000-02-22 14:31:42 +0000296
297 - introduced the "psnames" module. It is used to:
298
299 o convert a Postscript glyph name into the equivalent Unicode
300 character code (used by the Type 1 driver(s) to synthetize
301 on the fly a Unicode charmap).
302
303 o provide an interface to retrieve the Postscript names of
304 the Macintosh, Adobe Standard & Adobe Expert character codes.
305 (the Macintosh names are used by the SFNT-module postscript
306 names support routines, while the other two tables are used
307 by the Type 1 driver(s)).
308
309 - introduced the "type1z" alternate Type 1 driver. This is a (still
310 experimental) driver for the Type 1 format that will ultimately
311 replace the one in "src/type1". It uses pattern matching to load
312 data from the font, instead of a finite state analyzer. It works
313 much better than the "old" driver with "broken" fonts. It is also
314 much smaller (under 15 Kb).
315
316 - the Type 1 drivers (both in "src/type1" and "src/type1z") are
317 nearly complete. They both provide automatic Unicode charmap
318 synthesis through the "psnames" module. No re-encoding vector
319 is needed. (note that they still leak memory due to some code
320 missing, and I'm getting lazy).
321
322 Trivial AFM support has been added to read kerning information
323 but wasn't exactly tested as it should ;-)
324
325 - The TrueType glyph loader has been seriously rewritten (see the
326 file "src/truetype/ttgload.c". It is now much, much simpler as
327 well as easier to read, maintain and understand :-) Preliminary
328 versions introduced a memory leak that has been reported by Jack
329 Davis, and is now fixed..
330
331 - introduced the new "ft_glyph_format_plotter", used to represent
332 stroked outlines like Windows "Vector" fonts, and certain Type 1
333 fonts like "Hershey". The corresponding raster will be written
334 soon.
335
336 - FT_New_Memory_Face is gone. Likewise, FT_Open_Face has a new
337 interface that uses a structure to describe the input stream,
338 the driver (if required), etc..
339
340TODO
341 - Write FT_Get_Glyph_Bitmap and FT_Load_Glyph_Bitmap
342
343 - Add a function like FT_Load_Character( face, char_code, load_flags )
344 that would really embbed a call to FT_Get_Char_Index then FT_Load_Glyph
345 to ease developer's work.
346
347 - Update the tutorial !!
348 - consider adding support for Multiple Master fonts in the Type 1
349 drivers.
350
351 - Test the AFM routines of the Type 1 drivers to check that kerning
352 information is returned correctly.
353
354 - write a decent auto-gridding component !! We need this to release
355 FreeType 2.0 gold !
356
357
358----- less urgent needs : ----------
359 - add a CFF/Type2 driver
360 - add a BDF driver
361 - add a FNT/PCF/HBF driver
362 - add a Speedo driver from the X11 sources
363
364
365==============================================================================
366OLDER CHANGES - 27-jan-2000
David Turner633da992000-01-27 14:07:33 +0000367
368 - updated the "sfnt" module interface to allow several SFNT-based
369 drivers to co-exist peacefully
David Turnere49ab252000-05-16 23:44:38 +0000370
David Turner633da992000-01-27 14:07:33 +0000371 - updated the "T1_Face" type to better separate Postscript font content
372 from the rest of the FT_Face structure. Might be used later by the
373 CFF/Type2 driver..
David Turnere49ab252000-05-16 23:44:38 +0000374
David Turner633da992000-01-27 14:07:33 +0000375 - added an experimental replacement Type 1 driver featuring advanced
376 (and speedy) pattern matching to retrieve the data from postscript
377 fonts.
378
379 - very minor changes in the implementation of FT_Set_Char_Size and
380 FT_Set_Pixel_Sizes (they now implement default to ligthen the
381 font driver's code).
382
383
384=============================================================================
385OLD MESSAGE
386
David Turnerd2b1f351999-12-16 23:11:37 +0000387This file summarizes the changes that occured since the last "beta" of FreeType 2.
388Because the list is important, it has been divided into separate sections:
389
David Turner5951ce91999-12-29 00:53:44 +0000390Table Of Contents:
391
392 I High-Level Interface (easier !)
393 II Directory Structure
394 III Glyph Image Formats
395 IV Build System
396 V Portability
397 VI Font Drivers
David Turnerd2b1f351999-12-16 23:11:37 +0000398
399-----------------------------------------------------------------------------------------
400High-Level Interface :
401
402 The high-level API has been considerably simplified. Here is how :
403
David Turner5951ce91999-12-29 00:53:44 +0000404 - resource objects have disappeared. this means that face objects can
405 now be created with a single function call (see FT_New_Face and
David Turnerd2b1f351999-12-16 23:11:37 +0000406 FT_Open_Face)
David Turnere49ab252000-05-16 23:44:38 +0000407
David Turnerd2b1f351999-12-16 23:11:37 +0000408 - when calling either FT_New_Face & FT_Open_Face, a size object and a
409 glyph slot object are automatically created for the face, and can be
410 accessed through "face->glyph" and "face->size" if one really needs to.
411 In most cases, there's no need to call FT_New_Size or FT_New_Glyph.
David Turnere49ab252000-05-16 23:44:38 +0000412
David Turnerd2b1f351999-12-16 23:11:37 +0000413 - similarly, FT_Load_Glyph now only takes a "face" argument (instead of
414 a glyph slot and a size). Also, it's "result" parameter is gone, as
415 the glyph image type is returned in the field "face->glyph.format"
David Turnere49ab252000-05-16 23:44:38 +0000416
David Turnerd2b1f351999-12-16 23:11:37 +0000417 - the list of available charmaps is directly accessible through
418 "face->charmaps", counting "face->num_charmaps" elements. Each
419 charmap has an 'encoding' field which specifies which known encoding
420 it deals with. Valid values are, for example :
David Turnere49ab252000-05-16 23:44:38 +0000421
David Turnerd2b1f351999-12-16 23:11:37 +0000422 ft_encoding_unicode (for ASCII, Latin-1 and Unicode)
423 ft_encoding_apple_roman
424 ft_encoding_sjis
425 ft_encoding_adobe_standard
David Turner5951ce91999-12-29 00:53:44 +0000426 ft_encoding_adobe_expert
David Turnere49ab252000-05-16 23:44:38 +0000427
David Turnerd2b1f351999-12-16 23:11:37 +0000428 other values may be added in the future. Each charmap still holds its
429 "platform_id" and "encoding_id" values in case the encoding is too
430 exotic for the current library
431
432
433-----------------------------------------------------------------------------------------
434Directory Structure:
435
436 Should seem obvious to most of you:
437
438 freetype/
439 config/ -- configuration sub-makefiles
440 ansi/
David Turner5951ce91999-12-29 00:53:44 +0000441 unix/ -- platform-specific configuration files
David Turnerd2b1f351999-12-16 23:11:37 +0000442 win32/
443 os2/
444 msdos/
445
446 include/ -- public header files, those to be included directly
447 by client apps
448
449 src/ -- sources of the library
450 base/ -- the base layer
451 sfnt/ -- the sfnt "driver" (see the drivers section below)
452 truetype/ -- the truetype driver
453 type1/ -- the type1 driver
454 shared/ -- some header files shared between drivers
455
456 demos/ -- demos/tools
457
458 docs/ -- documentation (a bit empty for now)
459
460-----------------------------------------------------------------------------------------
461Glyph Image Formats :
462
463 Drivers are now able to register new glyph image formats within the library.
464 For now, the base layer supports of course bitmaps and vector outlines, but
465 one could imagine something different like colored bitmaps, bi-color
466 vectors or wathever else (Metafonts anyone ??).
467
468 See the file `include/ftimage.h'. Note also that the type FT_Raster_Map is
469 gone, and is now replaced by FT_Bitmap, which should encompass all known
470 bitmap types.
471
472 Each new image format must provide at least one "raster", i.e. a module
David Turner5951ce91999-12-29 00:53:44 +0000473 capable of transforming the glyph image into a bitmap. It's also possible
David Turnerd2b1f351999-12-16 23:11:37 +0000474 to change the default raster used for a given glyph image format.
475
476 The default outline scan-converter now uses 128 levels of grays by default,
477 which tends to smooth many things. Note that the demo programs have been
David Turner5951ce91999-12-29 00:53:44 +0000478 updated significantly in order to display these..
David Turnerd2b1f351999-12-16 23:11:37 +0000479
480
481-----------------------------------------------------------------------------------------
482Build system :
483
484 You still need GNU Make to build the library. The build system has been
485 very seriously re-vamped in order to provide things like :
486
487 - automatic host platform detection (reverting to 'config/ansi'
488 if it is not detected, with pseudo-standard compilation flags)
489
490 - the ability to compile from the Makefiles with very different and
491 exotic compilers. Note that linking the library can be difficult for
492 some platforms.
493
494 For example, the file `config/win32/lcclib.bat' is invoked by the
495 build system to create the ".lib" file with LCC-Win32 because its
496 librarian has too many flaws to be invoked directly from the Makefile.
497
498 Here's how it works :
499
500 - the first time you type `make', the build system runs a series of
501 sub-makefiles in order to detect your host platform. It then dumps
502 what it found, and creates a file called `config.mk' in the current
503 directory. This is a sub-Makefile used to define many important Make
504 variables used to build the library.
505
506 - the second time, the build system detects the `config.mk' then use it
507 to build the library. All object files go into 'obj' by default, as
508 well as the library file, but this can easily be changed.
509
510 Note that you can run "make setup" to force another host platform detection
511 even if a `config.mk' is present in the current directory. Another solution
512 is simply to delete the file, then re-run make.
513
514 Finally, the default compiler for all platforms is gcc (for now, this will
515 hopefully changed in the future). You can however specify a different
516 compiler by specifying it after the 'setup' target as in :
517
518 gnumake setup lcc on Win32 to use the LCC compiler
519 gnumake setup visualc on Win32 to use Visual C++
520
521 See the file `config/<system>/detect.mk' for a list of supported compilers
522 for your platforms.
523
524 It should be relatively easy to write new detection rules files and
525 config.mk..
526
527 Finally, to build the demo programs, go to `demos' and launch GNU Make,
528 it will use the `config.mk' in the top directory to build the test
529 programs..
530
531-----------------------------------------------------------------------------------------
532Portability :
533
534 In the previous beta, a single FT_System object was used to encompass
535 all low-level operations like thread synchronisation, memory management
536 and i/o access. This has been greatly simplified :
537
538 - thread synchronisation has been dropped, for the simple reason that
539 the library is already re-entrant, and that if you really need two
540 threads accessing the same FT_Library, you should really synchronize
541 access to it yourself with a simple mutex.
542
543 - memory management is performed through a very simple object called
544 "FT_Memory", which really is a table containing a table of pointers
545 to functions like malloc, realloc and free as well as some user data
546 (closure).
547
548 - resources have disappeared (they created more problems than they
549 solved), and i/o management have been simplified greatly as a
550 result. Streams are defined through FT_Stream objects, which can
551 be either memory-based or disk-based.
552
553 Note that each face has its own stream, which is closed only when
554 the face object is destroyed. Hence, a function like TT_Flush_Face
555 in 1.x cannot be directly supported. However, if you really need
556 something like this, you can easily tailor your own streams to achieve
557 the same feature at a lower level (and use FT_Open_Face instead of
558 FT_New_Face to create the face).
559
560 See the file "include/ftsystem.h" for more details, as well as the
561 implementations found in "config/unix" and "config/ansi".
562
563
564-----------------------------------------------------------------------------------------
David Turner5951ce91999-12-29 00:53:44 +0000565Font Drivers :
David Turnere49ab252000-05-16 23:44:38 +0000566
David Turner5951ce91999-12-29 00:53:44 +0000567
568 The Font Driver interface has been modified in order to support
569 extensions & versioning.
570
571
572 The list of the font drivers that are statically linked to the
573 library at compile time is managed through a new configuration file
574 called `config/<platform>/ftmodule.h'.
575
576 This file is autogenerated when invoking `make modules'. This target
577 will parse all sub-directories of 'src', looking for a "module.mk"
578 rules file, used to describe the driver to the build system.
579
580 Hence, one should call `make modules' each time a font driver is added
581 or removed from the `src' directory.
582
583
584 Finally, this version provides a "pseudo-driver" in `src/sfnt'. This
585 driver doesn't support font files directly, but provides services used
586 by all TrueType-like font drivers. Hence, its code is shared between
587 the TrueType & OpenType font formats, and possibly more formats to
588 come if we're lucky..
David Turnerd2b1f351999-12-16 23:11:37 +0000589
590-----------------------------------------------------------------------------------------
591Extensions support :
David Turner5951ce91999-12-29 00:53:44 +0000592
593 The extensions support is inspired by the one found in 1.x.
594
595 Now, each font driver has its own "extension registry", which lists
596 which extensions are available for the font faces managed by the driver.
597
598 Extension ids are now strings, rather than 4-byte tags, as this is
599 usually more readable..
600
601 Each extension has:
602 - some data, associated to each face object
603 - an interface (table of function pointers)
604
605 An extension that is format-specific should simply register itself
606 to the correct font driver. Here is some example code:
607
608 // Registering an extensions
609 //
610 FT_Error FT_Init_XXXX_Extension( FT_Library library )
611 {
612 FT_DriverInterface* tt_driver;
613
614 driver = FT_Get_Driver( library, "truetype" );
615 if (!driver) return FT_Err_Unimplemented_Feature;
616
David Turnere49ab252000-05-16 23:44:38 +0000617 return FT_Register_Extension( driver, &extension_class );
David Turner5951ce91999-12-29 00:53:44 +0000618 }
619
David Turnere49ab252000-05-16 23:44:38 +0000620
David Turner5951ce91999-12-29 00:53:44 +0000621 // Implementing the extensions
622 //
623 FT_Error FT_Proceed_Extension_XXX( FT_Face face )
624 {
625 FT_XXX_Extension ext;
626 FT_XXX_Extension_Interface ext_interface;
627
628 ext = FT_Get_Extension( face, "extensionid", &ext_interface );
629 if (!ext) return error;
630
631 return ext_interface->do_it(ext);
632 }
David Turnerd2b1f351999-12-16 23:11:37 +0000633