[glade3/signal-tree-model: 277/358] Merge branch 'master' into signal-tree-model



commit 75bf078ff3099b800a5b482df00c44228144ec80
Merge: 6ca40fc 0988109
Author: Johannes Schmid <jhs gnome org>
Date:   Thu Dec 30 14:32:02 2010 +0100

    Merge branch 'master' into signal-tree-model
    
    Conflicts:
    	gladeui/glade-app.c
    	gladeui/glade-base-editor.c
    	gladeui/glade-editor.c
    	gladeui/glade-project.c
    	gladeui/glade-signal-editor.c
    	gladeui/glade-signal.c
    	gladeui/glade-widget.c

 ChangeLog                                 |  106 +
 Makefile.am                               |    4 +-
 autogen.sh                                |   42 +-
 configure.ac                              |   48 +-
 doc/gladeui.types                         |    1 -
 gladeui/Makefile.am                       |    2 -
 gladeui/glade-accumulators.c              |  100 +-
 gladeui/glade-accumulators.h              |    1 -
 gladeui/glade-app.c                       | 1944 ++--
 gladeui/glade-app.h                       |    9 +-
 gladeui/glade-base-editor.c               | 3472 +++---
 gladeui/glade-base-editor.h               |    1 -
 gladeui/glade-builtins.c                  |  734 +-
 gladeui/glade-builtins.h                  |    1 -
 gladeui/glade-catalog.c                   | 1194 +-
 gladeui/glade-catalog.h                   |   22 -
 gladeui/glade-cell-renderer-icon.c        |  177 +-
 gladeui/glade-cell-renderer-icon.h        |    1 -
 gladeui/glade-clipboard-view.c            |  388 -
 gladeui/glade-clipboard-view.h            |   52 -
 gladeui/glade-clipboard.c                 |  269 +-
 gladeui/glade-clipboard.h                 |    1 -
 gladeui/glade-command.c                   | 3488 +++---
 gladeui/glade-command.h                   |    5 -
 gladeui/glade-cursor.c                    |  262 +-
 gladeui/glade-cursor.h                    |    1 -
 gladeui/glade-debug.c                     |   27 +-
 gladeui/glade-debug.h                     |    1 -
 gladeui/glade-design-layout.c             | 1283 +-
 gladeui/glade-design-view.c               |  318 +-
 gladeui/glade-displayable-values.c        |  198 +-
 gladeui/glade-displayable-values.h        |    1 -
 gladeui/glade-editable.c                  |   49 +-
 gladeui/glade-editable.h                  |    1 -
 gladeui/glade-editor-property.c           | 5504 ++++-----
 gladeui/glade-editor-property.h           |    5 -
 gladeui/glade-editor-table.c              |  547 +-
 gladeui/glade-editor-table.h              |    7 +-
 gladeui/glade-editor.c                    | 2043 ++--
 gladeui/glade-editor.h                    |    1 -
 gladeui/glade-fixed.c                     | 1769 ++--
 gladeui/glade-fixed.h                     |    1 -
 gladeui/glade-id-allocator.c              |  201 +-
 gladeui/glade-id-allocator.h              |    1 -
 gladeui/glade-inspector.c                 | 1250 +-
 gladeui/glade-inspector.h                 |    1 -
 gladeui/glade-name-context.c              |  306 +-
 gladeui/glade-name-context.h              |    1 -
 gladeui/glade-named-icon-chooser-dialog.c | 2808 +++---
 gladeui/glade-palette.c                   | 1211 +-
 gladeui/glade-palette.h                   |    1 -
 gladeui/glade-parameter.c                 |  285 +-
 gladeui/glade-parameter.h                 |    1 -
 gladeui/glade-placeholder.c               |  655 +-
 gladeui/glade-placeholder.h               |    1 -
 gladeui/glade-popup.c                     | 1253 +-
 gladeui/glade-popup.h                     |    1 -
 gladeui/glade-previewer.c                 |  518 +-
 gladeui/glade-previewer.rc.in             |   29 +
 gladeui/glade-project.c                   | 7108 +++++------
 gladeui/glade-project.h                   |    9 +-
 gladeui/glade-property-class.c            | 2814 +++---
 gladeui/glade-property-class.h            |   17 +-
 gladeui/glade-property.c                  | 1828 ++--
 gladeui/glade-property.h                  |    8 -
 gladeui/glade-signal-editor.c             |    1 +
 gladeui/glade-signal-editor.h             |    1 -
 gladeui/glade-signal.c                    |  255 +-
 gladeui/glade-signal.h                    |    2 -
 gladeui/glade-utils.c                     | 2552 ++--
 gladeui/glade-utils.h                     |    4 +-
 gladeui/glade-widget-action.c             |  326 +-
 gladeui/glade-widget-action.h             |    1 -
 gladeui/glade-widget-adaptor.c            | 5578 +++++-----
 gladeui/glade-widget-adaptor.h            |   58 +-
 gladeui/glade-widget.c                    | 5326 ++++----
 gladeui/glade-widget.h                    |    1 -
 gladeui/glade-xml-utils.c                 | 1039 +-
 gladeui/glade-xml-utils.h                 |   35 +-
 gladeui/glade.h                           |    2 -
 gladeui/icon-naming-spec.c                |   57 +-
 plugins/gtk+/Makefile.am                  |    2 +-
 plugins/gtk+/glade-accels.c               | 1339 +-
 plugins/gtk+/glade-accels.h               |    1 -
 plugins/gtk+/glade-activatable-editor.c   |  629 +-
 plugins/gtk+/glade-activatable-editor.h   |    1 -
 plugins/gtk+/glade-attributes.c           | 1898 ++--
 plugins/gtk+/glade-attributes.h           |    1 -
 plugins/gtk+/glade-button-editor.c        |  836 +-
 plugins/gtk+/glade-button-editor.h        |    1 -
 plugins/gtk+/glade-cell-renderer-editor.c |  970 +-
 plugins/gtk+/glade-cell-renderer-editor.h |    1 -
 plugins/gtk+/glade-column-types.c         | 1378 ++--
 plugins/gtk+/glade-column-types.h         |    1 -
 plugins/gtk+/glade-convert.c              |  914 --
 plugins/gtk+/glade-entry-editor.c         | 1230 +-
 plugins/gtk+/glade-entry-editor.h         |    1 -
 plugins/gtk+/glade-gtk.c                  |18967 ++++++++++++++---------------
 plugins/gtk+/glade-gtk.h                  |    1 -
 plugins/gtk+/glade-icon-factory-editor.c  |  252 +-
 plugins/gtk+/glade-icon-factory-editor.h  |    1 -
 plugins/gtk+/glade-icon-sources.c         | 1689 ++--
 plugins/gtk+/glade-icon-sources.h         |    1 -
 plugins/gtk+/glade-image-editor.c         |  626 +-
 plugins/gtk+/glade-image-editor.h         |    1 -
 plugins/gtk+/glade-image-item-editor.c    |  658 +-
 plugins/gtk+/glade-image-item-editor.h    |    1 -
 plugins/gtk+/glade-label-editor.c         | 1167 +-
 plugins/gtk+/glade-label-editor.h         |    5 -
 plugins/gtk+/glade-model-data.c           | 1995 ++--
 plugins/gtk+/glade-model-data.h           |    1 -
 plugins/gtk+/glade-store-editor.c         |  311 +-
 plugins/gtk+/glade-store-editor.h         |    1 -
 plugins/gtk+/glade-text-button.c          |  147 +-
 plugins/gtk+/glade-text-button.h          |    1 -
 plugins/gtk+/glade-tool-button-editor.c   |  824 +-
 plugins/gtk+/glade-tool-button-editor.h   |    3 -
 plugins/gtk+/glade-treeview-editor.c      |  350 +-
 plugins/gtk+/glade-treeview-editor.h      |    1 -
 plugins/gtk+/gtk+.xml.in                  |  199 +-
 plugins/python/glade-python.c             |  158 +-
 po/POTFILES.in                            |    7 +-
 po/POTFILES.skip                          |    2 +-
 po/sv.po                                  | 3127 +++---
 src/glade-close-button.c                  |   66 +-
 src/glade-window.c                        | 5483 +++++----
 src/glade-window.h                        |    1 -
 src/glade.rc.in                           |    2 +-
 src/main.c                                |  255 +-
 129 files changed, 51111 insertions(+), 54020 deletions(-)
