* src/autohint/ahglyph.c (ah_outline_link_segments): Remove unused variables. * src/autohint/ahhint.c (ah_align_serif_edge): Use FT_UNUSED instead of UNUSED. * src/autohint/ahmodule.c (ft_autohinter_reset): Ditto. * src/pshinter/pshrec.c (ps_mask_table_merge): Fix typo in variable swapping code. * src/pshinter/pshglob.h (PSH_Blue_Align): Add PSH_BLUE_ALIGN_NONE. * src/pshinter/pshglob.c (psh_blues_snap_stem): Use it. * src/pshinter/pshalgo1.c (psh1_hint_table_optimize): Ditto. * src/pshinter/pshalgo2.c (psh2_hint_align): Ditto. * include/freetype/internal/ftobjs.h (UNUSED): Removed.
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 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218
diff --git a/ChangeLog b/ChangeLog
index 8132b99..403c5ad 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,18 @@
+2002-02-18 Werner Lemberg <wl@gnu.org>
+
+ * src/autohint/ahglyph.c (ah_outline_link_segments): Remove unused
+ variables.
+ * src/autohint/ahhint.c (ah_align_serif_edge): Use FT_UNUSED instead
+ of UNUSED.
+ * src/autohint/ahmodule.c (ft_autohinter_reset): Ditto.
+ * src/pshinter/pshrec.c (ps_mask_table_merge): Fix typo in variable
+ swapping code.
+ * src/pshinter/pshglob.h (PSH_Blue_Align): Add PSH_BLUE_ALIGN_NONE.
+ * src/pshinter/pshglob.c (psh_blues_snap_stem): Use it.
+ * src/pshinter/pshalgo1.c (psh1_hint_table_optimize): Ditto.
+ * src/pshinter/pshalgo2.c (psh2_hint_align): Ditto.
+ * include/freetype/internal/ftobjs.h (UNUSED): Removed.
+
2002-02-10 Roberto Alameda <ojancano@geekmail.de>
Add support for ISOLatin1 PS encoding.
diff --git a/builds/unix/ftconfig.in b/builds/unix/ftconfig.in
index 4fa7e8b..ce20cf6 100644
--- a/builds/unix/ftconfig.in
+++ b/builds/unix/ftconfig.in
@@ -71,8 +71,8 @@ FT_BEGIN_HEADER
#define FT_ALIGNMENT 8
- /* UNUSED is a macro used to indicate that a given parameter is not used */
- /* -- this is only used to get rid of unpleasant compiler warnings */
+ /* FT_UNUSED is a macro used to indicate that a given parameter is not */
+ /* used -- this is only used to get rid of unpleasant compiler warnings */
#ifndef FT_UNUSED
#define FT_UNUSED( arg ) ( (arg) = (arg) )
#endif
diff --git a/builds/vms/ftconfig.h b/builds/vms/ftconfig.h
index 8b7525c..f5e5e64 100644
--- a/builds/vms/ftconfig.h
+++ b/builds/vms/ftconfig.h
@@ -71,8 +71,8 @@ FT_BEGIN_HEADER
#define FT_ALIGNMENT 8
- /* UNUSED is a macro used to indicate that a given parameter is not used */
- /* -- this is only used to get rid of unpleasant compiler warnings */
+ /* FT_UNUSED is a macro used to indicate that a given parameter is not */
+ /* used -- this is only used to get rid of unpleasant compiler warnings */
#ifndef FT_UNUSED
#define FT_UNUSED( arg ) ( (arg) = (arg) )
#endif
diff --git a/include/freetype/config/ftconfig.h b/include/freetype/config/ftconfig.h
index f990c90..9d6d8fb 100644
--- a/include/freetype/config/ftconfig.h
+++ b/include/freetype/config/ftconfig.h
@@ -86,8 +86,8 @@ FT_BEGIN_HEADER
#define FT_ALIGNMENT 8
- /* UNUSED is a macro used to indicate that a given parameter is not used */
- /* -- this is only used to get rid of unpleasant compiler warnings */
+ /* FT_UNUSED is a macro used to indicate that a given parameter is not */
+ /* used -- this is only used to get rid of unpleasant compiler warnings */
#ifndef FT_UNUSED
#define FT_UNUSED( arg ) ( (arg) = (arg) )
#endif
diff --git a/include/freetype/internal/ftobjs.h b/include/freetype/internal/ftobjs.h
index 31b79c0..755faf8 100644
--- a/include/freetype/internal/ftobjs.h
+++ b/include/freetype/internal/ftobjs.h
@@ -54,10 +54,6 @@ FT_BEGIN_HEADER
#define NULL (void*)0
#endif
-#ifndef UNUSED
-#define UNUSED( arg ) ( (arg)=(arg) )
-#endif
-
/*************************************************************************/
/* */
diff --git a/src/autohint/ahglyph.c b/src/autohint/ahglyph.c
index 756db65..49da901 100644
--- a/src/autohint/ahglyph.c
+++ b/src/autohint/ahglyph.c
@@ -976,12 +976,8 @@
FT_Pos min = seg1->min_coord;
FT_Pos max = seg1->max_coord;
FT_Pos len, dist, score;
- FT_Pos size1, size2;
- size1 = max - min;
- size2 = seg2->max_coord - seg2->min_coord;
-
if ( min < seg2->min_coord )
min = seg2->min_coord;
diff --git a/src/autohint/ahhint.c b/src/autohint/ahhint.c
index 1c212a0..5c02589 100644
--- a/src/autohint/ahhint.c
+++ b/src/autohint/ahhint.c
@@ -158,7 +158,7 @@
FT_Pos dist;
FT_Pos sign = 1;
- UNUSED( hinter );
+ FT_UNUSED( hinter );
dist = serif->opos - base->opos;
diff --git a/src/autohint/ahmodule.c b/src/autohint/ahmodule.c
index 1b9b188..f8d54b9 100644
--- a/src/autohint/ahmodule.c
+++ b/src/autohint/ahmodule.c
@@ -79,7 +79,7 @@
ft_autohinter_reset( FT_AutoHinter module,
FT_Face face )
{
- UNUSED( module );
+ FT_UNUSED( module );
if ( face->autohint.data )
ah_hinter_done_face_globals( (AH_Face_Globals*)(face->autohint.data) );
diff --git a/src/cache/ftccache.c b/src/cache/ftccache.c
index 54d06ab..bd334aa 100644
--- a/src/cache/ftccache.c
+++ b/src/cache/ftccache.c
@@ -360,8 +360,8 @@
for ( i = 0; i < cache->size; i++ )
{
- FTC_Node node, next, *pnode;
- FT_UFast hash;
+ FTC_Node node, next, *pnode;
+ FT_UFast hash;
node = cache->buckets[i];
diff --git a/src/pshinter/pshalgo1.c b/src/pshinter/pshalgo1.c
index b8e8e1f..a31d829 100644
--- a/src/pshinter/pshalgo1.c
+++ b/src/pshinter/pshalgo1.c
@@ -415,7 +415,7 @@
hint->cur_len = fit_len;
/* check blue zones for horizontal stems */
- align.align = 0;
+ align.align = PSH_BLUE_ALIGN_NONE;
align.align_bot = align.align_top = 0;
if ( !vertical )
{
diff --git a/src/pshinter/pshalgo2.c b/src/pshinter/pshalgo2.c
index af30cdd..27ee5c1 100644
--- a/src/pshinter/pshalgo2.c
+++ b/src/pshinter/pshalgo2.c
@@ -387,7 +387,7 @@
hint->cur_len = fit_len;
/* check blue zones for horizontal stems */
- align.align = 0;
+ align.align = PSH_BLUE_ALIGN_NONE;
align.align_bot = align.align_top = 0;
if ( dimension == 1 )
diff --git a/src/pshinter/pshglob.c b/src/pshinter/pshglob.c
index db89890..49fb843 100644
--- a/src/pshinter/pshglob.c
+++ b/src/pshinter/pshglob.c
@@ -493,7 +493,7 @@
FT_Int no_shoots;
- alignment->align = 0;
+ alignment->align = PSH_BLUE_ALIGN_NONE;
no_shoots = blues->no_overshoots;
diff --git a/src/pshinter/pshglob.h b/src/pshinter/pshglob.h
index 1058fb1..157cb23 100644
--- a/src/pshinter/pshglob.h
+++ b/src/pshinter/pshglob.h
@@ -143,6 +143,7 @@ FT_BEGIN_HEADER
typedef enum
{
+ PSH_BLUE_ALIGN_NONE = 0,
PSH_BLUE_ALIGN_TOP = 1,
PSH_BLUE_ALIGN_BOT = 2
diff --git a/src/pshinter/pshrec.c b/src/pshinter/pshrec.c
index 7839505..c54ed06 100644
--- a/src/pshinter/pshrec.c
+++ b/src/pshinter/pshrec.c
@@ -414,7 +414,7 @@
{
temp = index1;
index1 = index2;
- index2 = index1;
+ index2 = temp;
}
if ( index1 < index2 && index1 >= 0 && index2 < (FT_Int)table->num_masks )
diff --git a/src/truetype/ttgload.c b/src/truetype/ttgload.c
index 8157a68..7b2a0f6 100644
--- a/src/truetype/ttgload.c
+++ b/src/truetype/ttgload.c
@@ -1087,7 +1087,7 @@
if ( num_subglyphs > 0 &&
loader->exec &&
- ins_pos > 0 &&
+ ins_pos > 0 &&
subglyph->flags & WE_HAVE_INSTR )
{
FT_UShort n_ins;