[w3m-dev 04128] Re: w3mimgdisplay

Hiroyuki Ito <[email protected]> Mon, 08 Nov 2004 18:58:46 +0900 (JST)
Newsgroups gmane.comp.web.w3m.devel
Message-ID <[email protected]>

> CVS  w3mimgdisplay 
> * gtk2 (2.2.1) GIF
>   ) http://www.yomiuri.co.jp/gif7/top_hd_yol.gif



$ dpkg -l libgtk2.0-0
=(U)/(I)/(R)/(P)/(H)
| =(N)/(I)/(C)/(U)/(F)/(H)
|/ =()/(H)/(R)/X=(,=)
||/                 
+++-==============-==============-============================================
ii  libgtk2.0-0    2.4.13-1       The GTK+ graphical user interface library


> * configure  --with-imagelib=gdk-pixbuf 
>   configure  5100
>     if test x"$have_gdkpixbuf" = xno; then
>   
>     if test x"$have_gdkpixbuf" != xyes; then
>   




> * () gdk-pixbuf (0.22.0) + gtk (1.2.10) 
>   


gdk-pixbuf  get_animation_size() 


 gdk-pixbuf  GIF animation 




Index: acinclude.m4
===================================================================
RCS file: /cvsroot/w3m/w3m/acinclude.m4,v
retrieving revision 1.38
diff -u -r1.38 acinclude.m4
--- acinclude.m4	4 Aug 2004 17:32:27 -0000	1.38
+++ acinclude.m4	8 Nov 2004 09:49:52 -0000
@@ -666,7 +666,7 @@
 	[have_gdkpixbuf="no"; have_gtk2="no"])
   fi
   if test x"$with_gdkpixbuf" = xyes; then
-   if test x"$have_gdkpixbuf" = xno; then
+   if test x"$have_gdkpixbuf" != xyes; then
     AC_W3M_CHECK_VER([GdkPixbuf],
 	[`$GDKPIXBUF_CONFIG --version 2>/dev/null`],
 	0, 16, 0,
Index: aclocal.m4
===================================================================
RCS file: /cvsroot/w3m/w3m/aclocal.m4,v
retrieving revision 1.39
diff -u -r1.39 aclocal.m4
--- aclocal.m4	4 Aug 2004 17:32:27 -0000	1.39
+++ aclocal.m4	8 Nov 2004 09:49:52 -0000
@@ -678,7 +678,7 @@
 	[have_gdkpixbuf="no"; have_gtk2="no"])
   fi
   if test x"$with_gdkpixbuf" = xyes; then
-   if test x"$have_gdkpixbuf" = xno; then
+   if test x"$have_gdkpixbuf" != xyes; then
     AC_W3M_CHECK_VER([GdkPixbuf],
 	[`$GDKPIXBUF_CONFIG --version 2>/dev/null`],
 	0, 16, 0,
Index: configure
===================================================================
RCS file: /cvsroot/w3m/w3m/configure,v
retrieving revision 1.150
diff -u -r1.150 configure
--- configure	13 Oct 2004 16:52:50 -0000	1.150
+++ configure	8 Nov 2004 09:49:53 -0000
@@ -5097,7 +5097,7 @@
  fi
   fi
   if test x"$with_gdkpixbuf" = xyes; then
-   if test x"$have_gdkpixbuf" = xno; then
+   if test x"$have_gdkpixbuf" != xyes; then
     version="`$GDKPIXBUF_CONFIG --version 2>/dev/null`"
  if test x"$version" != x; then
    echo "$as_me:$LINENO: checking GdkPixbuf version" >&5
Index: w3mimg/fb/fb_gdkpixbuf.c
===================================================================
RCS file: /cvsroot/w3m/w3m/w3mimg/fb/fb_gdkpixbuf.c,v
retrieving revision 1.19
diff -u -r1.19 fb_gdkpixbuf.c
--- w3mimg/fb/fb_gdkpixbuf.c	16 Aug 2004 16:56:40 -0000	1.19
+++ w3mimg/fb/fb_gdkpixbuf.c	8 Nov 2004 09:49:53 -0000
@@ -233,6 +233,7 @@
 	    fb_image_copy(tmp_image, fb_frame[i]);
 	    break;
 	case GDK_PIXBUF_FRAME_DISPOSE:
+	    fb_image_fill(tmp_image, bg_r, bg_g, bg_b);
 	    break;
 	case GDK_PIXBUF_FRAME_REVERT:
 	    fb_image_copy(tmp_image, fb_frame[0]);
Index: w3mimg/x11/x11_w3mimg.c
===================================================================
RCS file: /cvsroot/w3m/w3m/w3mimg/x11/x11_w3mimg.c,v
retrieving revision 1.27
diff -u -r1.27 x11_w3mimg.c
--- w3mimg/x11/x11_w3mimg.c	5 Aug 2004 18:22:16 -0000	1.27
+++ w3mimg/x11/x11_w3mimg.c	8 Nov 2004 09:49:53 -0000
@@ -109,6 +109,7 @@
     }
     if (delay)
 	*delay = d;
+    return n;
 }
 #endif
 #endif
@@ -522,6 +523,9 @@
 		      xi->imageGC, 0, 0, w, h, 0, 0);
 	    break;
 	case GDK_PIXBUF_FRAME_DISPOSE:
+	    XSetForeground(xi->display, xi->imageGC, xi->background_pixel);
+	    XFillRectangle(xi->display, tmp_pixmap, xi->imageGC,
+			   0, 0, w, h);
 	    break;
 	case GDK_PIXBUF_FRAME_REVERT:
 	    XCopyArea(xi->display, ximg->pixmap[0], tmp_pixmap,