[Gd-chatter] r11387 - in branches/opendylan-melange: gtk gtk-duim

andreas at gwydiondylan.org andreas at gwydiondylan.org
Wed May 30 01:46:07 CEST 2007


Author: andreas
Date: Wed May 30 01:46:05 2007
New Revision: 11387

Modified:
   branches/opendylan-melange/gtk-duim/gtk-events.dylan
   branches/opendylan-melange/gtk/gtk.dylan
   branches/opendylan-melange/gtk/module.dylan
   branches/opendylan-melange/gtk/support.c
Log:
job: fd

Add gtk-widget-get-allocation.


Modified: branches/opendylan-melange/gtk-duim/gtk-events.dylan
==============================================================================
--- branches/opendylan-melange/gtk-duim/gtk-events.dylan	(original)
+++ branches/opendylan-melange/gtk-duim/gtk-events.dylan	Wed May 30 01:46:05 2007
@@ -288,7 +288,7 @@
 define method handle-gtk-configure-event
     (sheet :: <sheet>, widget :: <GtkWidget>, event :: <GdkEventConfigure>)
  => (handled? :: <boolean>)
-  let allocation = widget.GtkWidget-allocation;
+  let allocation = widget.gtk-widget-get-allocation;
   let native-x  = event.GdkEventConfigure-x;
   let native-y  = event.GdkEventConfigure-y;
   let native-width  = allocation.GdkRectangle-width;

Modified: branches/opendylan-melange/gtk/gtk.dylan
==============================================================================
--- branches/opendylan-melange/gtk/gtk.dylan	(original)
+++ branches/opendylan-melange/gtk/gtk.dylan	Wed May 30 01:46:05 2007
@@ -32,6 +32,12 @@
   c-name: "gtk_widget_get_state";
 end;
 
+define C-function gtk-widget-get-allocation
+  input parameter widget :: <GtkWidget>;
+  result allocation :: <GtkAllocation>;
+  c-name: "gtk_widget_get_allocation";
+end;
+
 
 
 define method make(type :: subclass(<GTypeInstance>), #rest args, 

Modified: branches/opendylan-melange/gtk/module.dylan
==============================================================================
--- branches/opendylan-melange/gtk/module.dylan	(original)
+++ branches/opendylan-melange/gtk/module.dylan	Wed May 30 01:46:05 2007
@@ -13,6 +13,7 @@
   export g-signal-connect, initialize-gtk,
     gtk-widget-get-window,
     gtk-widget-get-state,
+    gtk-widget-get-allocation,
     property-getter-definer,
     property-setter-definer,
     \with-gdk-lock;

Modified: branches/opendylan-melange/gtk/support.c
==============================================================================
--- branches/opendylan-melange/gtk/support.c	(original)
+++ branches/opendylan-melange/gtk/support.c	Wed May 30 01:46:05 2007
@@ -29,3 +29,8 @@
 int gtk_widget_get_state (GtkWidget* widget) {
     return GTK_WIDGET_STATE(widget);
 }
+
+struct GtkAllocation* gtk_widget_get_allocation (GtkWidget* widget) {
+    return &(widget->allocation);
+}
+



More information about the chatter mailing list