After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 572754 - Remove deprecated GTK+ symbols
Remove deprecated GTK+ symbols
Status: RESOLVED FIXED
Product: anjuta
Classification: Applications
Component: unknown
SVN TRUNK
Other Linux
: Normal normal
: ---
Assigned To: Anjuta maintainers
Anjuta maintainers
Depends on:
Blocks: 577721 585692
 
 
Reported: 2009-02-22 16:49 UTC by André Klapper
Modified: 2010-05-29 09:35 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch for this bug (32.27 KB, patch)
2009-03-12 17:16 UTC, Maxim Ermilov
none Details | Review
patch for this bug (94.77 KB, patch)
2009-03-15 21:51 UTC, Maxim Ermilov
reviewed Details | Review
corrected patch (103.24 KB, patch)
2009-03-19 17:27 UTC, Maxim Ermilov
committed Details | Review
patch for this bug (25.96 KB, patch)
2009-04-12 16:20 UTC, Maxim Ermilov
needs-work Details | Review
subversion plugin (22.63 KB, patch)
2009-04-13 15:46 UTC, Maxim Ermilov
needs-work Details | Review
corrected patch (63.80 KB, patch)
2009-04-14 15:57 UTC, Maxim Ermilov
committed Details | Review
Removed remaining deprecated GTK symbols (1.87 KB, patch)
2009-05-02 11:52 UTC, Javier Jardón (IRC: jjardon)
committed Details | Review
Replace deprecated GTK_OBJECT_TYPE with G_OBJECT_TYPE (1.45 KB, patch)
2010-01-18 21:50 UTC, Thomas Andersen
accepted-commit_now Details | Review

Description André Klapper 2009-02-22 16:49:42 UTC
http://live.gnome.org/GnomeGoals/RemoveDeprecatedSymbols/GTK%2B

GTK_CHECK_CAST, GTK_CHECK_CLASS_CAST, GTK_CHECK_CLASS_TYPE, GTK_CHECK_GET_CLASS, GTK_CHECK_TYPE, GTK_SIGNAL_FUNC, GtkDestroyNotify, GtkSignalFunc, GtkType, gdk_window_get_size, gtk_about_dialog_set_name, gtk_action_connect_proxy, gtk_box_pack_end_defaults, gtk_box_pack_start_defaults, gtk_button_box_set_spacing, gtk_combo_set_popdown_strings, gtk_file_selection_new, gtk_item_factory_get_widget, gtk_menu_append, gtk_object_get_data, gtk_object_sink, gtk_option_menu_get_history, gtk_option_menu_new, gtk_option_menu_set_history, gtk_option_menu_set_menu, gtk_signal_connect, gtk_signal_emit_by_name, gtk_signal_handler_block_by_func, gtk_signal_handler_unblock_by_func, gtk_timeout_add, gtk_tooltips_new, gtk_tooltips_set_tip, gtk_widget_set_uposition


To potential patch contributors:
It might make sense to break this into several smaller patches. :-P
When patching also make sure that the gtk and glib versions in
configure.in/.ac are high enough and take a look since which version the new
non-deprecated functions are available. http://library.gnome.org is your friend
here. :-)


(Note: Some lines may be listed twice because they contain two deprecated symbols)

$:andre\> grep -r GTK_CHECK_CAST .
./plugins/project-manager/gbf-project-model.h:#define GBF_PROJECT_MODEL(obj)	          (GTK_CHECK_CAST ((obj), GBF_TYPE_PROJECT_MODEL, GbfProjectModel))
./plugins/project-manager/gbf-project-view.h:#define GBF_PROJECT_VIEW(obj)		  (GTK_CHECK_CAST ((obj), GBF_TYPE_PROJECT_VIEW, GbfProjectView))
./plugins/scintilla/scintilla/include/ScintillaWidget.h:#define SCINTILLA(obj)          GTK_CHECK_CAST (obj, scintilla_get_type (), ScintillaObject)
./libanjuta/cell-renderer-captioned-image.h:#define ANJUTA_CELL_RENDERER_CAPTIONED_IMAGE(obj)		(GTK_CHECK_CAST ((obj), ANJUTA_TYPE_CELL_RENDERER_CAPTIONED_IMAGE, AnjutaCellRendererCaptionedImage))
./libanjuta/e-splash.h:#define E_SPLASH(obj)			(GTK_CHECK_CAST ((obj), E_TYPE_SPLASH, ESplash))

$:andre\> grep -r GTK_CHECK_CLASS_CAST .
./plugins/project-manager/gbf-project-model.h:#define GBF_PROJECT_MODEL_CLASS(klass)    (GTK_CHECK_CLASS_CAST ((klass), GBF_TYPE_PROJECT_MODEL, GbfProjectModelClass))
./plugins/project-manager/gbf-project-view.h:#define GBF_PROJECT_VIEW_CLASS(klass)	  (GTK_CHECK_CLASS_CAST ((klass), 
GBF_TYPE_PROJECT_VIEW, GbfProjectViewClass))
./plugins/scintilla/scintilla/include/ScintillaWidget.h:#define SCINTILLA_CLASS(klass)  GTK_CHECK_CLASS_CAST (klass, scintilla_get_type (), ScintillaClass)
./libanjuta/cell-renderer-captioned-image.h:#define ANJUTA_CELL_RENDERER_CAPTIONED_IMAGE_CLASS(klass)	(GTK_CHECK_CLASS_CAST ((klass), ANJUTA_TYPE_CELL_RENDERER_CAPTIONED_IMAGE, AnjutaCellRendererCaptionedImageClass))
./libanjuta/e-splash.h:#define E_SPLASH_CLASS(klass)		(GTK_CHECK_CLASS_CAST ((klass), E_TYPE_SPLASH, ESplashClass))

