Functionalities for backbuffering GtkWidgets drawing?? help!!




From: Jan-Marek Glogowski <glogow fbihome de>
Date: 2004/07/23 Fri PM 08:53:56 EST
To: crypto_stonelock sympatico ca
CC: gtk-app-devel-list gnome org
Subject: Re: Help with flickering widgets when showing and hiding!!

What happens, if you use

window = GTK_WIDGET( my_gtk_list )->window;
or
window = GTK_WIDGET( my_gtk_window )->window

gdk_window_freeze_updates( window );
gtk_widget_show( item_old );
gtk_widget_hide( item_new );
gdk_window_thaw_updates( window );
[gdk_flush();]

HTH

Jan-Marek


Hello,

Jan-Marek gave me a few ideas but i'm still having trouble finding what I need. Does anybody know If anything 
similar to this bit of code would work? I know this doesn't work but im looking for the code equivalent using 
GTK instead of GDK. GDK has all I need but I'm using GTK for my widgets...i'm not directly drawing around in 
a drawable widget. The gdk_window_begin_paint_region function draws to a backbuffer and then when 
gdk_window_end_paint is called, the backbuffer is drawn on screen. GtkWindow doesn't seem to offer these 
functionalities. Where should I look?

      GdkRectangle rectangle;
      rectangle.x = GTK_WIDGET( listeDitemsMenuPartiePlanifiee1GestionEquipe )->allocation.x;
      rectangle.y = GTK_WIDGET( listeDitemsMenuPartiePlanifiee1GestionEquipe )->allocation.y;
      rectangle.width = 1000;
      rectangle.height = 1000;
      GdkRegion* region = gdk_region_rectangle( &rectangle );
      GdkWindow* windowFreeze = GTK_WIDGET( listeDitemsMenuPartiePlanifiee1GestionEquipe )->window;
      gdk_window_begin_paint_region( GDK_WINDOW( windowFreeze ), region );

      /* Here I show stuff on screen */
      PartiesEquipe( 10, RecVar1.NoEqu1, 1 );
      PartiesEquipe( 10, RecVar1.NoEqu2, 2 );
      /*******************************/
 
      gdk_window_end_paint( GDK_WINDOW( windowFreeze ));
      gdk_flush();





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