How to use GtkAllocation to find absolute x,y co-ordinates?
- From: "Harinandan S" <harinandans gmail com>
- To: gtk-list gnome org
- Subject: How to use GtkAllocation to find absolute x,y co-ordinates?
- Date: Sat, 29 Mar 2008 19:23:19 +0530
Hi All,
I want to find the absolute x,y co-ordinates and width and height of a widget. I looked at GTK API reference and found GtkAllocation. I tried it in my program but
gint x = widget->allocation.x ;
returned -1. What does that mean? I want x,y coordinates in terms of the pixel values. I also tried widget->allocation.y but that also returned -1.
Am i going wrong somewhere? I used this statement immediately after creating the widget.
--
Regards,
Harinandan S
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]