[gnumeric] fix format warnings #646571



commit 75b36ffcbab1c3a4a768677a49ac821a75f74227
Author: Andreas J Guelzow <aguelzow pyrshep ca>
Date:   Sat Apr 2 17:48:23 2011 -0600

    fix format warnings #646571
    
    2011-04-02  Andreas J. Guelzow <aguelzow pyrshep ca>
    
    	* src/mstyle.c (gnm_style_dump_color): fix format warning
    	(gnm_style_dump): ditto, fixes #646571

 ChangeLog    |    5 +++++
 src/mstyle.c |    6 +++---
 2 files changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 3da07ae..0d77be7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2011-04-02  Andreas J. Guelzow <aguelzow pyrshep ca>
+
+	* src/mstyle.c (gnm_style_dump_color): fix format warning
+	(gnm_style_dump): ditto, fixes #646571
+
 2011-03-31  Morten Welinder  <terra gnome org>
 
 	* src/gui-file.c (gui_file_open): Plug leak.
diff --git a/src/mstyle.c b/src/mstyle.c
index f540242..15e8082 100644
--- a/src/mstyle.c
+++ b/src/mstyle.c
@@ -1791,7 +1791,7 @@ static void
 gnm_style_dump_color (GnmColor *color, GnmStyleElement elem)
 {
 	if (color)
-		g_printerr ("\t%s: %hx:%hx:%hx\n", gnm_style_element_name [elem],
+		g_printerr ("\t%s: %x:%x:%x\n", gnm_style_element_name [elem],
 			    GO_COLOR_UINT_R (color->go_color),
 			    GO_COLOR_UINT_G (color->go_color),
 			    GO_COLOR_UINT_B (color->go_color));
@@ -1863,9 +1863,9 @@ gnm_style_dump (GnmStyle const *style)
 		g_printerr ("\tformat '%s'\n", fmt);
 	}
 	if (elem_is_set (style, MSTYLE_ALIGN_V))
-		g_printerr ("\tvalign %hd\n", style->v_align);
+		g_printerr ("\tvalign %hd\n", (short)style->v_align);
 	if (elem_is_set (style, MSTYLE_ALIGN_H))
-		g_printerr ("\thalign %hd\n", style->h_align);
+		g_printerr ("\thalign %hd\n", (short)style->h_align);
 	if (elem_is_set (style, MSTYLE_INDENT))
 		g_printerr ("\tindent %d\n", style->indent);
 	if (elem_is_set (style, MSTYLE_ROTATION))



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]