---
diff --cc gladeui/glade-app.c
index 5f2a300,b26e158..5e35578
--- a/gladeui/glade-app.c
+++ b/gladeui/glade-app.c
@@@ -59,8 -57,9 +57,8 @@@
  
  enum
  {
- 	UPDATE_UI,
- 	LAST_SIGNAL
+   UPDATE_UI,
 -  SIGNAL_EDITOR_CREATED,
+   LAST_SIGNAL
  };
  
  enum
@@@ -284,39 -277,40 +276,33 @@@ glade_app_refresh_undo_redo_button (Gla
  }
  
  static void
- glade_app_update_ui_default (GladeApp *app)
+ glade_app_update_ui_default (GladeApp * app)
  {
- 	GList *list;
- 	
- 	for (list = app->priv->undo_list; list; list = list->next)
- 		if (list->data)
- 			glade_app_refresh_undo_redo_button (app, list->data, TRUE);
+   GList *list;
  
- 	for (list = app->priv->redo_list; list; list = list->next)
- 		if (list->data)
- 			glade_app_refresh_undo_redo_button (app, list->data, FALSE);
- }
+   for (list = app->priv->undo_list; list; list = list->next)
+     if (list->data)
+       glade_app_refresh_undo_redo_button (app, list->data, TRUE);
  
- static gboolean
- clipboard_view_on_delete_cb (GtkWidget *clipboard_view, GdkEvent *e, GladeApp *app)
- {
- 	glade_util_hide_window (GTK_WINDOW (clipboard_view));
- 	return TRUE;
+   for (list = app->priv->redo_list; list; list = list->next)
+     if (list->data)
+       glade_app_refresh_undo_redo_button (app, list->data, FALSE);
  }
  
 -static void
 -glade_app_signal_editor_created_default (GladeApp * app,
 -                                         GladeSignalEditor * signal_editor)
 -{
 -  glade_signal_editor_construct_signals_list (signal_editor);
 -}
 -
  static GKeyFile *
- glade_app_config_load (GladeApp *app)
+ glade_app_config_load (GladeApp * app)
  {
- 	GKeyFile *config = g_key_file_new ();
- 	gchar *filename;
+   GKeyFile *config = g_key_file_new ();
+   gchar *filename;
  
- 	filename = g_build_filename (g_get_user_config_dir (), GLADE_CONFIG_FILENAME, NULL);
+   filename =
+       g_build_filename (g_get_user_config_dir (), GLADE_CONFIG_FILENAME, NULL);
  
- 	g_key_file_load_from_file (config, filename, G_KEY_FILE_NONE, NULL);
- 	
- 	g_free (filename);
- 	
- 	return config;
+   g_key_file_load_from_file (config, filename, G_KEY_FILE_NONE, NULL);
+ 
+   g_free (filename);
+ 
+   return config;
  }
  
  const gchar *
