Cleanups.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167
diff --git a/ChangeLog b/ChangeLog
index e7eabe1..0c83c64 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -21,9 +21,9 @@
2003-04-09 Mike Fabian <mfabian@suse.de>
- * src/bdf/bdfdrivr.h (BDF_encoding_el), src/pcf/pcf.h: Changed
- FT_Short to FT_UShort in order to be able to access more than 32768
- glyphs in fonts.
+ * src/bdf/bdfdrivr.h (BDF_encoding_el), src/pcf/pcf.h
+ (PCF_EncodingRec): Changed FT_Short to FT_UShort in order to be able
+ to access more than 32768 glyphs in fonts.
2003-04-08 David Turner <david@freetype.org>
@@ -87,13 +87,13 @@
* src/base/ftobjs.c: Implement them.
(ft_glyphslot_done): Use ft_glyphslot_free_bitmap.
- * src/bdf/bdfdrivr.c (BDF_Glyph_Load): Remove unused variable
- `memory'.
+ * src/bdf/bdfdrivr.c (BDF_Glyph_Load), src/pcf/pcfdriver.c
+ (PCF_Glyph_Load): Remove unused variable `memory'.
Use `ft_glyphslot_*' functions.
Don't set `FT_GLYPH_OWN_BITMAP'.
- * src/pcf/pcfdriver.c, src/pfr/pfrsbit.c,
- src/sfnt/ttsbit.c, src/type42/t42objs.c, src/winfonts/winfnt.c:
+ * src/pfr/pfrsbit.c, src/sfnt/ttsbit.c, src/type42/t42objs.c,
+ src/winfonts/winfnt.c:
* src/cache/ftlru.c (FT_LruList_Lookup): Fixed an invalid assertion
check.
@@ -294,7 +294,13 @@
(bdf_get_bdf_property, bdf_driver_requester): New functions.
(bdf_driver_class): Use `bdf_driver_requester'.
- * src/pcf/pcfdrivr.c, src/pcf/pcfread.h:
+ * src/pcf/pcfdrivr.c: Include FT_BDF_H.
+ (pcf_get_bdf_property, pdc_driver_requester): New functions
+ (pcf_driver_class): Use `pcf_driver_requester'.
+
+ * src/pcf/pcfread.c: Include `pcfread.h'.
+ (pcf_find_property): Decorate it with FT_LOCAL_DEF.
+ * src/pcf/pcfread.h: New file, providing `pcf_find_property'.
* src/sfnt/ttload.c (sfnt_dir_check): Relaxed the "head" table size
verification to accept a few broken fonts who pad the size
@@ -627,18 +633,21 @@
2002-10-31 David Turner <david@freetype.org>
+ Add support for automatic handling of gzip-compressed PCF files.
+
* src/gzip/*: New files, taken from the zlib package (except
ftgzip.c).
- * include/freetype/ftgzip.h, src/gzip/ftgzip.c: New files, adding
- support for gzip compressed streams.
+ * include/freetype/ftgzip.h, src/gzip/ftgzip.c: New files.
* include/freetype/config/ftheader.h (FT_GZIP_H): New macro for
`ftgzip.h'.
- * src/pcf/pcfdriver.c: Adding automatic support for gzip-compressed
- PCF files.
- * include/freetype/internal/pcftypes.h (PCF_Public_FaceRec): Add
- `gzip_stream' and `gzip_source'.
+ * src/pcf/pcfdriver.c: Include FT_GZIP_H and FT_ERRORS_H.
+ (PCF_Face_Init): If normal open fails, try to open gzip stream.
+ (PCF_Face_Done): Close gzip stream.
+
+ * include/freetype/internal/pcftypes.h (PCF_Public_FaceRec),
+ src/pcf/pcf.h (PCF_FaceRec): Add `gzip_stream' and `gzip_source'.
* include/freetype/config/ftoption.h (FT_CONFIG_OPTION_USE_ZLIB):
New macro.
diff --git a/src/pcf/pcf.h b/src/pcf/pcf.h
index 5223564..64acefc 100644
--- a/src/pcf/pcf.h
+++ b/src/pcf/pcf.h
@@ -2,7 +2,7 @@
FreeType font driver for pcf fonts
- Copyright (C) 2000-2001, 2002 by
+ Copyright (C) 2000, 2001, 2002, 2003 by
Francesco Zappa Nardelli
Permission is hereby granted, free of charge, to any person obtaining a copy
diff --git a/src/pcf/pcfdriver.c b/src/pcf/pcfdriver.c
index 6f0b9e1..269a088 100644
--- a/src/pcf/pcfdriver.c
+++ b/src/pcf/pcfdriver.c
@@ -2,7 +2,7 @@
FreeType font driver for pcf files
- Copyright (C) 2000-2001, 2002 by
+ Copyright (C) 2000, 2001, 2002, 2003 by
Francesco Zappa Nardelli
Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -242,7 +242,8 @@ THE SOFTWARE.
{
FT_Error error2;
- /* this didn't work, try gzip support !! */
+
+ /* this didn't work, try gzip support! */
error2 = FT_Stream_OpenGzip( &face->gzip_stream, stream );
if ( error2 == FT_Err_Unimplemented_Feature )
goto Fail;
@@ -464,7 +465,8 @@ THE SOFTWARE.
const char* prop_name,
BDF_PropertyRec *aproperty )
{
- PCF_Property prop;
+ PCF_Property prop;
+
prop = pcf_find_property( face, prop_name );
if ( prop != NULL )
@@ -476,15 +478,16 @@ THE SOFTWARE.
}
else
{
- /* apparently, the PCF driver loads all properties as signed integers !
- * this really doesn't seem to be a problem, because this is
- * sufficient for any meaningful values
- */
+ /* apparently, the PCF driver loads all properties as signed integers!
+ * This really doesn't seem to be a problem, because this is
+ * sufficient for any meaningful values.
+ */
aproperty->type = BDF_PROPERTY_TYPE_INTEGER;
aproperty->u.integer = prop->value.integer;
}
return 0;
}
+
return FT_Err_Invalid_Argument;
}
diff --git a/src/pcf/pcfread.h b/src/pcf/pcfread.h
index 5f54ba6..c9524f1 100644
--- a/src/pcf/pcfread.h
+++ b/src/pcf/pcfread.h
@@ -2,7 +2,7 @@
FreeType font driver for pcf fonts
- Copyright 2000-2001 by
+ Copyright 2003 by
Francesco Zappa Nardelli
Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -39,7 +39,7 @@ FT_BEGIN_HEADER
FT_END_HEADER
-#endif /* __PCFUTIL_H__ */
+#endif /* __PCFREAD_H__ */
/* END */