* src/pcf/pcfdriver.c (PCF_Glyph_Load): Fix computation of horiBearingX. * src/bdf/bdfdrivr.c (BDF_GlyphLoad): Fix computation of horiBearingY.
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
diff --git a/ChangeLog b/ChangeLog
index 206f0b2..de0b404 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2002-08-18 Werner Lemberg <wl@gnu.org>
+
+ * src/pcf/pcfdriver.c (PCF_Glyph_Load): Fix computation of
+ horiBearingX.
+ * src/bdf/bdfdrivr.c (BDF_GlyphLoad): Fix computation of
+ horiBearingY.
+
2002-08-16 George Williams <gww@silcom.com>
Add support for Apple composite glyphs.
diff --git a/src/bdf/bdfdrivr.c b/src/bdf/bdfdrivr.c
index 3773432..391dec8 100644
--- a/src/bdf/bdfdrivr.c
+++ b/src/bdf/bdfdrivr.c
@@ -617,7 +617,8 @@ THE SOFTWARE.
/* FZ XXX: TODO: vertical metrics */
slot->metrics.horiAdvance = glyph.dwidth << 6;
slot->metrics.horiBearingX = glyph.bbx.x_offset << 6;
- slot->metrics.horiBearingY = glyph.bbx.y_offset << 6;
+ slot->metrics.horiBearingY = ( glyph.bbx.y_offset +
+ glyph.bbx.height ) << 6;
slot->metrics.width = bitmap->width << 6;
slot->metrics.height = bitmap->rows << 6;
diff --git a/src/pcf/pcfdriver.c b/src/pcf/pcfdriver.c
index 812e2be..ac9dda3 100644
--- a/src/pcf/pcfdriver.c
+++ b/src/pcf/pcfdriver.c
@@ -388,7 +388,7 @@ THE SOFTWARE.
goto Exit;
if ( PCF_BIT_ORDER( face->bitmapsFormat ) != MSBFirst )
- BitOrderInvert( bitmap->buffer,bytes );
+ BitOrderInvert( bitmap->buffer, bytes );
if ( ( PCF_BYTE_ORDER( face->bitmapsFormat ) !=
PCF_BIT_ORDER( face->bitmapsFormat ) ) )
@@ -412,7 +412,7 @@ THE SOFTWARE.
slot->bitmap_top = metric->ascent;
slot->metrics.horiAdvance = metric->characterWidth << 6 ;
- slot->metrics.horiBearingX = metric->rightSideBearing << 6 ;
+ slot->metrics.horiBearingX = metric->leftSideBearing << 6 ;
slot->metrics.horiBearingY = metric->ascent << 6 ;
slot->metrics.width = metric->characterWidth << 6 ;
slot->metrics.height = bitmap->rows << 6;