@@@ -464,53 -455,68 +447,50 @@@ glade_app_init (GladeApp * app
  static void
  glade_app_class_init (GladeAppClass * klass)
  {
 -  GObjectClass *object_class;
 +	GObjectClass *object_class;
 +	
 +	object_class = G_OBJECT_CLASS (klass);
 +	
 +	object_class->constructor  = glade_app_constructor;
 +	object_class->dispose      = glade_app_dispose;
 +	object_class->finalize     = glade_app_finalize;
 +	object_class->get_property = glade_app_get_property;
 +	object_class->set_property = glade_app_set_property;
  
 -  object_class = G_OBJECT_CLASS (klass);
 +	klass->update_ui_signal = glade_app_update_ui_default;
 +	klass->show_properties  = NULL;
 +	klass->hide_properties  = NULL;
  
- 	/**
 -  object_class->constructor = glade_app_constructor;
 -  object_class->dispose = glade_app_dispose;
 -  object_class->finalize = glade_app_finalize;
 -  object_class->get_property = glade_app_get_property;
 -  object_class->set_property = glade_app_set_property;
+ 
 -  klass->update_ui_signal = glade_app_update_ui_default;
 -  klass->signal_editor_created = glade_app_signal_editor_created_default;
 -  klass->show_properties = NULL;
 -  klass->hide_properties = NULL;
+ 
 -        /**
++    /**
  	 * GladeApp::update-ui:
  	 * @gladeapp: the #GladeApp which received the signal.
  	 *
  	 * Emitted when a project name changes or a cut/copy/paste/delete occurred.
  	 */
- 	glade_app_signals[UPDATE_UI] =
- 		g_signal_new ("update-ui",
- 			      G_TYPE_FROM_CLASS (object_class),
- 			      G_SIGNAL_RUN_FIRST,
- 			      G_STRUCT_OFFSET (GladeAppClass,
- 					       update_ui_signal),
- 			      NULL, NULL,
- 			      g_cclosure_marshal_VOID__VOID,
- 			      G_TYPE_NONE, 0);
- 
- 	g_object_class_install_property 
- 		(object_class, PROP_ACTIVE_PROJECT,
- 		 g_param_spec_object 
- 		 ("active-project", _("Active Project"), 
- 		  _("The active project"),
- 		  GLADE_TYPE_PROJECT, G_PARAM_READWRITE));
- 
- 	g_object_class_install_property 
- 		(object_class, PROP_POINTER_MODE,
- 		 g_param_spec_enum 
- 		 ("pointer-mode", _("Pointer Mode"), 
- 		  _("Current mode for the pointer in the workspace"),
- 		  GLADE_TYPE_POINTER_MODE,
- 		  GLADE_POINTER_SELECT,
- 		  G_PARAM_READWRITE));
- 	
- 	g_type_class_add_private (klass, sizeof (GladeAppPrivate));
+   glade_app_signals[UPDATE_UI] =
+       g_signal_new ("update-ui",
+                     G_TYPE_FROM_CLASS (object_class),
+                     G_SIGNAL_RUN_FIRST,
+                     G_STRUCT_OFFSET (GladeAppClass,
+                                      update_ui_signal),
+                     NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
+ 
 -        /**
 -	 * GladeApp::signal-editor-created:
 -	 * @gladeapp: the #GladeApp which received the signal.
 -	 * @signal_editor: the new #GladeSignalEditor.
 -	 *
 -	 * Emitted when a new signal editor created.
 -	 * A tree view is created in the default handler.
 -	 * Connect your handler before the default handler for setting a custom column or renderer
 -	 * and after it for connecting to the tree view signals
 -	 */
 -  glade_app_signals[SIGNAL_EDITOR_CREATED] =
 -      g_signal_new ("signal-editor-created",
 -                    G_TYPE_FROM_CLASS (object_class),
 -                    G_SIGNAL_RUN_LAST,
 -                    G_STRUCT_OFFSET (GladeAppClass,
 -                                     signal_editor_created),
 -                    NULL, NULL,
 -                    glade_marshal_VOID__OBJECT, G_TYPE_NONE, 1, G_TYPE_OBJECT);
 -
+   g_object_class_install_property
+       (object_class, PROP_ACTIVE_PROJECT,
+        g_param_spec_object
+        ("active-project", _("Active Project"),
+         _("The active project"), GLADE_TYPE_PROJECT, G_PARAM_READWRITE));
+ 
+   g_object_class_install_property
+       (object_class, PROP_POINTER_MODE,
+        g_param_spec_enum
+        ("pointer-mode", _("Pointer Mode"),
+         _("Current mode for the pointer in the workspace"),
+         GLADE_TYPE_POINTER_MODE, GLADE_POINTER_SELECT, G_PARAM_READWRITE));
+ 
+   g_type_class_add_private (klass, sizeof (GladeAppPrivate));
  }
  
  /*****************************************************************
diff --cc gladeui/glade-editor.c
index 35fe785,0068eca..8bcd6c8
--- a/gladeui/glade-editor.c
+++ b/gladeui/glade-editor.c
@@@ -595,13 -594,14 +594,22 @@@ glade_editor_set_signal_editor (GladeEd
  }
  
  static void
- glade_editor_load_signal_page (GladeEditor *editor)
+ glade_editor_load_signal_page (GladeEditor * editor)
  {
++<<<<<<< HEAD
 +	if (editor->signal_editor == NULL) {
 +		editor->signal_editor = glade_signal_editor_new ();
 +		gtk_container_add (GTK_CONTAINER (editor->page_signals),
 +				   GTK_WIDGET(editor->signal_editor));
 +	}
++=======
+   if (editor->signal_editor == NULL)
+     {
+       editor->signal_editor = glade_signal_editor_new ((gpointer) editor);
+       gtk_container_add (GTK_CONTAINER (editor->page_signals),
+                          GTK_WIDGET (editor->signal_editor));
+     }
++>>>>>>> master
  }
  
  static void
diff --cc gladeui/glade-project.c
index 9b85496,d26dd9f..ce125ef
--- a/gladeui/glade-project.c
+++ b/gladeui/glade-project.c
@@@ -3832,42 -3565,43 +3565,42 @@@ glade_project_undo_items (GladeProject 
   * Returns: A newly created menu
   */
  GtkWidget *
- glade_project_redo_items (GladeProject *project)
+ glade_project_redo_items (GladeProject * project)
  {
- 	GtkWidget *menu = NULL;
- 	GtkWidget *item;
- 	GladeCommand *cmd;
- 	GList   *l;
+   GtkWidget *menu = NULL;
+   GtkWidget *item;
+   GladeCommand *cmd;
+   GList *l;
+ 
+   g_return_val_if_fail (project != NULL, NULL);
  
- 	g_return_val_if_fail (project != NULL, NULL);
+   for (l = project->priv->prev_redo_item ?
+        project->priv->prev_redo_item->next :
+        project->priv->undo_stack; l; l = walk_command (l, TRUE))
+     {
+       cmd = l->data;
  
- 	for (l = project->priv->prev_redo_item ?
- 		     project->priv->prev_redo_item->next :
- 		     project->priv->undo_stack;
- 	     l; l = walk_command (l, TRUE))
- 	{
- 		cmd = l->data;
+       if (!menu)
+         menu = gtk_menu_new ();
  
- 		if (!menu) menu = gtk_menu_new ();
- 		
- 		item = gtk_menu_item_new_with_label (cmd->description);
- 		gtk_widget_show (item);
- 		gtk_menu_shell_append (GTK_MENU_SHELL (menu), GTK_WIDGET (item));
- 		g_object_set_data (G_OBJECT (item), "command-data", cmd);
+       item = gtk_menu_item_new_with_label (cmd->description);
+       gtk_widget_show (item);
+       gtk_menu_shell_append (GTK_MENU_SHELL (menu), GTK_WIDGET (item));
+       g_object_set_data (G_OBJECT (item), "command-data", cmd);
  
- 		g_signal_connect (G_OBJECT (item), "activate",
- 				  G_CALLBACK (redo_item_activated), project);
+       g_signal_connect (G_OBJECT (item), "activate",
+                         G_CALLBACK (redo_item_activated), project);
  
- 	}
- 	
- 	return menu;
+     }
+ 
+   return menu;
  }
  
 -
  void
- glade_project_reset_path (GladeProject *project)
+ glade_project_reset_path (GladeProject * project)
  {
- 	g_return_if_fail (GLADE_IS_PROJECT (project));
- 	project->priv->path = (g_free (project->priv->path), NULL);
+   g_return_if_fail (GLADE_IS_PROJECT (project));
+   project->priv->path = (g_free (project->priv->path), NULL);
  }
  
  /**
diff --cc gladeui/glade-signal-editor.c
index 1420d50,fca6c68..ed3d3e4
--- a/gladeui/glade-signal-editor.c
+++ b/gladeui/glade-signal-editor.c
@@@ -568,14 -1521,137 +568,15 @@@ glade_signal_editor_init (GladeSignalEd
  }
  
  static void
 -glade_signal_editor_handler_store_update (GladeSignalEditor * editor,
 -                                          const gchar * signal_name,
 -                                          GtkListStore * store)
 +glade_signal_editor_class_init (GladeSignalEditorClass *klass)
  {
 -  GladeSignalEditorPrivate *priv = editor->priv;
 -
 -  const gchar *handlers[] = { "gtk_widget_show",
 -    "gtk_widget_hide",
 -    "gtk_widget_grab_focus",
 -    "gtk_widget_destroy",
 -    "gtk_true",
 -    "gtk_false",
 -    "gtk_main_quit",
 -    NULL
 -  };
 -
 -  GtkTreeIter tmp_iter;
 -  gint i;
 -  gchar *handler, *signal, *name;
 -
 -  name = (gchar *) glade_widget_get_name (priv->widget);
 -
 -  signal = g_strdup (signal_name);
 -  glade_util_replace (signal, '-', '_');
 -
 -  gtk_list_store_clear (store);
 -
 -  gtk_list_store_append (store, &tmp_iter);
 -  handler = g_strdup_printf ("on_%s_%s", name, signal);
 -  gtk_list_store_set (store, &tmp_iter, 0, handler, -1);
 -  g_free (handler);
 -
 -  gtk_list_store_append (store, &tmp_iter);
 -  handler = g_strdup_printf ("%s_%s_cb", name, signal);
 -  gtk_list_store_set (store, &tmp_iter, 0, handler, -1);
 -  g_free (handler);
 -
 -  g_free (signal);
 -  for (i = 0; handlers[i]; i++)
 -    {
 -      gtk_list_store_append (store, &tmp_iter);
 -      gtk_list_store_set (store, &tmp_iter, 0, handlers[i], -1);
 -    }
 -}
 -
 -static gboolean
 -glade_signal_editor_handler_editing_started_default (GladeSignalEditor * editor,
 -                                                     gchar * signal_name,
 -                                                     GtkTreeIter * iter,
 -                                                     GtkCellEditable * editable)
 -{
 -  GladeSignalEditorPrivate *priv = editor->priv;
 -  GtkEntry *entry;
 -  GtkEntryCompletion *completion;
 -  GtkTreeModel *completion_store = priv->handler_store;
 -
 -  g_return_val_if_fail (GTK_IS_BIN (editable), FALSE);
 -  g_return_val_if_fail (GTK_IS_LIST_STORE (completion_store), FALSE);
 -
 -  entry = GTK_ENTRY (gtk_bin_get_child (GTK_BIN (editable)));
 -
 -  glade_signal_editor_editing_started (entry, priv->is_void_handler);
 +	GObjectClass *object_class;
  
 -  glade_signal_editor_handler_store_update (editor, signal_name,
 -                                            GTK_LIST_STORE (completion_store));
 +	glade_signal_editor_parent_class = g_type_class_peek_parent (klass);
  
 -  completion = gtk_entry_completion_new ();
 -  gtk_entry_completion_set_text_column (completion, 0);
 -  gtk_entry_completion_set_inline_completion (completion, TRUE);
 -  gtk_entry_completion_set_popup_completion (completion, FALSE);
 -  gtk_entry_completion_set_model (completion, completion_store);
 -  gtk_entry_set_completion (entry, completion);
 +	object_class = G_OBJECT_CLASS (klass);
 +	object_class->dispose = glade_signal_editor_dispose;
  
 -  return FALSE;
 +	g_type_class_add_private (klass, sizeof (GladeSignalEditorPrivate));
  }
+ 
 -static void
 -glade_signal_editor_userdata_store_update (GladeSignalEditor * self,
 -                                           GtkListStore * store)
 -{
 -  GtkTreeIter tmp_iter;
 -  GList *list;
 -
 -  GladeSignalEditorPrivate *priv = self->priv;
 -
 -  gtk_list_store_clear (store);
 -
 -  for (list = (GList *) glade_project_get_objects (priv->widget->project);
 -       list && list->data; list = g_list_next (list))
 -    {
 -      GladeWidget *widget = glade_widget_get_from_gobject (list->data);
 -
 -      if (widget)
 -        {
 -          gtk_list_store_append (store, &tmp_iter);
 -          gtk_list_store_set (store, &tmp_iter, 0, widget->name, -1);
 -        }
 -    }
 -
 -  gtk_tree_sortable_set_sort_column_id (GTK_TREE_SORTABLE (store), 0,
 -                                        GTK_SORT_DESCENDING);
 -}
 -
 -static gboolean
 -glade_signal_editor_userdata_editing_started_default (GladeSignalEditor *
 -                                                      editor,
 -                                                      gchar * signal_name,
 -                                                      GtkTreeIter * iter,
 -                                                      GtkCellEditable *
 -                                                      editable)
 -{
 -  GtkEntry *entry;
 -  GtkEntryCompletion *completion;
 -  GladeSignalEditorPrivate *priv = editor->priv;
 -  GtkTreeModel *completion_store = priv->userdata_store;
 -
 -  g_return_val_if_fail (priv->widget != NULL, FALSE);
 -  g_return_val_if_fail (GTK_IS_LIST_STORE (completion_store), FALSE);
 -  g_return_val_if_fail (GTK_IS_ENTRY (editable), FALSE);
 -
 -  entry = GTK_ENTRY (editable);
 -
 -  glade_signal_editor_editing_started (entry, priv->is_void_handler);
 -
 -  glade_signal_editor_userdata_store_update (editor,
 -                                             GTK_LIST_STORE (completion_store));
 -
 -  completion = gtk_entry_completion_new ();
 -  gtk_entry_completion_set_text_column (completion, 0);
 -  gtk_entry_completion_set_model (completion, completion_store);
 -  gtk_entry_set_completion (entry, completion);
 -
 -  return FALSE;
 -}
diff --cc gladeui/glade-signal.c
index 9588c12,ea0009f..ec90f92
--- a/gladeui/glade-signal.c
+++ b/gladeui/glade-signal.c
@@@ -85,25 -83,24 +83,24 @@@ glade_signal_free (GladeSignal * signal
   * Returns: %TRUE if @sig1 and @sig2 have identical attributes, %FALSE otherwise
   */
  gboolean
 -glade_signal_equal (GladeSignal * sig1, GladeSignal * sig2)
 +glade_signal_equal (const GladeSignal *sig1, const GladeSignal *sig2)
  {
- 	gboolean ret = FALSE;
- 	g_return_val_if_fail (GLADE_IS_SIGNAL (sig1), FALSE);
- 	g_return_val_if_fail (GLADE_IS_SIGNAL (sig2), FALSE);
- 
- 	/* Intentionally ignore support_warning */
- 	if (!strcmp (sig1->name, sig2->name)        &&
- 	    !strcmp (sig1->handler, sig2->handler)  &&
- 	    sig1->after   == sig2->after            &&
- 	    sig1->swapped == sig2->swapped)
- 	{
- 		if ((sig1->userdata == NULL && sig2->userdata == NULL) ||
- 		    (sig1->userdata != NULL && sig2->userdata != NULL  &&
- 		     !strcmp (sig1->userdata, sig2->userdata)))
- 			ret = TRUE;
- 	}
- 
- 	return ret;
+   gboolean ret = FALSE;
+   g_return_val_if_fail (GLADE_IS_SIGNAL (sig1), FALSE);
+   g_return_val_if_fail (GLADE_IS_SIGNAL (sig2), FALSE);
+ 
+   /* Intentionally ignore support_warning */
+   if (!strcmp (sig1->name, sig2->name) &&
+       !strcmp (sig1->handler, sig2->handler) &&
+       sig1->after == sig2->after && sig1->swapped == sig2->swapped)
+     {
+       if ((sig1->userdata == NULL && sig2->userdata == NULL) ||
+           (sig1->userdata != NULL && sig2->userdata != NULL &&
+            !strcmp (sig1->userdata, sig2->userdata)))
+         ret = TRUE;
+     }
+ 
+   return ret;
  }
  
  /**
diff --cc gladeui/glade-widget.c
index f496a47,92df27c..c65e14e
--- a/gladeui/glade-widget.c
+++ b/gladeui/glade-widget.c
@@@ -56,16 -55,15 +55,15 @@@
  #include "glade-app.h"
  #include "glade-design-view.h"
  #include "glade-widget-action.h"
 -
 +#include "glade-signal-model.h"
  
  
- static void         glade_widget_set_adaptor           (GladeWidget           *widget,
- 							GladeWidgetAdaptor    *adaptor);
- static void         glade_widget_set_properties        (GladeWidget           *widget,
- 							GList                 *properties);
- static void         glade_widget_set_object            (GladeWidget           *gwidget, 
- 							GObject               *new_object, 
- 							gboolean               destroy);
+ static void glade_widget_set_adaptor (GladeWidget * widget,
+                                       GladeWidgetAdaptor * adaptor);
+ static void glade_widget_set_properties (GladeWidget * widget,
+                                          GList * properties);
+ static void glade_widget_set_object (GladeWidget * gwidget,
+                                      GObject * new_object, gboolean destroy);
  
  enum
  {
@@@ -172,230 -173,192 +173,225 @@@ glade_widget_remove_child_impl (GladeWi
  }
  
  static void
- glade_widget_replace_child_impl (GladeWidget *widget,
- 				 GObject     *old_object,
- 				 GObject     *new_object)
+ glade_widget_replace_child_impl (GladeWidget * widget,
+                                  GObject * old_object, GObject * new_object)
  {
- 	GladeWidget *gnew_widget = glade_widget_get_from_gobject (new_object);
- 	GladeWidget *gold_widget = glade_widget_get_from_gobject (old_object);
+   GladeWidget *gnew_widget = glade_widget_get_from_gobject (new_object);
+   GladeWidget *gold_widget = glade_widget_get_from_gobject (old_object);
  
- 	if (gnew_widget)
- 	{
- 		g_object_ref (gnew_widget);
+   if (gnew_widget)
+     {
+       g_object_ref (gnew_widget);
  
- 		gnew_widget->parent = widget;
+       gnew_widget->parent = widget;
  
- 		/* Set packing actions first so we have access from the plugin
- 		 */
- 		glade_widget_set_packing_actions (gnew_widget, widget);
- 	}
+       /* Set packing actions first so we have access from the plugin
+        */
+       glade_widget_set_packing_actions (gnew_widget, widget);
+     }
  