$:andre\> grep -r GTK_CHECK_CLASS_TYPE .
./plugins/project-manager/gbf-project-model.h:#define GBF_IS_PROJECT_MODEL_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GBF_TYPE_PROJECT_MODEL))
./plugins/project-manager/gbf-project-view.h:#define GBF_IS_PROJECT_VIEW_CLASS(klass)  (GTK_CHECK_CLASS_TYPE ((obj), GBF_TYPE_PROJECT_VIEW))
./libanjuta/cell-renderer-captioned-image.h:#define ANJUTA_IS_CELL_RENDERER_CAPTIONED_IMAGE_CLASS(klass)	(GTK_CHECK_CLASS_TYPE ((klass), ANJUTA_TYPE_CELL_RENDERER_CAPTIONED_IMAGE))
./libanjuta/e-splash.h:#define E_IS_SPLASH_CLASS(klass)		(GTK_CHECK_CLASS_TYPE ((obj), E_TYPE_SPLASH))

$:andre\> grep -r GTK_CHECK_GET_CLASS .
./libanjuta/cell-renderer-captioned-image.h:#define ANJUTA_CELL_RENDERER_CAPTIONED_IMAGE_GET_CLASS(obj)   (GTK_CHECK_GET_CLASS ((obj), ANJUTA_TYPE_CELL_RENDERER_CAPTIONED_IMAGE, AnjutaCellRendererCaptionedImageClass))

$:andre\> grep -r GTK_CHECK_TYPE .
./plugins/project-manager/gbf-project-model.h:#define GBF_IS_PROJECT_MODEL(obj)	      (GTK_CHECK_TYPE ((obj), GBF_TYPE_PROJECT_MODEL))
./plugins/project-manager/gbf-project-view.h:#define GBF_IS_PROJECT_VIEW(obj)	  (GTK_CHECK_TYPE ((obj), GBF_TYPE_PROJECT_VIEW))
./plugins/scintilla/scintilla/include/ScintillaWidget.h:#define IS_SCINTILLA(obj)       GTK_CHECK_TYPE (obj, scintilla_get_type ())
./libanjuta/cell-renderer-captioned-image.h:#define ANJUTA_IS_CELL_RENDERER_CAPTIONED_IMAGE(obj)		(GTK_CHECK_TYPE ((obj), ANJUTA_TYPE_CELL_RENDERER_CAPTIONED_IMAGE))
./libanjuta/e-splash.h:#define E_IS_SPLASH(obj)			(GTK_CHECK_TYPE ((obj), E_TYPE_SPLASH))

$:andre\> grep -r GTK_SIGNAL_FUNC .
./plugins/message-view/anjuta-msgman.c:	 GTK_SIGNAL_FUNC
./plugins/message-view/anjuta-msgman.c:	 GTK_SIGNAL_FUNC
./plugins/message-view/anjuta-msgman.c:	 GTK_SIGNAL_FUNC
./plugins/message-view/anjuta-msgman.c:	 GTK_SIGNAL_FUNC
./plugins/message-view/anjuta-msgman.c:	 GTK_SIGNAL_FUNC
./plugins/message-view/anjuta-msgman.c:	 GTK_SIGNAL_FUNC
./plugins/patch/patch-plugin.c:		 GTK_SIGNAL_FUNC (patch_level_changed), NULL);
./plugins/indent/indent-dialog.c:	 GTK_SIGNAL_FUNC(on_indent_checkbutton_toggled), 
./plugins/indent/indent-dialog.c:	 GTK_SIGNAL_FUNC(on_indent_spinbutton_value_changed), 
./plugins/indent/indent-dialog.c:	 GTK_SIGNAL_FUNC (on_indent_parameters_entry_changed),
./plugins/indent/indent-dialog.c:	 GTK_SIGNAL_FUNC (on_indent_parameters_entry_changed),
./plugins/indent/indent-dialog.c:	 GTK_SIGNAL_FUNC (on_indent_parameters_entry_changed),
./plugins/indent/indent-dialog.c:	 GTK_SIGNAL_FUNC (on_indent_parameters_entry_changed),
./plugins/debug-manager/signals.c:	 GTK_SIGNAL_FUNC (on_signals_delete_event),sg);
./plugins/debug-manager/signals.c:	GTK_SIGNAL_FUNC (on_signals_key_press_event), sg);
./plugins/scintilla/scintilla/PlatGTK.cxx:	GTK_SIGNAL_FUNC(UnselectionAC), &current);
./plugins/scintilla/scintilla/PlatGTK.cxx:	GTK_SIGNAL_FUNC(SelectionAC), &current);
./plugins/scintilla/scintilla/PlatGTK.cxx:	GTK_SIGNAL_FUNC(ButtonPress), this);
./plugins/tools/dialog.c:	glade_xml_signal_connect_data (xml, TOOL_ADD_SIGNAL, GTK_SIGNAL_FUNC (on_tool_add), this);
./plugins/tools/dialog.c:	glade_xml_signal_connect_data (xml, TOOL_ACTIVATED_SIGNAL, GTK_SIGNAL_FUNC (on_tool_activated), this);
./plugins/tools/dialog.c:	glade_xml_signal_connect_data (xml, TOOL_EDIT_SIGNAL, GTK_SIGNAL_FUNC (on_tool_edit), this);
./plugins/tools/dialog.c:	glade_xml_signal_connect_data (xml, TOOL_DELETE_SIGNAL, GTK_SIGNAL_FUNC (on_tool_delete), this);
./plugins/tools/dialog.c:	glade_xml_signal_connect_data (xml, TOOL_UP_SIGNAL, GTK_SIGNAL_FUNC (on_tool_up), this);
./plugins/tools/dialog.c:	glade_xml_signal_connect_data (xml, TOOL_DOWN_SIGNAL, GTK_SIGNAL_FUNC (on_tool_down), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, VARIABLE_RESPONSE_SIGNAL, GTK_SIGNAL_FUNC (on_variable_response), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, VARIABLE_ACTIVATE_SIGNAL, GTK_SIGNAL_FUNC (on_variable_activate), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, EDITOR_RESPONSE_SIGNAL, GTK_SIGNAL_FUNC (on_editor_response), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, EDITOR_PARAM_VARIABLE_SIGNAL, GTK_SIGNAL_FUNC (on_editor_param_variable_show), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, EDITOR_DIR_VARIABLE_SIGNAL, GTK_SIGNAL_FUNC (on_editor_dir_variable_show), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, EDITOR_TOGGLE_SHORCUT_SIGNAL, GTK_SIGNAL_FUNC (on_editor_shortcut_toggle), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, EDITOR_TOGGLE_TERMINAL_SIGNAL, GTK_SIGNAL_FUNC (on_editor_terminal_toggle), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, EDITOR_TOGGLE_SCRIPT_SIGNAL, GTK_SIGNAL_FUNC (on_editor_script_toggle), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, EDITOR_INPUT_VARIABLE_SIGNAL, GTK_SIGNAL_FUNC (on_editor_input_variable_show), this);
./plugins/tools/editor.c:	glade_xml_signal_connect_data (xml, EDITOR_INPUT_CHANGED_SIGNAL, GTK_SIGNAL_FUNC (on_editor_input_changed), this);

