Re: GtkImage size



Uh huh ...

That's a pretty good idea. I'll follow up on it. Thanks!

As for how it could change, imagine that the container is a horizontal panel ... one of those things with the border that you can grab with a mouse and move left or right. So, the user could change that GtkImage dimension. Actually, that reminds me that not only do I need to know when the size has changed, but I also need to be able to veto it if it gets too small.
Still, you got me part way, I think ... thanks!

... anyone else??????


At 06:43 PM 9/10/2005, Nick Watts wrote:
you can use gtk_image_get_pixbuf() to get the pixbuf of the image, then use gdk_pixbuf_get_height() and gdk_pixbuf_get_width() to determine the size.
as for an event when it changes, I don't know how you would do that, but I 
can't imagine how the size would be changed other than explicitly by the 
program in which case, you can allow for it anyway.  Hope that helps, why 
do you need an event for it though?
On 9/11/05, Barry Demchak <<mailto:vendors tpsoft com>vendors tpsoft com> 
wrote:
Hi, all --

Can anyone tell me how I find out the height and width of a GtkImage widget??

I also need to know how to set up an event to tell me when the size changes.

I have been going 'round and 'round in the documentation, and it's just not
very obvious.

Thanks!



_______________________________________________
gtk-app-devel-list mailing list
<mailto:gtk-app-devel-list gnome org>gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list







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