- 	if (gold_widget)
- 	{ 
- 		g_object_unref (gold_widget);
+   if (gold_widget)
+     {
+       g_object_unref (gold_widget);
  
- 		if (gold_widget != gnew_widget)
- 			gold_widget->parent = NULL;
- 	}
+       if (gold_widget != gnew_widget)
+         gold_widget->parent = NULL;
+     }
  
- 	glade_widget_adaptor_replace_child 
- 		(widget->adaptor, widget->object,
- 		 old_object, new_object);
+   glade_widget_adaptor_replace_child
+       (widget->adaptor, widget->object, old_object, new_object);
  
- 	/* Setup packing properties here so we can introspect the new
- 	 * values from the backend.
- 	 */
- 	if (gnew_widget)
- 		glade_widget_set_packing_properties (gnew_widget, widget);
+   /* Setup packing properties here so we can introspect the new
+    * values from the backend.
+    */
+   if (gnew_widget)
+     glade_widget_set_packing_properties (gnew_widget, widget);
  }
  
 -static void
 -glade_widget_add_signal_handler_impl (GladeWidget * widget,
 -                                      GladeSignal * signal_handler)
 +/**
 + * glade_widget_add_signal_handler:
 + * @widget: A #GladeWidget
 + * @signal_handler: The #GladeSignal
 + *
 + * Adds a signal handler for @widget 
 + */
 +void
 +glade_widget_add_signal_handler (GladeWidget *widget, const GladeSignal *signal_handler)
  {
- 	GPtrArray *signals;
- 	GladeSignal *new_signal_handler;
+   GPtrArray *signals;
+   GladeSignal *new_signal_handler;
  
- 	g_return_if_fail (GLADE_IS_WIDGET (widget));
- 	g_return_if_fail (GLADE_IS_SIGNAL (signal_handler));
+   g_return_if_fail (GLADE_IS_WIDGET (widget));
+   g_return_if_fail (GLADE_IS_SIGNAL (signal_handler));
  
- 	signals = glade_widget_list_signal_handlers (widget, signal_handler->name);
- 	if (!signals)
- 	{
- 		signals = g_ptr_array_new ();
- 		g_hash_table_insert (widget->signals, g_strdup (signal_handler->name), signals);
- 	}
+   signals = glade_widget_list_signal_handlers (widget, signal_handler->name);
+   if (!signals)
+     {
+       signals = g_ptr_array_new ();
+       g_hash_table_insert (widget->signals, g_strdup (signal_handler->name),
+                            signals);
+     }
  
- 	new_signal_handler = glade_signal_clone (signal_handler);
- 	g_ptr_array_add (signals, new_signal_handler);
- 	g_signal_emit (widget, glade_widget_signals[ADD_SIGNAL_HANDLER], 0, new_signal_handler);
+   new_signal_handler = glade_signal_clone (signal_handler);
+   g_ptr_array_add (signals, new_signal_handler);
++  g_signal_emit (widget, glade_widget_signals[ADD_SIGNAL_HANDLER], 0, new_signal_handler);
  
- 	glade_project_update_signal_support_warning (widget, new_signal_handler);
+   glade_project_update_signal_support_warning (widget, new_signal_handler);
  }
  
 +/**
 + * glade_widget_remove_signal_handler:
 + * @widget: A #GladeWidget
 + * @signal_handler: The #GladeSignal
 + *
 + * Removes a signal handler from @widget 
 + */
 +