$:andre\> grep -r GtkDestroyNotify .
./plugins/scintilla/style-editor.c:  (GtkDestroyNotify)style_data_destroy);

$:andre\> grep -r GtkSignalFunc .
./plugins/gdb/utilities.h:	   GtkSignalFunc callback,
./plugins/gdb/utilities.h:	  const gchar *tooltip, GtkSignalFunc callback, 
./plugins/indent/indent-dialog.c:  (GtkSignalFunc)indent_exit,
./plugins/indent/indent-dialog.c:  (GtkSignalFunc)indent_exit,
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		 GtkSignalFunc(ScintillaGTK::StyleSetText), NULL);
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		 GtkSignalFunc(ScintillaGTK::RealizeText), NULL);
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		 GtkSignalFunc(ScintillaGTK::ExposeText), this);
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		 GtkSignalFunc(ScrollSignal), this);
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		 GtkSignalFunc(ScrollHSignal), this);
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		  GtkSignalFunc(ScintillaGTK::ExposeCT), &ct);
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		  GtkSignalFunc(ScintillaGTK::PressCT), static_cast<void *>(this));

$:andre\> grep -r GtkType .
./plugins/sourceview/anjuta-view.h:GtkType	 anjuta_view_get_type  	(void) G_GNUC_CONST;
./plugins/scintilla/scintilla/include/ScintillaWidget.h:GtkType		scintilla_get_type	(void);
./plugins/scintilla/scintilla/ScintillaGTK.cxx:GtkType scintilla_get_type() {
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	static GtkType scintilla_type = 0;
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		static GtkTypeInfo scintilla_info = {
./libanjuta/e-splash.h:GtkType    e_splash_get_type            (void);

$:andre\> grep -r gdk_window_get_size .
./plugins/debug-manager/signals.c:		gdk_window_get_size (sg->widgets.window->window, &sg->win_width,
./plugins/debug-manager/sharedlib.c:		gdk_window_get_size(sl ->widgets.window->window, &sl->win_width,
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gdk_window_get_size(widget->window, &width, &height);
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gdk_window_get_size(widget->window, &width, &height);

$:andre\> grep -r gtk_about_dialog_set_name .
./src/about.c:	gtk_about_dialog_set_name(GTK_ABOUT_DIALOG(dialog), name);

$:andre\> grep -r gtk_action_connect_proxy .
./plugins/glade/plugin.c:	gtk_action_connect_proxy (action, GTK_WIDGET (priv->button_undo));
./plugins/glade/plugin.c:	gtk_action_connect_proxy (action, GTK_WIDGET (priv->button_redo));

$:andre\> grep -r gtk_box_pack_end_defaults .
./plugins/macro/macro-actions.c:	gtk_box_pack_end_defaults(GTK_BOX(hbox), entry);
./plugins/symbol-db/symbol-db-view-search.c:	gtk_box_pack_end_defaults (GTK_BOX (search), frame);
./src/shell.c:	gtk_box_pack_end_defaults (GTK_BOX (shell->box), plugins);

$:andre\> grep -r gtk_box_pack_start_defaults .
./plugins/macro/macro-actions.c:	gtk_box_pack_start_defaults(GTK_BOX(hbox), label);
./plugins/document-manager/plugin.c:	gtk_box_pack_start_defaults (GTK_BOX(dplugin->vbox), docman);
./plugins/document-manager/anjuta-bookmarks.c:	gtk_box_pack_start_defaults (GTK_BOX(button_box), priv->button_add);
./plugins/document-manager/anjuta-bookmarks.c:	gtk_box_pack_start_defaults (GTK_BOX(button_box), priv->button_remove);
./libanjuta/anjuta-launcher.c:	gtk_box_pack_start_defaults (GTK_BOX(hbox), icon);
./libanjuta/anjuta-launcher.c:	gtk_box_pack_start_defaults (GTK_BOX (hbox), box);
./src/shell.c:	gtk_box_pack_start_defaults (GTK_BOX (GTK_DIALOG(win)->vbox), accel_editor);

$:andre\> grep -r gtk_button_box_set_spacing .
./plugins/gtodo/mcategory.c:	gtk_button_box_set_spacing(GTK_BUTTON_BOX(vbutbox), 6);

$:andre\> grep -r gtk_combo_set_popdown_strings .
./plugins/scintilla/style-editor.c:	gtk_combo_set_popdown_strings (GTK_COMBO (se->priv->hilite_item_combo), list);

$:andre\> grep -r gtk_file_selection_new .
./plugins/gtodo/tasklists.c:	selection = gtk_file_selection_new(_("Open a Task List"));
./plugins/gtodo/tasklists.c:	selection = gtk_file_selection_new(_("Create a Task List"));

$:andre\> grep -r gtk_item_factory_get_widget .
./plugins/gtodo/todo_db.c:	// FIXME: gtk_widget_set_sensitive (gtk_item_factory_get_widget
./plugins/gtodo/todo_db.c:	// FIXME: gtk_widget_set_sensitive (gtk_item_factory_get_widget
./plugins/gtodo/todo_db.c:	// FIXME: gtk_widget_set_sensitive (gtk_item_factory_get_widget
./plugins/gtodo/todo_db.c:	// FIXME: gtk_widget_set_sensitive (gtk_item_factory_get_widget
./plugins/gtodo/interface.c:	/*    settings.hide_done = gtk_check_menu_item_get_active(GTK_CHECK_MENU_ITEM (gtk_item_factory_get_widget(mw.item_factory, N_("/View/Todo List/Hide Completed Items"))));*/
./plugins/scintilla/scintilla/ScintillaGTK.cxx:		GtkWidget *item = gtk_item_factory_get_widget_by_action(
./plugins/scintilla/scintilla/PlatGTK.cxx:	GtkWidget *widget = gtk_item_factory_get_widget(factory, "<main>");

$:andre\> grep -r gtk_menu_append .
./plugins/file-loader/plugin.c:	gtk_menu_append (menu, menuitem);
./plugins/file-loader/plugin.c:	gtk_menu_append (menu, menuitem);
./plugins/file-loader/plugin.c:	gtk_menu_append (menu, menuitem);
./plugins/file-loader/plugin.c:	gtk_menu_append (menu, menuitem);
./plugins/file-loader/plugin.c:	gtk_menu_append (menu, menuitem);
./plugins/file-loader/plugin.c:	gtk_menu_append (menu, menuitem);
./plugins/file-loader/plugin.c:	gtk_menu_append (menu, menuitem);
./plugins/file-wizard/file.c:	gtk_menu_append(GTK_MENU(menu), menuitem);
./plugins/file-wizard/file.c:	gtk_menu_append(GTK_MENU(menu), menuitem);
./src/anjuta-app.c:	gtk_menu_append (GTK_MENU (app->view_menu), GTK_WIDGET (menuitem));

$:andre\> grep -r gtk_object_get_data .
./plugins/scintilla/style-editor.c:	gtk_object_get_data (GTK_OBJECT (se->priv->dialog),
./plugins/scintilla/style-editor.c:	gtk_object_get_data (GTK_OBJECT (se->priv->dialog),

$:andre\> grep -r gtk_object_sink .
./plugins/project-wizard/druid.c:	gtk_object_sink (GTK_OBJECT (tooltips));
./plugins/class-gen/combo-flags.c:	gtk_object_sink (GTK_OBJECT (cell));
./plugins/class-gen/combo-flags.c:	gtk_object_sink (GTK_OBJECT (cell));
./plugins/valgrind/vgdefaultview.c:	gtk_object_sink (GTK_OBJECT (view->rule_list));
./plugins/scintilla/aneditor.cxx:	gtk_object_sink (GTK_OBJECT (wEditor.GetID()));

$:andre\> grep -r gtk_option_menu_get_history .
./plugins/valgrind/vgrule-editor.c:	type = gtk_option_menu_get_history (editor->type);
./plugins/valgrind/vgrule-editor.c:	type = gtk_option_menu_get_history (GTK_OPTION_MENU (omenu));
./plugins/gtodo/export.c:		cat = gtk_option_menu_get_history (GTK_OPTION_MENU (mw.option));
./plugins/gtodo/callback.c:		int i = gtk_option_menu_get_history(GTK_OPTION_MENU(mw.option));
./plugins/gtodo/callback.c:	if(gtk_option_menu_get_history(GTK_OPTION_MENU(mw.option))== 0)tm = g_strdup_printf(_("Are you sure you want to remove all the completed todo items?"));
./plugins/gtodo/callback.c:	else tm = g_strdup_printf(_("Are you sure you want to remove all the completed todo items in the category \"%s\"?"), mw.mitems[gtk_option_menu_get_history(GTK_OPTION_MENU(mw.option))-2]->date);
./plugins/gtodo/add_edit_item.c:	if(!edit)gtk_option_menu_set_history(GTK_OPTION_MENU(option), gtk_option_menu_get_history(GTK_OPTION_MENU(mw.option))-2);
./plugins/gtodo/add_edit_item.c:	gtodo_todo_item_set_category(item, mw.mitems[gtk_option_menu_get_history(GTK_OPTION_MENU(option))]->date);
./plugins/gtodo/add_edit_item.c:	gtodo_todo_item_set_priority(item, 2-gtk_option_menu_get_history(GTK_OPTION_MENU(priority)));
./plugins/gtodo/add_edit_item.c:	int i = gtk_option_menu_get_history(option);    
./plugins/gtodo/todo_db.c:	last_category = gtk_option_menu_get_history (GTK_OPTION_MENU (mw.option));
./plugins/gtodo/todo_db.c:	if (gtk_option_menu_get_history (GTK_OPTION_MENU (mw.option)) == 0)
./plugins/gtodo/todo_db.c:			mw.mitems[gtk_option_menu_get_history (GTK_OPTION_MENU (mw.option)) -
./plugins/gtodo/list_tooltip.c:	int i = gtk_option_menu_get_history(GTK_OPTION_MENU(mw.option));
./plugins/file-loader/plugin.c:		option = gtk_option_menu_get_history(GTK_OPTION_MENU (options));
./plugins/file-wizard/file.c:	source_type = gtk_option_menu_get_history(GTK_OPTION_MENU(optionmenu));
./plugins/file-wizard/file.c:		sel = gtk_option_menu_get_history(GTK_OPTION_MENU(optionmenu));
./plugins/file-wizard/file.c:		sel = gtk_option_menu_get_history(GTK_OPTION_MENU(optionmenu));
./plugins/file-wizard/file.c:	sel = gtk_option_menu_get_history(optionmenu);

$:andre\> grep -r gtk_option_menu_new .
./plugins/valgrind/vgmemcheckprefs.c:	omenu = gtk_option_menu_new ();
./plugins/valgrind/vghelgrindprefs.c:	omenu = gtk_option_menu_new ();
./plugins/valgrind/vgrule-editor.c:	omenu = gtk_option_menu_new ();
./plugins/valgrind/vgrule-editor.c:	omenu = gtk_option_menu_new ();
./plugins/valgrind/vgsearchbar.c:	bar->menu = GTK_OPTION_MENU (widget = gtk_option_menu_new ());
./plugins/gtodo/add_edit_item.c:	option = gtk_option_menu_new();
./plugins/gtodo/add_edit_item.c:		priority = gtk_option_menu_new();
./plugins/gtodo/interface.c:	mw.option = gtk_option_menu_new();
./plugins/file-loader/plugin.c:	options = gtk_option_menu_new ();

$:andre\> grep -r gtk_option_menu_set_history .
./plugins/valgrind/vgmemcheckprefs.c:	gtk_option_menu_set_history (GTK_OPTION_MENU (omenu), history);
./plugins/valgrind/vghelgrindprefs.c:	gtk_option_menu_set_history (GTK_OPTION_MENU (omenu), history);
./plugins/valgrind/vgrule-editor.c:	gtk_option_menu_set_history (GTK_OPTION_MENU (omenu), (int) type);
./plugins/valgrind/vgrule-editor.c:	gtk_option_menu_set_history (editor->type, (int) type);
./plugins/valgrind/vgsearchbar.c:	gtk_option_menu_set_history (bar->menu, 0);
./plugins/valgrind/vgsearchbar.c:	gtk_option_menu_set_history (bar->menu, 0);
./plugins/gtodo/callback.c:			if(j < categorys+3 && mw.mitems != NULL && mw.mitems[j-2] != NULL) gtk_option_menu_set_history(GTK_OPTION_MENU(mw.option),j);
./plugins/gtodo/add_edit_item.c:	gtk_option_menu_set_history(GTK_OPTION_MENU(option), i);
./plugins/gtodo/add_edit_item.c:	if(!edit)gtk_option_menu_set_history(GTK_OPTION_MENU(option), gtk_option_menu_get_history(GTK_OPTION_MENU(mw.option))-2);
./plugins/gtodo/add_edit_item.c:	gtk_option_menu_set_history(GTK_OPTION_MENU(priority), 1);
./plugins/gtodo/add_edit_item.c:	gtk_option_menu_set_history(GTK_OPTION_MENU(priority), 2-gtodo_todo_item_get_priority(item));
./plugins/gtodo/add_edit_item.c:	gtk_option_menu_set_history(GTK_OPTION_MENU(option), 0);	
./plugins/gtodo/todo_db.c:		gtk_option_menu_set_history (GTK_OPTION_MENU (mw.option), last_category);
./plugins/gtodo/todo_db.c:		gtk_option_menu_set_history (GTK_OPTION_MENU (mw.option), 0);
./plugins/gtodo/interface.c:		gtk_option_menu_set_history(GTK_OPTION_MENU(mw.option),i);

$:andre\> grep -r gtk_option_menu_set_menu .
./plugins/valgrind/vgmemcheckprefs.c:	gtk_option_menu_set_menu (GTK_OPTION_MENU (omenu), menu);
./plugins/valgrind/vghelgrindprefs.c:	gtk_option_menu_set_menu (GTK_OPTION_MENU (omenu), menu);
./plugins/valgrind/vgrule-editor.c:	gtk_option_menu_set_menu (GTK_OPTION_MENU (omenu), menu);
./plugins/valgrind/vgrule-editor.c:	gtk_option_menu_set_menu (GTK_OPTION_MENU (omenu), menu);
./plugins/valgrind/vgsearchbar.c:	gtk_option_menu_set_menu (bar->menu, menu);
./plugins/gtodo/add_edit_item.c:	gtk_option_menu_set_menu(GTK_OPTION_MENU(option), menu);
./plugins/gtodo/add_edit_item.c:	gtk_option_menu_set_menu(GTK_OPTION_MENU(priority), pmenu);
./plugins/gtodo/add_edit_item.c:	gtk_option_menu_set_menu(GTK_OPTION_MENU(option), menu);
./plugins/gtodo/interface.c:	gtk_option_menu_set_menu(GTK_OPTION_MENU(mw.option), mw.menu);
./plugins/file-loader/plugin.c:	gtk_option_menu_set_menu (GTK_OPTION_MENU (options), menu);
./plugins/file-wizard/file.c:	gtk_option_menu_set_menu(GTK_OPTION_MENU(optionmenu), menu);
./plugins/file-wizard/file.c:	gtk_option_menu_set_menu(GTK_OPTION_MENU(optionmenu), menu);

$:andre\> grep -r gtk_signal_connect .
./plugins/debug-manager/signals.c:	gtk_signal_connect (GTK_OBJECT (window3), "delete_event",
./plugins/debug-manager/signals.c:	gtk_signal_connect (GTK_OBJECT (window3), "key-press-event",
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gtk_signal_connect_after(GTK_OBJECT(widtxt), "style_set",
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gtk_signal_connect_after(GTK_OBJECT(widtxt), "realize",
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gtk_signal_connect(GTK_OBJECT(widtxt), "expose_event",
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gtk_signal_connect(adjustmentv, "value_changed",
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gtk_signal_connect(adjustmenth, "value_changed",
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gtk_signal_connect(GTK_OBJECT(widcdrw), "expose_event",
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	gtk_signal_connect(GTK_OBJECT(widcdrw), "button_press_event",
./plugins/scintilla/scintilla/PlatGTK.cxx:	gtk_signal_connect(GTK_OBJECT(wid), "unselect_row",
./plugins/scintilla/scintilla/PlatGTK.cxx:	gtk_signal_connect(GTK_OBJECT(wid), "select_row",
./plugins/scintilla/scintilla/PlatGTK.cxx:	gtk_signal_connect(GTK_OBJECT(wid), "button_press_event",

$:andre\> grep -r gtk_signal_emit_by_name .
./plugins/file-wizard/file.c:	gtk_signal_emit_by_name(GTK_OBJECT (optionmenu), "changed");
./src/start-with.c:	gtk_signal_emit_by_name (GTK_OBJECT (app->menubar.file.new_project),
./src/start-with.c:	gtk_signal_emit_by_name (GTK_OBJECT (app->menubar.file.import_project),
./src/start-with.c:	gtk_signal_emit_by_name (GTK_OBJECT (app->menubar.file.open_project),
./src/start-with.c:	gtk_signal_emit_by_name (GTK_OBJECT (app->menubar.file.open_file),
./src/start-with.c:	gtk_signal_emit_by_name (GTK_OBJECT (app->menubar.file.new_file),

$:andre\> grep -r gtk_signal_handler_block_by_func .
./libanjuta/anjuta-preferences.c:	gtk_signal_handler_block_by_func (GTK_OBJECT(p->object), G_CALLBACK (update_property_on_change_str), p);

$:andre\> grep -r gtk_signal_handler_unblock_by_func .
./libanjuta/anjuta-preferences.c:	gtk_signal_handler_unblock_by_func (GTK_OBJECT(p->object), G_CALLBACK (update_property_on_change_str), p);

$:andre\> grep -r gtk_timeout_add .
./plugins/scintilla/scintilla/ScintillaGTK.cxx:	timer.tickerID = reinterpret_cast<TickerID>(gtk_timeout_add(timer.tickSize, (GtkFunction)TimeOut, this));
./libanjuta/anjuta-launcher.c:/* monitors closure of stdout stderr and pty through a gtk_timeout_add setup */

$:andre\> grep -r gtk_tooltips_new .
./plugins/project-wizard/druid.c:	tooltips = data->druid->tooltips = gtk_tooltips_new ();

$:andre\> grep -r gtk_tooltips_set_tip .
./plugins/project-wizard/druid.c:	gtk_tooltips_set_tip (tooltips, entry, description, NULL);

$:andre\> grep -r gtk_widget_set_uposition .
./plugins/debug-manager/signals.c:	gtk_widget_set_uposition (sg->widgets.window, sg->win_pos_x,
./plugins/debug-manager/sharedlib.c:	gtk_widget_set_uposition(sl->widgets.window, sl->win_pos_x,
./plugins/scintilla/scintilla/PlatGTK.cxx:	//gtk_widget_set_uposition(id, rc.left, rc.top);
./plugins/scintilla/scintilla/PlatGTK.cxx:	gtk_widget_set_uposition(id, rc.left, rc.top);
./plugins/scintilla/scintilla/PlatGTK.cxx:	gtk_widget_set_uposition(PWidget(id), ox, oy);
Comment 1 Maxim Ermilov 2009-03-12 17:16:48 UTC
Created attachment 130544 [details] [review]
patch for this bug

Remove deprecated GTK+ symbols except : gtk_action_connect_proxy, gtk_combo_set_popdown_strings, gtk_file_selection_new, gtk_item_factory_get_widget, gtk_object_sink, gtk_option_menu_get_history, gtk_option_menu_new, gtk_option_menu_set_history, gtk_option_menu_set_menu, gtk_tooltips_new, gtk_tooltips_set_tip, gtk_widget_set_uposition
Comment 2 Maxim Ermilov 2009-03-15 21:51:12 UTC
Created attachment 130713 [details] [review]
patch for this bug

Use GtkComboBox instead GtkOptionMenu in valgrind, gtodo, file-wizard, file-loader && remove libgnome dependency.
Now all code can compile with "-DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED" except gtodo(gtk_item_factory_get_widget), tools (GnomeEntry), class-inheritance (GnomeCanvasItem) and main.
Comment 3 André Klapper 2009-03-17 10:23:03 UTC
Maxim, you rock!
Thanks for all your clean up work in general in the last months!

(For GnomeCanvasItem see bug 571740.)
Comment 4 Johannes Schmid 2009-03-18 08:19:25 UTC
(In reply to comment #2)
> Created an attachment (id=130713) [edit]
> patch for this bug
> 
> Use GtkComboBox instead GtkOptionMenu in valgrind, gtodo, file-wizard,
> file-loader && remove libgnome dependency.
> Now all code can compile with "-DGDK_PIXBUF_DISABLE_DEPRECATED
> -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED" except
> gtodo(gtk_item_factory_get_widget), tools (GnomeEntry), class-inheritance
> (GnomeCanvasItem) and main.
> 

Thanks for the patch!

The patch uses GtkActivatable with is not available in gtk+ 2.12 which anjuta currently depends on. Probably you can use some #ifdefs for that part.

There are also some warnings in the scratchbox plugin because you miss a cast and assign a const gchar* to a gchar*.

Please check if everything compiles cleanly and there are no new warnings and more important if everything still works as expected.

gtk_item_factory should be replaced by GtkUIManager which is used in many other anjuta modules. GnomeEntry should be replaced by GtkEntry (maybe with some special handling).

Comment 5 Maxim Ermilov 2009-03-19 17:27:37 UTC
Created attachment 130982 [details] [review]
corrected patch

Add #if where uses GtkActivatable. Fix all new warnings (on gcc 4.3.2) . With this patch, everything still works as expected.
Comment 6 Johannes Schmid 2009-03-19 17:44:11 UTC
Thanks!

Actually some of the warnings weren't caused by you - sorry about that.

I will have a look at the patch soon!
Comment 7 Johannes Schmid 2009-03-30 21:45:17 UTC
Commited the patch to trunk - Thanks!

Do you think you could take care of the GnomeEntry (should be trivial) and GtkItemFactory stuff? GnomeCanvas is definitly a bigger work...
Comment 8 Maxim Ermilov 2009-04-12 16:20:27 UTC
Created attachment 132558 [details] [review]
patch for this bug

I removed deprecated GTK+ symbols in cvs-plugin(Without that It can be port to GtkBuilder)
Comment 9 Maxim Ermilov 2009-04-12 17:12:00 UTC
(In reply to comment #8)
> I removed deprecated GTK+ symbols in cvs-plugin(Without that It can be port to
> GtkBuilder)
> 

Without that It can NOT be port to GtkBuilder.
Comment 10 Maxim Ermilov 2009-04-13 15:46:45 UTC
Created attachment 132597 [details] [review]
subversion plugin

I replaced all deprecated widgets in subversion plugin(GnomeFileEntry, GnomeEntry).
Comment 11 Johannes Schmid 2009-04-13 16:49:09 UTC
Thanks for the patches:
- Can you please give the widget more descriptive names than "button01" or "button03"?
- Please use #define BUTTON_OK "button_ok" or something like that at the beginning of source files to avoid "magic" strings in the source code. Some older code may not follow this very strictly but it's better anyway.

Otherwise they look good.
Comment 12 Maxim Ermilov 2009-04-14 15:57:54 UTC
Created attachment 132644 [details] [review]
corrected patch

I corrected patch & replaced all deprecated widgets in tools plugin(GnomeFileEntry, GnomeIconEntry, GnomeEntry).
Comment 13 Johannes Schmid 2009-04-15 22:25:25 UTC
Thanks a lot. Basically, only the GnomeIconEntry in the project-wizard remains!
Comment 14 André Klapper 2009-04-22 14:30:01 UTC
http://www.gnome.org/~fpeters/299.html lists for Anjuta:
"gdk_pixbuf_unref, gtk_action_connect_proxy, gtk_item_factory_get_widget, gtk_object_sink, gtk_timeout_add"
Comment 15 Javier Jardón (IRC: jjardon) 2009-05-02 11:52:26 UTC
Created attachment 133799 [details] [review]
Removed remaining deprecated GTK symbols

I can compile with make CFLAGS+="-DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED -DG_DISABLE_DEPRECATED"
Comment 16 Johannes Schmid 2009-05-04 07:26:02 UTC
Thanks for your patch and sorry that you had to bother with file-manager.old which should have been removed long ago but someone slipped in again after the git<->svn migration.
Comment 17 André Klapper 2009-06-11 02:12:29 UTC
Hmm. Somehow deprecated gtk_notebook_set_page got back in again twice, hence reopening.

Fixing this should be very trivial.
http://library.gnome.org/devel/gtk/unstable/GtkNotebook.html#gtk-notebook-set-page

$:andre\> grep -r gtk_notebook_set_page .
./plugins/devhelp/plugin.c:	gtk_notebook_set_page (GTK_NOTEBOOK(devhelp->control_notebook), page);
./plugins/symbol-db/plugin.c:	gtk_notebook_set_page (GTK_NOTEBOOK(sdb_plugin->dbv_notebook), page);
Comment 18 Massimo Cora' 2009-06-11 16:37:24 UTC
I've just committed the fix. It was due to some modifications on the last patch by Johannes.

Comment 19 André Klapper 2009-06-22 10:22:46 UTC
Guys, you again committed stuff that is deprecated.

http://git.gnome.org/cgit/anjuta/commit/?id=500f62ad65544b59aecc6a8429cd5210ba48790d
http://library.gnome.org/devel/gtk/unstable/GtkWidget.html#gtk-widget-get-action

Can you PLEASE by default use the corresponding flags to avoid this?
make CFLAGS+="-DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED -DG_DISABLE_DEPRECATED"

This is the second time I reopen this ticket.
Comment 20 Johannes Schmid 2009-06-22 11:47:31 UTC
Sorry, this was code copied from gedit so I expected it to be fine. I am sorry, but we cannot use the deprecation flags because we rely on GnomeIconEntry which has no replacement and which doesn't build with GTK_DISABLE_DEPRECTED.
Comment 21 Luis Menina 2009-06-24 00:34:10 UTC
Can't GnomeIconEntry be replaced by a GtkLabel with an icon (using gtk_entry_set_icon_*) ? This would only need a bump to GTK 2.16.
Comment 22 Johannes Schmid 2009-06-24 07:18:55 UTC
GnomeIconEntry is not like SexyIconEntry but more like a GtkFileChooserButton for icons so I don't see how this could be replaced by GtkEntry.
Comment 23 Sébastien Granjoux 2009-06-24 17:25:53 UTC
I have worked on this (see bug #513156).

Nautilus was using such widget in one of its property dialog. It is now using a GtkButton with an image and display a file selection dialog when it is clicked.

So I have done the same change in Anjuta, I have already done the change, it just needs more code.
Comment 24 Thomas Andersen 2010-01-18 21:49:30 UTC
Anjuta used deprecated GTK_OBJECT_TYPE in plugins/glade/plugin.c
Comment 25 Thomas Andersen 2010-01-18 21:50:22 UTC
Created attachment 151718 [details] [review]
Replace deprecated GTK_OBJECT_TYPE with G_OBJECT_TYPE

GTK_OBJECT_TYPE is defined as G_OBJECT_TYPE

http://library.gnome.org/devel/gtk/unstable/GtkObject.html#GTK-OBJECT-TYPE:CAPS
Comment 26 Sébastien Granjoux 2010-01-19 18:52:11 UTC
Review of attachment 151718 [details] [review]:

Thanks for your report and your patch. I have just committed it.
Comment 27 André Klapper 2010-05-28 10:53:52 UTC
As Anjuta developers looove to add deprecated code, reopening this ticket for the 4th time:

$:andre\> grep -r gdk_pixbuf_ref .
./plugins/class-inheritance/class-inherit.c: gdk_pixbuf_ref (icon);
./plugins/class-inheritance/class-inherit.c: gdk_pixbuf_ref (icon);
$:andre\> grep -r gdk_pixbuf_unref .
./plugins/class-inheritance/class-inherit.c: gdk_pixbuf_unref (cls_item->icon);
$:andre\> grep -r gtk_object_sink .
./libfoocanvas/foo-canvas.c:	gtk_object_sink (GTK_OBJECT (item));
./libfoocanvas/foo-canvas.c:	gtk_object_sink (GTK_OBJECT (canvas->root));

(In reply to comment #20)
> but we cannot use the deprecation flags because we rely on GnomeIconEntry which
> has no replacement and which doesn't build with GTK_DISABLE_DEPRECTED.

I don't think this is an argument anymore (see bug 513156 comment 87) so please consider using -DGSEAL_ENABLE by default.
Comment 28 André Klapper 2010-05-28 10:54:52 UTC
(In reply to comment #27)
> I don't think this is an argument anymore (see bug 513156 comment 87) so please
> consider using -DGSEAL_ENABLE by default.

Ahem. Of course not the GSEAL flag, but the correct one here.
Comment 29 André Klapper 2010-05-28 11:09:28 UTC
> ./libfoocanvas/foo-canvas.c:    gtk_object_sink (GTK_OBJECT (item));
> ./libfoocanvas/foo-canvas.c:    gtk_object_sink (GTK_OBJECT (canvas->root));

Okay, these two have #if GLIB_CHECK_VERSION(2,10,0) && GTK_CHECK_VERSION(2,8,14).
Comment 30 André Klapper 2010-05-28 19:00:51 UTC
As this was trivial I went ahead and fixed this in http://git.gnome.org/browse/anjuta/commit/?id=f87c4d4ce2587dc0f65c906805caac400da0455e 

Closing as FIXED for some time until somebody breaks something again.
Comment 31 Naba Kumar 2010-05-29 09:30:52 UTC
(In reply to comment #27)
> As Anjuta developers looove to add deprecated code, reopening this ticket for
> the 4th time:
> 
Sorry, it happened because we moved class-inheritance plugin into anjuta main tree. Incidentally, my disable deprecation guards didn't cover all corners. Curiously, how did you detect it (I was using -DG/GDK/GTK_DISABLE_DEPRECATED apparently missed them)?
Comment 32 Naba Kumar 2010-05-29 09:35:06 UTC
(In reply to comment #31)
> (In reply to comment #27)
> > As Anjuta developers looove to add deprecated code, reopening this ticket for
> > the 4th time:
> > 
> Sorry, it happened because we moved class-inheritance plugin into anjuta main
> tree. Incidentally, my disable deprecation guards didn't cover all corners.
> Curiously, how did you detect it (I was using -DG/GDK/GTK_DISABLE_DEPRECATED
> apparently missed them)?

Hmm, looking at it now, it might be because I *forgot* to guard the plugin code while focusing on libfoocanvas where the guards were. Nevermind.

But thanks a lot!

As a side note, should we enable deprecation guards for maintainer mode?