First off lemme apologize for the html based mail... my computer is messed 
up right now.

My problem is... I want to make a 4 pixmpa animation, each pixmap being 
displayed 4 seconds apart. I read up on it, and first you display your first 
pixmap, then do the periodic timer, and then replace the pixmap with a new 
pixmap. I can get it to display the first pixmap, wait the alotted amount of 
time, and then seg faults. Lemme give some portions of my code...

/* generating my pixmaps... i have 4 different pictures */
pix1 = gdk_pixmap_create_from_xpm (window->window,
                                    &mask1,
                                    &style->bg[GTK_STATE_NORMAL],
                                    "./cands.xpm");
pix2 = gdk_pixmap_create_from_xpm (window->window,
                                    &mask2,
                                    &style->bg[GTK_STATE_NORMAL],
                                    "./agftp.xpm");

/* Create a gtk pixmap, display the first pixmap, wait 4 seconds */
  pixmap = gtk_pixmap_new (pix1, mask1);
  gtk_container_add (GTK_CONTAINER (window), vbox);
  gtk_container_border_width (GTK_CONTAINER (vbox), 1);
  gtk_box_pack_start (GTK_BOX (vbox), pixmap, FALSE, TRUE, 0);
  gdk_pixmap_unref (pix1);
  gtk_timeout_add (4000, NULL, NULL);

It works to this point. Now I read that you need to use the command

gtk_pixmap_set (GTK_PIXMAP (pixmap), pix2, mask2);

to replace the pixmap, but if I insert this line in my code, it displays the 
last picture in the seriers first, and then seg faults after the timeout. So 
either way I run into problems. Any suggestions?

Eric
_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com


_______________________________________________
gtk-list mailing list
[EMAIL PROTECTED]
http://mail.gnome.org/mailman/listinfo/gtk-list

Reply via email to