- void
- glade_widget_remove_signal_handler(GladeWidget *widget, const GladeSignal *signal_handler)
+ static void
 -glade_widget_remove_signal_handler_impl (GladeWidget * widget,
 -                                         GladeSignal * signal_handler)
++glade_widget_remove_signal_handler (GladeWidget * widget,
++                                    GladeSignal * signal_handler)
  {
- 	GPtrArray   *signals;
- 	GladeSignal *tmp_signal_handler;
- 	guint        i;
+   GPtrArray *signals;
+   GladeSignal *tmp_signal_handler;
+   guint i;
  
- 	g_return_if_fail (GLADE_IS_WIDGET (widget));
- 	g_return_if_fail (GLADE_IS_SIGNAL (signal_handler));
+   g_return_if_fail (GLADE_IS_WIDGET (widget));
+   g_return_if_fail (GLADE_IS_SIGNAL (signal_handler));
  
- 	signals = glade_widget_list_signal_handlers (widget, signal_handler->name);
+   signals = glade_widget_list_signal_handlers (widget, signal_handler->name);
  
- 	/* trying to remove an inexistent signal? */
- 	g_assert (signals);
+   /* trying to remove an inexistent signal? */
+   g_assert (signals);
  
 -  for (i = 0; i < signals->len; i++)
 -    {
 -      tmp_signal_handler = g_ptr_array_index (signals, i);
 -      if (glade_signal_equal (tmp_signal_handler, signal_handler))
 -        {
 -          glade_signal_free (tmp_signal_handler);
 -          g_ptr_array_remove_index (signals, i);
 -          break;
 -        }
 -    }
 +	for (i = 0; i < signals->len; i++)
 +	{
 +		tmp_signal_handler = g_ptr_array_index (signals, i);
 +		if (glade_signal_equal (tmp_signal_handler, signal_handler))
 +		{
 +			g_signal_emit (widget, glade_widget_signals[REMOVE_SIGNAL_HANDLER], 0, tmp_signal_handler);
 +			g_ptr_array_remove_index (signals, i);
 +			if (signals->len == 0)
 +			{
 +				g_hash_table_remove (widget->signals, tmp_signal_handler->name);
 +			}
 +			else
 +			{
 +				glade_signal_free (tmp_signal_handler);
 +			}
 +			break;
 +		}
 +	}
  }
  
 -static void
 -glade_widget_change_signal_handler_impl (GladeWidget * widget,
 -                                         GladeSignal * old_signal_handler,
 -                                         GladeSignal * new_signal_handler)
 -{
 -  GPtrArray *signals;
 -  GladeSignal *signal_handler_iter;
 -  guint i;
 -
 -  g_return_if_fail (GLADE_IS_WIDGET (widget));
 -  g_return_if_fail (GLADE_IS_SIGNAL (old_signal_handler));
 -  g_return_if_fail (GLADE_IS_SIGNAL (new_signal_handler));
 -  g_return_if_fail (strcmp (old_signal_handler->name, new_signal_handler->name)
 -                    == 0);
 -
 -  signals =
 -      glade_widget_list_signal_handlers (widget, old_signal_handler->name);
 -
 -  /* trying to remove an inexistent signal? */
 -  g_assert (signals);
 -
 -  for (i = 0; i < signals->len; i++)
 -    {
 -      signal_handler_iter = g_ptr_array_index (signals, i);
 -      if (glade_signal_equal (signal_handler_iter, old_signal_handler))
 -        {
 -          if (strcmp (old_signal_handler->handler,
 -                      new_signal_handler->handler) != 0)
 -            {
 -              g_free (signal_handler_iter->handler);
 -              signal_handler_iter->handler =
 -                  g_strdup (new_signal_handler->handler);
 -            }
 -
 -          /* Handler */
 -          if (signal_handler_iter->handler)
 -            g_free (signal_handler_iter->handler);
 -          signal_handler_iter->handler = g_strdup (new_signal_handler->handler);
 -
 -          /* Object */
 -          if (signal_handler_iter->userdata)
 -            g_free (signal_handler_iter->userdata);
 -          signal_handler_iter->userdata =
 -              g_strdup (new_signal_handler->userdata);
 -
 -          signal_handler_iter->after = new_signal_handler->after;
 -          signal_handler_iter->swapped = new_signal_handler->swapped;
 -          break;
 -        }
 -    }
 +/**
 + * glade_widget_change_signal_handler:
 + * @widget: A #GladeWidget
 + * @old_signal_handler: the old #GladeSignal
 + * @new_signal_handler: the new #GladeSignal
 + *
 + * Changes a #GladeSignal on @widget 
 + */
 +void
 +glade_widget_change_signal_handler (GladeWidget *widget,
 +				    const GladeSignal *old_signal_handler,
 +				    const GladeSignal *new_signal_handler)
 +{
 +	GPtrArray   *signals;
 +	GladeSignal *signal_handler_iter;
 +	guint        i;
 +	
 +	g_return_if_fail (GLADE_IS_WIDGET (widget));
 +	g_return_if_fail (GLADE_IS_SIGNAL (old_signal_handler));
 +	g_return_if_fail (GLADE_IS_SIGNAL (new_signal_handler));
 +	g_return_if_fail (strcmp (old_signal_handler->name, new_signal_handler->name) == 0);
 +
 +	signals = glade_widget_list_signal_handlers (widget, old_signal_handler->name);
 +
 +	/* trying to remove an inexistent signal? */
 +	g_assert (signals);
 +
 +	for (i = 0; i < signals->len; i++)
 +	{
 +		signal_handler_iter = g_ptr_array_index (signals, i);
 +		if (glade_signal_equal (signal_handler_iter, old_signal_handler))
 +		{
 +			if (strcmp (old_signal_handler->handler,
 +				    new_signal_handler->handler) != 0)
 +			{
 +				g_free (signal_handler_iter->handler);
 +				signal_handler_iter->handler =
 +					g_strdup (new_signal_handler->handler);
 +			}
 +
 +			/* Handler */
 +			if (signal_handler_iter->handler)
 +				g_free (signal_handler_iter->handler);
 +			signal_handler_iter->handler =
 +				g_strdup (new_signal_handler->handler);
 +			
 +			/* Object */
 +			if (signal_handler_iter->userdata)
 +				g_free (signal_handler_iter->userdata);
 +			signal_handler_iter->userdata = 
 +				g_strdup (new_signal_handler->userdata);
 +			
 +			signal_handler_iter->after    = new_signal_handler->after;
 +			signal_handler_iter->swapped  = new_signal_handler->swapped;
 +
 +			g_signal_emit (widget, glade_widget_signals[CHANGE_SIGNAL_HANDLER], 0,
 +			               old_signal_handler, signal_handler_iter);
 +
 +			break;
 +		}
 +	}
  }
  
--
  static gboolean
- glade_widget_button_press_event_impl (GladeWidget    *gwidget,
- 				      GdkEvent       *base_event)
+ glade_widget_button_press_event_impl (GladeWidget * gwidget,
+                                       GdkEvent * base_event)
  {
- 	GtkWidget         *widget;
- 	GdkEventButton    *event = (GdkEventButton *)base_event;
- 	gboolean           handled = FALSE;
+   GtkWidget *widget;
+   GdkEventButton *event = (GdkEventButton *) base_event;
+   gboolean handled = FALSE;
  
- 	/* make sure to grab focus, since we may stop default handlers */
- 	widget = GTK_WIDGET (glade_widget_get_object (gwidget));
- 	if (gtk_widget_get_can_focus (widget) && !gtk_widget_has_focus (widget))
- 		gtk_widget_grab_focus (widget);
+   /* make sure to grab focus, since we may stop default handlers */
+   widget = GTK_WIDGET (glade_widget_get_object (gwidget));
+   if (gtk_widget_get_can_focus (widget) && !gtk_widget_has_focus (widget))
+     gtk_widget_grab_focus (widget);
  
- 	/* if it's already selected don't stop default handlers, e.g. toggle button */
- 	if (event->button == 1)
- 	{
- 		if (event->state & GDK_CONTROL_MASK)
- 		{
- 			if (glade_project_is_selected (gwidget->project,
- 						       gwidget->object))
- 				glade_app_selection_remove 
- 					(gwidget->object, TRUE);
- 			else
- 				glade_app_selection_add
- 					(gwidget->object, TRUE);
- 			handled = TRUE;
- 		}
- 		else if (glade_project_is_selected (gwidget->project,
- 						    gwidget->object) == FALSE)
- 		{
- 			glade_util_clear_selection ();
- 			glade_app_selection_set 
- 				(gwidget->object, TRUE);
- 
- 			/* Add selection without interrupting event flow 
- 			 * when shift is down, this allows better behaviour
- 			 * for GladeFixed children 
- 			 */
- 			handled = !(event->state & GDK_SHIFT_MASK);
- 		}
- 	}
+   /* if it's already selected don't stop default handlers, e.g. toggle button */
+   if (event->button == 1)
+     {
+       if (event->state & GDK_CONTROL_MASK)
+         {
+           if (glade_project_is_selected (gwidget->project, gwidget->object))
+             glade_app_selection_remove (gwidget->object, TRUE);
+           else
+             glade_app_selection_add (gwidget->object, TRUE);
+           handled = TRUE;
+         }
+       else if (glade_project_is_selected (gwidget->project,
+                                           gwidget->object) == FALSE)
+         {
+           glade_util_clear_selection ();
+           glade_app_selection_set (gwidget->object, TRUE);
+ 
+           /* Add selection without interrupting event flow 
+            * when shift is down, this allows better behaviour
+            * for GladeFixed children 
+            */
+           handled = !(event->state & GDK_SHIFT_MASK);
+         }
+     }
  
- 	/* Give some kind of access in case of missing right button */
- 	if (!handled && glade_popup_is_popup_event (event))
-        	{
- 			glade_popup_widget_pop (gwidget, event, TRUE);
- 			handled = TRUE;
- 	}
+   /* Give some kind of access in case of missing right button */
+   if (!handled && glade_popup_is_popup_event (event))
+     {
+       glade_popup_widget_pop (gwidget, event, TRUE);
+       handled = TRUE;
+     }
  
- 	return handled;
+   return handled;
  }
  
  static gboolean
@@@ -881,63 -839,58 +872,64 @@@ reset_object_property (GladeProperty * 
  }
  
  static void
- glade_widget_dispose (GObject *object)
+ glade_widget_dispose (GObject * object)
  {
- 	GladeWidget *widget = GLADE_WIDGET (object);
+   GladeWidget *widget = GLADE_WIDGET (object);
  
- 	glade_widget_push_superuser ();
+   glade_widget_push_superuser ();
  
- 	/* Release references by way of object properties... */
- 	while (widget->prop_refs)
- 	{
- 		GladeProperty *property = GLADE_PROPERTY (widget->prop_refs->data);
- 		glade_property_set (property, NULL);
- 	}
+   /* Release references by way of object properties... */
+   while (widget->prop_refs)
+     {
+       GladeProperty *property = GLADE_PROPERTY (widget->prop_refs->data);
+       glade_property_set (property, NULL);
+     }
  
- 	if (widget->properties)
- 		g_list_foreach (widget->properties, (GFunc)reset_object_property, widget->project);
+   if (widget->properties)
+     g_list_foreach (widget->properties, (GFunc) reset_object_property,
+                     widget->project);
  
- 	/* We have to make sure properties release thier references on other widgets first 
- 	 * hence the reset (for object properties) */
- 	if (widget->properties)
- 	{
- 		g_list_foreach (widget->properties, (GFunc)g_object_unref, NULL);
- 		g_list_free (widget->properties);
- 		widget->properties = NULL;
- 	}
+   /* We have to make sure properties release thier references on other widgets first 
+    * hence the reset (for object properties) */
+   if (widget->properties)
+     {
+       g_list_foreach (widget->properties, (GFunc) g_object_unref, NULL);
+       g_list_free (widget->properties);
+       widget->properties = NULL;
+     }
  
- 	glade_widget_set_object (widget, NULL, TRUE);
- 	
- 	if (widget->packing_properties)
- 	{
- 		g_list_foreach (widget->packing_properties, (GFunc)g_object_unref, NULL);
- 		g_list_free (widget->packing_properties);
- 		widget->packing_properties = NULL;
- 	}
- 	
- 	if (widget->actions)
- 	{
- 		g_list_foreach (widget->actions, (GFunc)g_object_unref, NULL);
- 		g_list_free (widget->actions);
- 		widget->actions = NULL;
- 	}
- 	
- 	if (widget->packing_actions)
- 	{
- 		g_list_foreach (widget->packing_actions, (GFunc)g_object_unref, NULL);
- 		g_list_free (widget->packing_actions);
- 		widget->packing_actions = NULL;
- 	}
- 	
- 	if (widget->signal_model)
- 	{
- 		g_object_unref (widget->signal_model);
- 		widget->signal_model = NULL;
- 	}
- 	
- 	glade_widget_pop_superuser ();
+   glade_widget_set_object (widget, NULL, TRUE);
+ 
+   if (widget->packing_properties)
+     {
+       g_list_foreach (widget->packing_properties, (GFunc) g_object_unref, NULL);
+       g_list_free (widget->packing_properties);
+       widget->packing_properties = NULL;
+     }
  
- 	G_OBJECT_CLASS (glade_widget_parent_class)->dispose (object);
+   if (widget->actions)
+     {
+       g_list_foreach (widget->actions, (GFunc) g_object_unref, NULL);
+       g_list_free (widget->actions);
+       widget->actions = NULL;
+     }
+ 
+   if (widget->packing_actions)
+     {
+       g_list_foreach (widget->packing_actions, (GFunc) g_object_unref, NULL);
+       g_list_free (widget->packing_actions);
+       widget->packing_actions = NULL;
+     }
+ 
++  if (widget->signal_model)
++    {
++      g_object_unref (widget->signal_model);
++      widget->signal_model = NULL;
++    }
++
+   glade_widget_pop_superuser ();
+ 
+   G_OBJECT_CLASS (glade_widget_parent_class)->dispose (object);
  }
  
  static void
@@@ -1095,165 -1048,153 +1087,153 @@@ glade_widget_init (GladeWidget * widget
  }
  
  static void
- glade_widget_class_init (GladeWidgetClass *klass)
- {
- 	GObjectClass *object_class;
- 
- 	if (glade_widget_name_quark == 0)
- 		glade_widget_name_quark = 
- 			g_quark_from_static_string ("GladeWidgetDataTag");
- 
- 	object_class = G_OBJECT_CLASS (klass);
- 
- 	object_class->constructor     = glade_widget_constructor;
- 	object_class->finalize        = glade_widget_finalize;
- 	object_class->dispose         = glade_widget_dispose;
- 	object_class->set_property    = glade_widget_set_real_property;
- 	object_class->get_property    = glade_widget_get_real_property;
- 
- 	klass->add_child              = glade_widget_add_child_impl;
- 	klass->remove_child           = glade_widget_remove_child_impl;
- 	klass->replace_child          = glade_widget_replace_child_impl;
- 	klass->event                  = glade_widget_event_impl;
- 
- 	klass->button_press_event     = glade_widget_button_press_event_impl;
- 	klass->button_release_event   = NULL;
- 	klass->motion_notify_event    = NULL;
- 
- 	g_object_class_install_property
- 		(object_class, PROP_NAME,
- 		 g_param_spec_string ("name", _("Name"),
- 				      _("The name of the widget"),
- 				      NULL,
- 				      G_PARAM_READWRITE |
- 				      G_PARAM_CONSTRUCT));
- 
- 	g_object_class_install_property
- 		(object_class, PROP_INTERNAL,
- 		 g_param_spec_string ("internal", _("Internal name"),
- 				      _("The internal name of the widget"),
- 				      NULL, G_PARAM_READWRITE |
- 				      G_PARAM_CONSTRUCT));
- 	
- 	g_object_class_install_property
- 		(object_class, PROP_ANARCHIST,
- 		 g_param_spec_boolean ("anarchist", _("Anarchist"),
- 				       _("Whether this composite child is "
- 					 "an ancestral child or an anarchist child"),
- 				       FALSE, G_PARAM_READWRITE |
- 				       G_PARAM_CONSTRUCT_ONLY));
- 
- 	g_object_class_install_property
- 		(object_class, PROP_OBJECT,
- 		 g_param_spec_object ("object", _("Object"),
- 				      _("The object associated"),
- 				      G_TYPE_OBJECT,
- 				      G_PARAM_READWRITE |
- 				      G_PARAM_CONSTRUCT));
- 
- 	g_object_class_install_property
- 		(object_class, PROP_ADAPTOR,
- 		   g_param_spec_object ("adaptor", _("Adaptor"),
- 					_("The class adaptor for the associated widget"),
- 					GLADE_TYPE_WIDGET_ADAPTOR,
- 					G_PARAM_READWRITE |
- 					G_PARAM_CONSTRUCT_ONLY));
- 
- 	g_object_class_install_property
- 		(object_class, PROP_PROJECT,
- 		 g_param_spec_object ("project", _("Project"),
- 				      _("The glade project that "
- 					"this widget belongs to"),
- 				      GLADE_TYPE_PROJECT,
- 				      G_PARAM_READWRITE |
- 				      G_PARAM_CONSTRUCT));
- 
- 	g_object_class_install_property
- 		(object_class, PROP_PROPERTIES,
- 		 g_param_spec_pointer ("properties", _("Properties"),
- 				       _("A list of GladeProperties"),
- 				       G_PARAM_READWRITE |
- 				       G_PARAM_CONSTRUCT_ONLY));
- 
- 	g_object_class_install_property
- 		(object_class, 	PROP_PARENT,
- 		 g_param_spec_object ("parent", _("Parent"),
- 				      _("A pointer to the parenting GladeWidget"),
- 				      GLADE_TYPE_WIDGET,
- 				      G_PARAM_READWRITE |
- 				      G_PARAM_CONSTRUCT));
- 
- 	g_object_class_install_property
- 		(object_class, 	PROP_INTERNAL_NAME,
- 		 g_param_spec_string ("internal-name", _("Internal Name"),
- 				      _("A generic name prefix for internal widgets"),
- 				      NULL, G_PARAM_CONSTRUCT_ONLY|G_PARAM_WRITABLE));
- 
- 	g_object_class_install_property
- 		(object_class, 	PROP_TEMPLATE,
- 		 g_param_spec_object ("template", _("Template"),
- 				       _("A GladeWidget template to base a new widget on"),
- 				      GLADE_TYPE_WIDGET,
- 				      G_PARAM_CONSTRUCT_ONLY|G_PARAM_WRITABLE));
- 
- 	g_object_class_install_property
- 		(object_class, PROP_TEMPLATE_EXACT,
- 		 g_param_spec_boolean ("template-exact", _("Exact Template"),
- 				       _("Whether we are creating an exact duplicate when using a template"),
- 				       FALSE, G_PARAM_WRITABLE|G_PARAM_CONSTRUCT_ONLY));
- 
- 	g_object_class_install_property
- 		(object_class, 	PROP_REASON,
- 		 g_param_spec_int ("reason", _("Reason"),
- 				   _("A GladeCreateReason for this creation"),
- 				   GLADE_CREATE_USER,
- 				   GLADE_CREATE_REASONS - 1,
- 				   GLADE_CREATE_USER,
- 				   G_PARAM_CONSTRUCT_ONLY|G_PARAM_WRITABLE));
- 
- 	g_object_class_install_property
- 		(object_class, 	PROP_TOPLEVEL_WIDTH,
- 		 g_param_spec_int ("toplevel-width", _("Toplevel Width"),
- 				   _("The width of the widget when toplevel in "
- 				     "the GladeDesignLayout"),
- 				   -1,
- 				   G_MAXINT,
- 				   -1,
- 				   G_PARAM_READWRITE));
- 
- 	g_object_class_install_property
- 		(object_class, 	PROP_TOPLEVEL_HEIGHT,
- 		 g_param_spec_int ("toplevel-height", _("Toplevel Height"),
- 				   _("The height of the widget when toplevel in "
- 				     "the GladeDesignLayout"),
- 				   -1,
- 				   G_MAXINT,
- 				   -1,
- 				   G_PARAM_READWRITE));
- 
- 	g_object_class_install_property
- 		(object_class, 	PROP_SUPPORT_WARNING,
- 		 g_param_spec_string ("support warning", _("Support Warning"),
- 				      _("A warning string about version mismatches"),
- 				      NULL, G_PARAM_READABLE));
- 
- 	/**
+ glade_widget_class_init (GladeWidgetClass * klass)
+ {
+   GObjectClass *object_class;
+ 
+   if (glade_widget_name_quark == 0)
+     glade_widget_name_quark = g_quark_from_static_string ("GladeWidgetDataTag");
+ 
+   object_class = G_OBJECT_CLASS (klass);
+ 
+   object_class->constructor = glade_widget_constructor;
+   object_class->finalize = glade_widget_finalize;
+   object_class->dispose = glade_widget_dispose;
+   object_class->set_property = glade_widget_set_real_property;
+   object_class->get_property = glade_widget_get_real_property;
+ 
+   klass->add_child = glade_widget_add_child_impl;
+   klass->remove_child = glade_widget_remove_child_impl;
+   klass->replace_child = glade_widget_replace_child_impl;
+   klass->event = glade_widget_event_impl;
+ 
+   klass->add_signal_handler = glade_widget_add_signal_handler_impl;
+   klass->remove_signal_handler = glade_widget_remove_signal_handler_impl;
+   klass->change_signal_handler = glade_widget_change_signal_handler_impl;
+ 
+   klass->button_press_event = glade_widget_button_press_event_impl;
+   klass->button_release_event = NULL;
+   klass->motion_notify_event = NULL;
+ 
+   g_object_class_install_property
+       (object_class, PROP_NAME,
+        g_param_spec_string ("name", _("Name"),
+                             _("The name of the widget"),
+                             NULL, G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
+ 
+   g_object_class_install_property
+       (object_class, PROP_INTERNAL,
+        g_param_spec_string ("internal", _("Internal name"),
+                             _("The internal name of the widget"),
+                             NULL, G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
+ 
+   g_object_class_install_property
+       (object_class, PROP_ANARCHIST,
+        g_param_spec_boolean ("anarchist", _("Anarchist"),
+                              _("Whether this composite child is "
+                                "an ancestral child or an anarchist child"),
+                              FALSE, G_PARAM_READWRITE |
+                              G_PARAM_CONSTRUCT_ONLY));
+ 
+   g_object_class_install_property
+       (object_class, PROP_OBJECT,
+        g_param_spec_object ("object", _("Object"),
+                             _("The object associated"),
+                             G_TYPE_OBJECT,
+                             G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
+ 
+   g_object_class_install_property
+       (object_class, PROP_ADAPTOR,
+        g_param_spec_object ("adaptor", _("Adaptor"),
+                             _("The class adaptor for the associated widget"),
+                             GLADE_TYPE_WIDGET_ADAPTOR,
+                             G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+ 
+   g_object_class_install_property
+       (object_class, PROP_PROJECT,
+        g_param_spec_object ("project", _("Project"),
+                             _("The glade project that "
+                               "this widget belongs to"),
+                             GLADE_TYPE_PROJECT,
+                             G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
+ 
+   g_object_class_install_property
+       (object_class, PROP_PROPERTIES,
+        g_param_spec_pointer ("properties", _("Properties"),
+                              _("A list of GladeProperties"),
+                              G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+ 
+   g_object_class_install_property
+       (object_class, PROP_PARENT,
+        g_param_spec_object ("parent", _("Parent"),
+                             _("A pointer to the parenting GladeWidget"),
+                             GLADE_TYPE_WIDGET,
+                             G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
+ 
+   g_object_class_install_property
+       (object_class, PROP_INTERNAL_NAME,
+        g_param_spec_string ("internal-name", _("Internal Name"),
+                             _("A generic name prefix for internal widgets"),
+                             NULL, G_PARAM_CONSTRUCT_ONLY | G_PARAM_WRITABLE));
+ 
+   g_object_class_install_property
+       (object_class, PROP_TEMPLATE,
+        g_param_spec_object ("template", _("Template"),
+                             _("A GladeWidget template to base a new widget on"),
+                             GLADE_TYPE_WIDGET,
+                             G_PARAM_CONSTRUCT_ONLY | G_PARAM_WRITABLE));
+ 
+   g_object_class_install_property
+       (object_class, PROP_TEMPLATE_EXACT,
+        g_param_spec_boolean ("template-exact", _("Exact Template"),
+                              _
+                              ("Whether we are creating an exact duplicate when using a template"),
+                              FALSE, G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
+ 
+   g_object_class_install_property
+       (object_class, PROP_REASON,
+        g_param_spec_int ("reason", _("Reason"),
+                          _("A GladeCreateReason for this creation"),
+                          GLADE_CREATE_USER,
+                          GLADE_CREATE_REASONS - 1,
+                          GLADE_CREATE_USER,
+                          G_PARAM_CONSTRUCT_ONLY | G_PARAM_WRITABLE));
+ 
+   g_object_class_install_property
+       (object_class, PROP_TOPLEVEL_WIDTH,
+        g_param_spec_int ("toplevel-width", _("Toplevel Width"),
+                          _("The width of the widget when toplevel in "
+                            "the GladeDesignLayout"),
+                          -1, G_MAXINT, -1, G_PARAM_READWRITE));
+ 
+   g_object_class_install_property
+       (object_class, PROP_TOPLEVEL_HEIGHT,
+        g_param_spec_int ("toplevel-height", _("Toplevel Height"),
+                          _("The height of the widget when toplevel in "
+                            "the GladeDesignLayout"),
+                          -1, G_MAXINT, -1, G_PARAM_READWRITE));
+ 
+   g_object_class_install_property
+       (object_class, PROP_SUPPORT_WARNING,
+        g_param_spec_string ("support warning", _("Support Warning"),
+                             _("A warning string about version mismatches"),
+                             NULL, G_PARAM_READABLE));
+ 
 -        /**
++    /**
  	 * GladeWidget::add-signal-handler:
  	 * @gladewidget: the #GladeWidget which received the signal.
  	 * @arg1: the #GladeSignal that was added to @gladewidget.
  	 */
- 	glade_widget_signals[ADD_SIGNAL_HANDLER] =
- 		g_signal_new ("add-signal-handler",
- 			      G_TYPE_FROM_CLASS (object_class),
- 			      G_SIGNAL_RUN_LAST,
- 			      G_STRUCT_OFFSET (GladeWidgetClass, add_signal_handler),
- 			      NULL, NULL,
- 			      g_cclosure_marshal_VOID__POINTER,
- 			      G_TYPE_NONE,
- 			      1,
- 			      G_TYPE_POINTER);
- 
- 	/**
+   glade_widget_signals[ADD_SIGNAL_HANDLER] =
+       g_signal_new ("add-signal-handler",
+                     G_TYPE_FROM_CLASS (object_class),
+                     G_SIGNAL_RUN_LAST,
+                     G_STRUCT_OFFSET (GladeWidgetClass, add_signal_handler),
+                     NULL, NULL,
+                     g_cclosure_marshal_VOID__POINTER,
+                     G_TYPE_NONE, 1, G_TYPE_POINTER);
+ 
 -        /**
++    /**
  	 * GladeWidget::remove-signal-handler:
  	 * @gladewidget: the #GladeWidget which received the signal.
  	 * @arg1: the #GladeSignal that was removed from @gladewidget.
@@@ -4379,26 -4260,9 +4299,26 @@@ glade_widget_unlock (GladeWidget * widg
   *
   */
  void
- glade_widget_support_changed (GladeWidget *widget)
+ glade_widget_support_changed (GladeWidget * widget)
  {
- 	g_return_if_fail (GLADE_IS_WIDGET (widget));
+   g_return_if_fail (GLADE_IS_WIDGET (widget));
  
- 	g_signal_emit (widget, glade_widget_signals[SUPPORT_CHANGED], 0);
+   g_signal_emit (widget, glade_widget_signals[SUPPORT_CHANGED], 0);
  }
 +
 +/**
 + * glade_widget_get_signal_model:
 + * @widget: A #GladeWidget
 + * 
 + * Returns: a GtkTreeModel that can be used to view the widget's signals.
 + *          The signal model is owned by the #GladeWidget.
 + */
 +GtkTreeModel *
 +glade_widget_get_signal_model (GladeWidget *widget)
 +{
 +	if (!widget->signal_model)
 +	{
 +		widget->signal_model = glade_signal_model_new (widget);
 +	}
 +	return widget->signal_model;
 +}



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