Re: Size of Widgets
- From: Tristan Van Berkom <tristan van berkom gmail com>
- To: Tapan Satpathy Ansuman-A19108 <ansuman motorola com>
- Cc: GTK App Devel List <gtk-app-devel-list gnome org>
- Subject: Re: Size of Widgets
- Date: Tue, 9 Nov 2004 10:10:17 -0500
On Tue, 9 Nov 2004 17:47:51 +0530, Tapan Satpathy Ansuman-A19108
<ansuman motorola com> wrote:
Hi,
I am trying to get the width and height of the widgets.
For this I am using
widget->allocation.width and
widget->allocation.height.
But both the values are always coming to be 1.
Is there anything else to be done?
My guess is that you are obtaining these values before the parent
("container") widget has allocated any size for that widget.
You can connect to the "size-allocate" signal to get that value every
time the widget gets resized, as well as when it recieves its initial
allocation.
Cheers,
-Tristan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]