-#ifdef HAVE_XWIDGETS
-
-struct GtkFixedPrivateL
-{
- GList *children;
-};
-
-static void emacs_fixed_gtk_widget_size_allocate (GtkWidget *widget,
- GtkAllocation *allocation){
- //for xwidgets
-
- //TODO 1st call base class method
- EmacsFixedClass *klass;
- GtkWidgetClass *parent_class;
- struct GtkFixedPrivateL* priv;
- GtkFixedChild *child;
- GtkAllocation child_allocation;
- GtkRequisition child_requisition;
- GList *children;
- struct xwidget_view* xv;
-
- klass = EMACS_FIXED_GET_CLASS (widget);
- parent_class = g_type_class_peek_parent (klass);
- parent_class->size_allocate (widget, allocation);
-
- priv = G_TYPE_INSTANCE_GET_PRIVATE (widget,
- GTK_TYPE_FIXED,
- struct GtkFixedPrivateL);
-
- gtk_widget_set_allocation (widget, allocation);
-
- if (gtk_widget_get_has_window (widget))
- {
- if (gtk_widget_get_realized (widget))
- gdk_window_move_resize (gtk_widget_get_window (widget),
- allocation->x,
- allocation->y,
- allocation->width,
- allocation->height);
- }
-
- for (children = priv->children;
- children;
- children = children->next)
- {
- child = children->data;
-
- if (!gtk_widget_get_visible (child->widget))
- continue;
-
- gtk_widget_get_preferred_size (child->widget, &child_requisition, NULL);
- child_allocation.x = child->x;
- child_allocation.y = child->y;
-
- if (!gtk_widget_get_has_window (widget))
- {
- child_allocation.x += allocation->x;
- child_allocation.y += allocation->y;
- }
-
- child_allocation.width = child_requisition.width;
- child_allocation.height = child_requisition.height;
-
-
-
- xv = (struct xwidget_view*) g_object_get_data (G_OBJECT (child->widget), XG_XWIDGET_VIEW);
- if(xv){
- child_allocation.width = xv->clip_right;
- child_allocation.height = xv->clip_bottom - xv->clip_top;
- }
- gtk_widget_size_allocate (child->widget, &child_allocation);
-
- }
-
-}
-
-#endif /* HAVE_XWIDGETS */
-