]> git.eshelyaron.com Git - emacs.git/commitdiff
(w32font_text_extents): Zero whole metrics struct first.
authorJason Rumney <jasonr@gnu.org>
Mon, 26 May 2008 10:41:58 +0000 (10:41 +0000)
committerJason Rumney <jasonr@gnu.org>
Mon, 26 May 2008 10:41:58 +0000 (10:41 +0000)
src/ChangeLog
src/w32font.c

index f9a137c290e5cd2aeda566174c4ec138075d6592..c67bd19a2955cb9c580b76a6df13fb72d540b64d 100644 (file)
@@ -1,3 +1,7 @@
+2008-05-26  Jason Rumney  <jasonr@gnu.org>
+
+        * w32font.c (w32font_text_extents): Zero whole metrics struct first.
+
 2008-05-25  Kenichi Handa  <handa@m17n.org>
 
        * w32term.c (x_draw_glyph_string): Fix calculation of underline
index 273d98a40e398aab7becd2a04df8e689c7b9a828..22d8c26d069732e326967713e83abd0651e6e8a0 100644 (file)
@@ -358,10 +358,9 @@ w32font_text_extents (font, code, nglyphs, metrics)
     {
       struct w32font_info *w32_font = (struct w32font_info *) font;
 
-      metrics->width = 0;
+      bzero (metrics, sizeof (struct font_metrics));
       metrics->ascent = font->ascent;
       metrics->descent = font->descent;
-      metrics->lbearing = 0;
 
       for (i = 0; i < nglyphs; i++)
         {