Re: Size of a drawable: how?




"Sergei O. Naoumov" <serge@physics.unc.edu> writes:

> Hi!
> How do I get the size of a drawable after it is created? It is clear if the
> drawable is a widget. In this case it's just widget->allocation.width and
> widget->allocation.height. But... What do I do if my drawable is a pixmap?
> Is there any universal way to get the drawable's size?

 void         gdk_window_get_geometry    (GdkWindow       *window,
                                          gint            *x,
                                          gint            *y,
                                          gint            *width,
                                          gint            *height,
                                          gint            *depth);

Yep, that really works for pixmaps.

Regards,
                                        Owen



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