Re: [pygtk] Switching pixmaps using GtkPixmap.set()

2000-10-31 Thread Tessa Lau


So I'm still trying to write an image viewer with PyGtk and Imlib.  I
looked at the source to Electric Eyes, and this is what it does (im is the
GdkImlibImage created by a call to gdk_imlib_load_image()):

gdk_imlib_render(im, width, height);
pmap = gdk_imlib_move_image(im);
mask = gdk_imlib_move_mask(im);
gdk_window_set_back_pixmap(a->window, pmap, FALSE);
gdk_window_clear(a->window);
gdk_window_shape_combine_mask(a->window, mask, 0, 0);
gdk_imlib_free_pixmap(pmap);

The two interesting calls are the gdk_imlib_move_image and move_mask,
neither or which appears to be wrapped in the GdkImlib module.  But they
seem to be an alternate means of getting a pixmap and a mask from Imlib,
other than get_pixmap.

Am I asking the wrong list?  Is there a list specifically for the GdkImlib
wrapper?  It doesn't seem like it should be this hard to write an image
viewer.

Tessa Lau
[EMAIL PROTECTED]

___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk



Re: [pygtk] pygtk for gtk+-2.0 snapshot

2000-10-31 Thread Hassan Aurag

 Ok This is off-topic, but any timeline about next major gtk/gnome/pygtk/pygnome 
release?

 
> In case anyone is interested, I have put up a snapshot of pygtk for the
> HEAD branch of CVS gtk+,glib and pango.  You can get it at:
>   http://www.gnome.org/~james/pygtk2-SNAP-20001030.tar.gz
> 
> You will need a fairly recent version of gtk+ and glib from CVS, as it
> uses the GSignal code that Tim Janik checked in a week ago.  I don't think
> it will be too difficult to add support for creating new GObject
> subclasses from python, and adding new signals to GObjects.  As the
> GObject code is split off into a separate module (gobject), you may find
> it useful as a general purpose notification framework for non GUI apps.
> 
> You will probably run into dynamic linker problems at first.  It is
> necessary to relink the pango modules and gdk-imlib modules so that they
> link against the libraries they use.  Alternatively, you can modify your
> python sources so that extension modules are loaded with the RTLD_GLOBAL
> flag.
> 
> You can almost test out the new text widget with these bindings.  The
> problem is with signal handlers, as the GtkTextIter arguments are not
> identified as such, so you only get opaque cobjects instead.
> 
> You will need python 2.0 (or maybe 1.6) as some of the unicode
> features.  When importing the gtk module, it will set the default encoding
> to UTF8, so you can pass unicode strings to most parts of gtk, and they
> will convert to UTF8 and display correctly.
> 
> Thread support is disabled at present because I haven't worked out how to
> get things working with the GObject system.  With pygtk-0.6.x, we used
> some hacks that relied on the global GDK lock to synchronise access to the
> python lock.  If there are any threading gurus on the list, I could use
> some help working out how to get things working without the benefit of
> this lock.  I can post some notes on the requirements to get things
> working if that would be helpful.
> 
> James.
> 
> 
> ___
> pygtk mailing list   [EMAIL PROTECTED]
> http://www.daa.com.au/mailman/listinfo/pygtk
> 



-- 
--
--
Hassan Aurag
--
CAE Electronics Ltd |   Universite de Montreal
System update specialist|   Centre de Recherches Mathematiques
++
Maximum Linux Magazine  |   Universite de Montreal
Contributing Editor |   Departement de Maths/Stat
++
EMAIL:  [EMAIL PROTECTED], [EMAIL PROTECTED], 
--
--

History is the version of past events that people have decided to agree on.
-- Napoleon Bonaparte, "Maxims"
--


___
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk