Revision: 5840 http://geany.svn.sourceforge.net/geany/?rev=5840&view=rev Author: colombanw Date: 2011-06-13 18:41:50 +0000 (Mon, 13 Jun 2011)
Log Message: ----------- Deprecate ui_widget_set_tooltip_text() in favor of gtk_widget_set_tooltip_text()
Modified Paths: -------------- trunk/ChangeLog trunk/plugins/export.c trunk/plugins/filebrowser.c trunk/plugins/splitwindow.c trunk/src/build.c trunk/src/dialogs.c trunk/src/document.c trunk/src/highlighting.c trunk/src/printing.c trunk/src/project.c trunk/src/search.c trunk/src/ui_utils.c trunk/src/vte.c
Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/ChangeLog 2011-06-13 18:41:50 UTC (rev 5840) @@ -2,6 +2,12 @@
* configure.ac, src/Makefile.am, src/makefile.win32, wscript: Dump dependencies to GTK >= 2.12, GLib >= 2.16 and GIO. + * plugins/export.c, plugins/filebrowser.c, plugins/splitwindow.c, + src/build.c, src/dialogs.c, src/document.c, src/highlighting.c, + src/printing.c, src/project.c, src/search.c, src/ui_utils.c, + src/vte.c: + Deprecate ui_widget_set_tooltip_text() in favor of + gtk_widget_set_tooltip_text().
2011-06-11 Colomban Wendling <colomban(at)geany(dot)org>
Modified: trunk/plugins/export.c =================================================================== --- trunk/plugins/export.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/plugins/export.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -185,7 +185,7 @@ GtkWidget *check_line_numbers;
check_line_numbers = gtk_check_button_new_with_mnemonic(_("_Insert line numbers")); - ui_widget_set_tooltip_text(check_line_numbers, + gtk_widget_set_tooltip_text(check_line_numbers, _("Insert line numbers before each line in the exported document")); gtk_box_pack_start(GTK_BOX(vbox), check_line_numbers, FALSE, FALSE, 0); gtk_widget_show_all(vbox); @@ -197,7 +197,7 @@ GtkWidget *check_zoom_level;
check_zoom_level = gtk_check_button_new_with_mnemonic(_("_Use current zoom level")); - ui_widget_set_tooltip_text(check_zoom_level, + gtk_widget_set_tooltip_text(check_zoom_level, _("Renders the font size of the document together with the current zoom level")); gtk_box_pack_start(GTK_BOX(vbox), check_zoom_level, FALSE, FALSE, 0); gtk_widget_show_all(vbox);
Modified: trunk/plugins/filebrowser.c =================================================================== --- trunk/plugins/filebrowser.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/plugins/filebrowser.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -866,22 +866,22 @@ gtk_toolbar_set_style(GTK_TOOLBAR(toolbar), GTK_TOOLBAR_ICONS);
wid = GTK_WIDGET(gtk_tool_button_new_from_stock(GTK_STOCK_GO_UP)); - ui_widget_set_tooltip_text(wid, _("Up")); + gtk_widget_set_tooltip_text(wid, _("Up")); g_signal_connect(wid, "clicked", G_CALLBACK(on_go_up), NULL); gtk_container_add(GTK_CONTAINER(toolbar), wid);
wid = GTK_WIDGET(gtk_tool_button_new_from_stock(GTK_STOCK_REFRESH)); - ui_widget_set_tooltip_text(wid, _("Refresh")); + gtk_widget_set_tooltip_text(wid, _("Refresh")); g_signal_connect(wid, "clicked", G_CALLBACK(refresh), NULL); gtk_container_add(GTK_CONTAINER(toolbar), wid);
wid = GTK_WIDGET(gtk_tool_button_new_from_stock(GTK_STOCK_HOME)); - ui_widget_set_tooltip_text(wid, _("Home")); + gtk_widget_set_tooltip_text(wid, _("Home")); g_signal_connect(wid, "clicked", G_CALLBACK(on_go_home), NULL); gtk_container_add(GTK_CONTAINER(toolbar), wid);
wid = GTK_WIDGET(gtk_tool_button_new_from_stock(GTK_STOCK_JUMP_TO)); - ui_widget_set_tooltip_text(wid, _("Set path from document")); + gtk_widget_set_tooltip_text(wid, _("Set path from document")); g_signal_connect(wid, "clicked", G_CALLBACK(on_current_path), NULL); gtk_container_add(GTK_CONTAINER(toolbar), wid);
@@ -891,7 +891,7 @@ gtk_container_add(GTK_CONTAINER(toolbar), wid);
wid = GTK_WIDGET(gtk_tool_button_new_from_stock(GTK_STOCK_CLEAR)); - ui_widget_set_tooltip_text(wid, _("Clear the filter")); + gtk_widget_set_tooltip_text(wid, _("Clear the filter")); g_signal_connect(wid, "clicked", G_CALLBACK(on_clear_filter), NULL); gtk_container_add(GTK_CONTAINER(toolbar), wid); } @@ -915,7 +915,7 @@ ui_entry_add_clear_icon(GTK_ENTRY(filter_entry)); g_signal_connect(filter_entry, "icon-release", G_CALLBACK(on_filter_clear), NULL); } - ui_widget_set_tooltip_text(filter_entry, + gtk_widget_set_tooltip_text(filter_entry, _("Filter your files with the usual wildcards. Separate multiple patterns with a space.")); g_signal_connect(filter_entry, "activate", G_CALLBACK(on_filter_activate), NULL); g_signal_connect(filter_combo, "changed", G_CALLBACK(ui_combo_box_changed), NULL); @@ -1233,7 +1233,7 @@ entry = gtk_entry_new(); if (open_cmd != NULL) gtk_entry_set_text(GTK_ENTRY(entry), open_cmd); - ui_widget_set_tooltip_text(entry, + gtk_widget_set_tooltip_text(entry, _("The command to execute when using "Open with". You can use %f and %d wildcards.\n" "%f will be replaced with the filename including full path\n" "%d will be replaced with the path name of the selected file without the filename")); @@ -1278,7 +1278,7 @@ checkbox_pb = gtk_check_button_new_with_label(_("Use the project's base directory")); gtk_button_set_focus_on_click(GTK_BUTTON(checkbox_pb), FALSE); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(checkbox_pb), fb_set_project_base_path); - ui_widget_set_tooltip_text(checkbox_pb, + gtk_widget_set_tooltip_text(checkbox_pb, _("Change the directory to the base directory of the currently opened project")); gtk_box_pack_start(GTK_BOX(vbox), checkbox_pb, FALSE, FALSE, 0); pref_widgets.set_project_base_path_checkbox = checkbox_pb;
Modified: trunk/plugins/splitwindow.c =================================================================== --- trunk/plugins/splitwindow.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/plugins/splitwindow.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -221,7 +221,7 @@ if (!tooltip) tooltip = label; if (tooltip) - ui_widget_set_tooltip_text(GTK_WIDGET(item), tooltip); + gtk_widget_set_tooltip_text(GTK_WIDGET(item), tooltip);
g_free(dupl); return GTK_WIDGET(item); @@ -268,7 +268,7 @@ tool_item = gtk_menu_tool_button_new(NULL, NULL); gtk_tool_button_set_stock_id(GTK_TOOL_BUTTON(tool_item), GTK_STOCK_JUMP_TO); item = (GtkWidget*)tool_item; - ui_widget_set_tooltip_text(item, _("Show the current document")); + gtk_widget_set_tooltip_text(item, _("Show the current document")); gtk_container_add(GTK_CONTAINER(toolbar), item); g_signal_connect(item, "clicked", G_CALLBACK(on_refresh), NULL);
Modified: trunk/src/build.c =================================================================== --- trunk/src/build.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/build.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -1887,7 +1887,7 @@ { GtkWidget *wid = roww->entries[i] = gtk_button_new(); gtk_button_set_use_underline(GTK_BUTTON(wid), TRUE); - ui_widget_set_tooltip_text(wid, _("Click to set menu item label")); + gtk_widget_set_tooltip_text(wid, _("Click to set menu item label")); g_signal_connect(wid, "clicked", G_CALLBACK(on_label_button_clicked), roww); } else
Modified: trunk/src/dialogs.c =================================================================== --- trunk/src/dialogs.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/dialogs.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -314,7 +314,7 @@ /* the ebox is for the tooltip, because gtk_combo_box can't show tooltips */ encoding_ebox = gtk_event_box_new(); encoding_combo = gtk_combo_box_new(); - ui_widget_set_tooltip_text(encoding_ebox, + gtk_widget_set_tooltip_text(encoding_ebox, _("Explicitly defines an encoding for the file, if it would not be detected. This is useful when you know that the encoding of a file cannot be detected correctly by Geany.\nNote if you choose multiple files, they will all be opened with the chosen encoding.")); gtk_container_add(GTK_CONTAINER(encoding_ebox), encoding_combo); gtk_table_attach(GTK_TABLE(table), encoding_ebox, 3, 4, 0, 1, @@ -331,7 +331,7 @@ filetype_ebox = gtk_event_box_new(); filetype_combo = gtk_combo_box_new_text(); gtk_combo_box_set_wrap_width(GTK_COMBO_BOX(filetype_combo), 2); - ui_widget_set_tooltip_text(filetype_ebox, + gtk_widget_set_tooltip_text(filetype_ebox, _("Explicitly defines a filetype for the file, if it would not be detected by filename extension.\nNote if you choose multiple files, they will all be opened with the chosen filetype.")); gtk_container_add(GTK_CONTAINER(filetype_ebox), filetype_combo); gtk_table_attach(GTK_TABLE(table), filetype_ebox, 3, 4, 1, 2, @@ -366,7 +366,7 @@ gtk_widget_set_name(dialog, "GeanyDialog");
viewbtn = gtk_dialog_add_button(GTK_DIALOG(dialog), _("_View"), GEANY_RESPONSE_VIEW); - ui_widget_set_tooltip_text(viewbtn, + gtk_widget_set_tooltip_text(viewbtn, _("Opens the file in read-only mode. If you choose more than one file to open, all files will be opened read-only."));
gtk_dialog_add_buttons(GTK_DIALOG(dialog), @@ -591,7 +591,7 @@ gtk_widget_set_name(dialog, "GeanyDialog");
rename_btn = gtk_dialog_add_button(GTK_DIALOG(dialog), _("R_ename"), GEANY_RESPONSE_RENAME); - ui_widget_set_tooltip_text(rename_btn, _("Save the file and rename it")); + gtk_widget_set_tooltip_text(rename_btn, _("Save the file and rename it"));
gtk_dialog_add_buttons(GTK_DIALOG(dialog), GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, @@ -601,7 +601,7 @@ vbox = gtk_vbox_new(FALSE, 0); check_open_new_tab = gtk_check_button_new_with_mnemonic(_("_Open file in a new tab")); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(check_open_new_tab), filesel_state.save.open_in_new_tab); - ui_widget_set_tooltip_text(check_open_new_tab, + gtk_widget_set_tooltip_text(check_open_new_tab, _("Keep the current unsaved document open" " and open the newly saved file in a new tab")); gtk_box_pack_start(GTK_BOX(vbox), check_open_new_tab, FALSE, FALSE, 0);
Modified: trunk/src/document.c =================================================================== --- trunk/src/document.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/document.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -336,7 +336,7 @@
gtk_label_set_text(GTK_LABEL(doc->priv->tab_label), short_name);
- ui_widget_set_tooltip_text(parent, DOC_FILENAME(doc)); + gtk_widget_set_tooltip_text(parent, DOC_FILENAME(doc));
g_free(short_name); }
Modified: trunk/src/highlighting.c =================================================================== --- trunk/src/highlighting.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/highlighting.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -3663,7 +3663,7 @@ tooltip = utils_get_setting(locale_string, hkeyfile, skeyfile, "theme_info", "description", NULL); if (tooltip != NULL) { - ui_widget_set_tooltip_text(item, tooltip); + gtk_widget_set_tooltip_text(item, tooltip); g_free(tooltip); } g_free(path);
Modified: trunk/src/printing.c =================================================================== --- trunk/src/printing.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/printing.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -380,17 +380,17 @@
w->check_print_linenumbers = gtk_check_button_new_with_mnemonic(_("Print line numbers")); gtk_box_pack_start(GTK_BOX(page), w->check_print_linenumbers, FALSE, FALSE, 0); - ui_widget_set_tooltip_text(w->check_print_linenumbers, _("Add line numbers to the printed page")); + gtk_widget_set_tooltip_text(w->check_print_linenumbers, _("Add line numbers to the printed page")); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(w->check_print_linenumbers), printing_prefs.print_line_numbers);
w->check_print_pagenumbers = gtk_check_button_new_with_mnemonic(_("Print page numbers")); gtk_box_pack_start(GTK_BOX(page), w->check_print_pagenumbers, FALSE, FALSE, 0); - ui_widget_set_tooltip_text(w->check_print_pagenumbers, _("Add page numbers at the bottom of each page. It takes 2 lines of the page.")); + gtk_widget_set_tooltip_text(w->check_print_pagenumbers, _("Add page numbers at the bottom of each page. It takes 2 lines of the page.")); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(w->check_print_pagenumbers), printing_prefs.print_page_numbers);
w->check_print_pageheader = gtk_check_button_new_with_mnemonic(_("Print page header")); gtk_box_pack_start(GTK_BOX(page), w->check_print_pageheader, FALSE, FALSE, 0); - ui_widget_set_tooltip_text(w->check_print_pageheader, _("Add a little header to every page containing the page number, the filename and the current date (see below). It takes 3 lines of the page.")); + gtk_widget_set_tooltip_text(w->check_print_pageheader, _("Add a little header to every page containing the page number, the filename and the current date (see below). It takes 3 lines of the page.")); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(w->check_print_pageheader), printing_prefs.print_page_header); g_signal_connect(w->check_print_pageheader, "toggled", G_CALLBACK(on_page_header_toggled), w);
@@ -408,7 +408,7 @@
w->check_print_basename = gtk_check_button_new_with_mnemonic(_("Use the basename of the printed file")); gtk_box_pack_start(GTK_BOX(vbox30), w->check_print_basename, FALSE, FALSE, 0); - ui_widget_set_tooltip_text(w->check_print_basename, _("Print only the basename(without the path) of the printed file")); + gtk_widget_set_tooltip_text(w->check_print_basename, _("Print only the basename(without the path) of the printed file")); gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(w->check_print_basename), printing_prefs.page_header_basename);
hbox10 = gtk_hbox_new(FALSE, 5); @@ -420,7 +420,7 @@ w->entry_print_dateformat = gtk_entry_new(); ui_entry_add_clear_icon(GTK_ENTRY(w->entry_print_dateformat)); gtk_box_pack_start(GTK_BOX(hbox10), w->entry_print_dateformat, TRUE, TRUE, 0); - ui_widget_set_tooltip_text(w->entry_print_dateformat, _("Specify a format for the date and time stamp which is added to the page header on each page. You can use any conversion specifiers which can be used with the ANSI C strftime function.")); + gtk_widget_set_tooltip_text(w->entry_print_dateformat, _("Specify a format for the date and time stamp which is added to the page header on each page. You can use any conversion specifiers which can be used with the ANSI C strftime function.")); gtk_entry_set_text(GTK_ENTRY(w->entry_print_dateformat), printing_prefs.page_header_datefmt);
on_page_header_toggled(GTK_TOGGLE_BUTTON(w->check_print_pageheader), w);
Modified: trunk/src/project.c =================================================================== --- trunk/src/project.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/project.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -167,7 +167,7 @@
e->base_path = gtk_entry_new(); ui_entry_add_clear_icon(GTK_ENTRY(e->base_path)); - ui_widget_set_tooltip_text(e->base_path, + gtk_widget_set_tooltip_text(e->base_path, _("Base directory of all files that make up the project. " "This can be a new path, or an existing directory tree. " "You can use paths relative to the project filename.")); @@ -468,7 +468,7 @@
e->base_path = gtk_entry_new(); ui_entry_add_clear_icon(GTK_ENTRY(e->base_path)); - ui_widget_set_tooltip_text(e->base_path, + gtk_widget_set_tooltip_text(e->base_path, _("Base directory of all files that make up the project. " "This can be a new path, or an existing directory tree. " "You can use paths relative to the project filename.")); @@ -496,7 +496,7 @@ gtk_misc_set_alignment(GTK_MISC(label), 0, 0);
e->patterns = gtk_entry_new(); - ui_widget_set_tooltip_text(e->patterns, + gtk_widget_set_tooltip_text(e->patterns, _("Space separated list of file patterns used for the find in files dialog " "(e.g. *.c *.h)")); gtk_table_attach(GTK_TABLE(table), e->patterns, 1, 2, 4, 5,
Modified: trunk/src/search.c =================================================================== --- trunk/src/search.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/search.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -292,7 +292,7 @@ check_regexp = gtk_check_button_new_with_mnemonic(_("_Use regular expressions")); ui_hookup_widget(dialog, check_regexp, "check_regexp"); gtk_button_set_focus_on_click(GTK_BUTTON(check_regexp), FALSE); - ui_widget_set_tooltip_text(check_regexp, _("Use POSIX-like regular expressions. " + gtk_widget_set_tooltip_text(check_regexp, _("Use POSIX-like regular expressions. " "For detailed information about using regular expressions, please read the documentation.")); g_signal_connect(check_regexp, "toggled", G_CALLBACK(on_find_replace_checkbutton_toggled), dialog); @@ -315,7 +315,7 @@ checkbox7 = gtk_check_button_new_with_mnemonic(_("Use _escape sequences")); ui_hookup_widget(dialog, checkbox7, "check_escape"); gtk_button_set_focus_on_click(GTK_BUTTON(checkbox7), FALSE); - ui_widget_set_tooltip_text(checkbox7, + gtk_widget_set_tooltip_text(checkbox7, _("Replace \\, \t, \n, \r and \uXXXX (Unicode chararacters) with the " "corresponding control characters"));
@@ -516,7 +516,7 @@ bbox = gtk_hbutton_box_new();
button = gtk_button_new_with_mnemonic(_("_Mark")); - ui_widget_set_tooltip_text(button, + gtk_widget_set_tooltip_text(button, _("Mark all matches in the current document")); gtk_container_add(GTK_CONTAINER(bbox), button); g_signal_connect(button, "clicked", G_CALLBACK(send_find_dialog_response), @@ -536,7 +536,7 @@ check_close = gtk_check_button_new_with_mnemonic(_("Close _dialog")); ui_hookup_widget(find_dlg.dialog, check_close, "check_close"); gtk_button_set_focus_on_click(GTK_BUTTON(check_close), FALSE); - ui_widget_set_tooltip_text(check_close, + gtk_widget_set_tooltip_text(check_close, _("Disable this option to keep the dialog open")); gtk_container_add(GTK_CONTAINER(bbox), check_close); gtk_button_box_set_child_secondary(GTK_BUTTON_BOX(bbox), check_close, TRUE); @@ -710,7 +710,7 @@ GINT_TO_POINTER(GEANY_RESPONSE_REPLACE_IN_FILE));
button = gtk_button_new_with_mnemonic(_("In Se_lection")); - ui_widget_set_tooltip_text(button, + gtk_widget_set_tooltip_text(button, _("Replace all matches found in the currently selected text")); gtk_container_add(GTK_CONTAINER(bbox), button); g_signal_connect(button, "clicked", G_CALLBACK(send_replace_dialog_response), @@ -720,7 +720,7 @@ check_close = gtk_check_button_new_with_mnemonic(_("Close _dialog")); ui_hookup_widget(replace_dlg.dialog, check_close, "check_close"); gtk_button_set_focus_on_click(GTK_BUTTON(check_close), FALSE); - ui_widget_set_tooltip_text(check_close, + gtk_widget_set_tooltip_text(check_close, _("Disable this option to keep the dialog open")); gtk_container_add(GTK_CONTAINER(bbox), check_close); gtk_button_box_set_child_secondary(GTK_BUTTON_BOX(bbox), check_close, TRUE); @@ -836,7 +836,7 @@
combo = gtk_combo_box_new_with_model(GTK_TREE_MODEL(store)); g_object_unref(store); - ui_widget_set_tooltip_text(combo, _("All: search all files in the directory\n" + gtk_widget_set_tooltip_text(combo, _("All: search all files in the directory\n" "Project: use file patterns defined in the project settings\n" "Custom: specify file patterns manually"));
@@ -915,7 +915,7 @@ entry = gtk_bin_get_child(GTK_BIN(fcombo)); ui_entry_add_clear_icon(GTK_ENTRY(entry)); gtk_entry_set_activates_default(GTK_ENTRY(entry), TRUE); - ui_widget_set_tooltip_text(entry, _("File patterns, e.g. *.c *.h")); + gtk_widget_set_tooltip_text(entry, _("File patterns, e.g. *.c *.h")); ui_hookup_widget(fif_dlg.dialog, entry, "entry_files"); fif_dlg.files_combo = fcombo;
@@ -977,7 +977,7 @@ check_regexp = gtk_check_button_new_with_mnemonic(_("_Use regular expressions")); ui_hookup_widget(fif_dlg.dialog, check_regexp, "check_regexp"); gtk_button_set_focus_on_click(GTK_BUTTON(check_regexp), FALSE); - ui_widget_set_tooltip_text(check_regexp, _("See grep's manual page for more information")); + gtk_widget_set_tooltip_text(check_regexp, _("See grep's manual page for more information"));
check_recursive = gtk_check_button_new_with_mnemonic(_("_Recurse in subfolders")); ui_hookup_widget(fif_dlg.dialog, check_recursive, "check_recursive"); @@ -995,7 +995,7 @@ checkbox2 = gtk_check_button_new_with_mnemonic(_("_Invert search results")); ui_hookup_widget(fif_dlg.dialog, checkbox2, "check_invert"); gtk_button_set_focus_on_click(GTK_BUTTON(checkbox2), FALSE); - ui_widget_set_tooltip_text(checkbox2, + gtk_widget_set_tooltip_text(checkbox2, _("Invert the sense of matching, to select non-matching lines"));
lbox = gtk_vbox_new(FALSE, 0); @@ -1020,7 +1020,7 @@ entry_extra = gtk_entry_new(); ui_entry_add_clear_icon(GTK_ENTRY(entry_extra)); gtk_widget_set_sensitive(entry_extra, FALSE); - ui_widget_set_tooltip_text(entry_extra, _("Other options to pass to Grep")); + gtk_widget_set_tooltip_text(entry_extra, _("Other options to pass to Grep")); ui_hookup_widget(fif_dlg.dialog, entry_extra, "entry_extra");
/* enable entry_extra when check_extra is checked */
Modified: trunk/src/ui_utils.c =================================================================== --- trunk/src/ui_utils.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/ui_utils.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -2190,25 +2190,17 @@
/** - * Sets @a text as the contents of the tooltip for @a widget. + * Sets @a text as the contents of the tooltip for @a widget. * - * @param widget The widget the tooltip should be set for. - * @param text The text for the tooltip. + * @param widget The widget the tooltip should be set for. + * @param text The text for the tooltip. * - * @since 0.16 + * @since 0.16 + * @deprecated 0.21 use gtk_widget_set_tooltip_text() instead */ void ui_widget_set_tooltip_text(GtkWidget *widget, const gchar *text) { -#if GTK_CHECK_VERSION(2, 12, 0) gtk_widget_set_tooltip_text(widget, text); -#else - static GtkTooltips *tooltips = NULL; - - if (G_UNLIKELY(tooltips == NULL)) - tooltips = GTK_TOOLTIPS(ui_lookup_widget(main_widgets.window, "tooltips")); - - gtk_tooltips_set_tip(tooltips, widget, text, NULL); -#endif }
Modified: trunk/src/vte.c =================================================================== --- trunk/src/vte.c 2011-06-13 18:41:15 UTC (rev 5839) +++ trunk/src/vte.c 2011-06-13 18:41:50 UTC (rev 5840) @@ -772,7 +772,7 @@ gtk_table_attach(GTK_TABLE(table), font_term, 1, 2, 0, 1, (GtkAttachOptions) (GTK_EXPAND | GTK_FILL), (GtkAttachOptions) (0), 0, 0); - ui_widget_set_tooltip_text(font_term, _("Sets the font for the terminal widget")); + gtk_widget_set_tooltip_text(font_term, _("Sets the font for the terminal widget"));
label = gtk_label_new(_("Foreground color:")); gtk_table_attach(GTK_TABLE(table), label, 0, 1, 1, 2, @@ -790,14 +790,14 @@ gtk_table_attach(GTK_TABLE(table), color_fore, 1, 2, 1, 2, (GtkAttachOptions) (GTK_FILL), (GtkAttachOptions) (0), 0, 0); - ui_widget_set_tooltip_text(color_fore, _("Sets the foreground color of the text in the terminal widget")); + gtk_widget_set_tooltip_text(color_fore, _("Sets the foreground color of the text in the terminal widget")); gtk_color_button_set_title(GTK_COLOR_BUTTON(color_fore), _("Color Chooser"));
color_back = gtk_color_button_new(); gtk_table_attach(GTK_TABLE(table), color_back, 1, 2, 2, 3, (GtkAttachOptions) (GTK_FILL), (GtkAttachOptions) (0), 0, 0); - ui_widget_set_tooltip_text(color_back, _("Sets the background color of the text in the terminal widget")); + gtk_widget_set_tooltip_text(color_back, _("Sets the background color of the text in the terminal widget")); gtk_color_button_set_title(GTK_COLOR_BUTTON(color_back), _("Color Chooser"));
label = gtk_label_new(_("Scrollback lines:")); @@ -812,7 +812,7 @@ gtk_table_attach(GTK_TABLE(table), spin_scrollback, 1, 2, 3, 4, (GtkAttachOptions) (GTK_EXPAND | GTK_FILL), (GtkAttachOptions) (0), 0, 0); - ui_widget_set_tooltip_text(spin_scrollback, _("Specifies the history in lines, which you can scroll back in the terminal widget")); + gtk_widget_set_tooltip_text(spin_scrollback, _("Specifies the history in lines, which you can scroll back in the terminal widget")); gtk_spin_button_set_numeric(GTK_SPIN_BUTTON(spin_scrollback), TRUE); gtk_spin_button_set_wrap(GTK_SPIN_BUTTON(spin_scrollback), TRUE);
@@ -824,7 +824,7 @@
entry_shell = gtk_entry_new(); ui_entry_add_clear_icon(GTK_ENTRY(entry_shell)); - ui_widget_set_tooltip_text(entry_shell, _("Sets the path to the shell which should be started inside the terminal emulation")); + gtk_widget_set_tooltip_text(entry_shell, _("Sets the path to the shell which should be started inside the terminal emulation"));
button_shell = gtk_button_new(); gtk_widget_show(button_shell); @@ -842,38 +842,38 @@
box = gtk_vbox_new(FALSE, 3); check_scroll_key = gtk_check_button_new_with_mnemonic(_("Scroll on keystroke")); - ui_widget_set_tooltip_text(check_scroll_key, _("Whether to scroll to the bottom if a key was pressed")); + gtk_widget_set_tooltip_text(check_scroll_key, _("Whether to scroll to the bottom if a key was pressed")); gtk_container_add(GTK_CONTAINER(box), check_scroll_key);
check_scroll_out = gtk_check_button_new_with_mnemonic(_("Scroll on output")); - ui_widget_set_tooltip_text(check_scroll_out, _("Whether to scroll to the bottom when output is generated")); + gtk_widget_set_tooltip_text(check_scroll_out, _("Whether to scroll to the bottom when output is generated")); gtk_container_add(GTK_CONTAINER(box), check_scroll_out);
check_cursor_blinks = gtk_check_button_new_with_mnemonic(_("Cursor blinks")); - ui_widget_set_tooltip_text(check_cursor_blinks, _("Whether to blink the cursor")); + gtk_widget_set_tooltip_text(check_cursor_blinks, _("Whether to blink the cursor")); gtk_container_add(GTK_CONTAINER(box), check_cursor_blinks);
check_enable_bash_keys = gtk_check_button_new_with_mnemonic(_("Override Geany keybindings")); - ui_widget_set_tooltip_text(check_enable_bash_keys, + gtk_widget_set_tooltip_text(check_enable_bash_keys, _("Allows the VTE to receive keyboard shortcuts (apart from focus commands)")); gtk_container_add(GTK_CONTAINER(box), check_enable_bash_keys);
check_ignore_menu_key = gtk_check_button_new_with_mnemonic(_("Disable menu shortcut key (F10 by default)")); - ui_widget_set_tooltip_text(check_ignore_menu_key, _("This option disables the keybinding to popup the menu bar (default is F10). Disabling it can be useful if you use, for example, Midnight Commander within the VTE.")); + gtk_widget_set_tooltip_text(check_ignore_menu_key, _("This option disables the keybinding to popup the menu bar (default is F10). Disabling it can be useful if you use, for example, Midnight Commander within the VTE.")); gtk_container_add(GTK_CONTAINER(box), check_ignore_menu_key);
check_follow_path = gtk_check_button_new_with_mnemonic(_("Follow the path of the current file")); - ui_widget_set_tooltip_text(check_follow_path, _("Whether to execute "cd $path" when you switch between opened files")); + gtk_widget_set_tooltip_text(check_follow_path, _("Whether to execute "cd $path" when you switch between opened files")); gtk_container_add(GTK_CONTAINER(box), check_follow_path);
/* create check_skip_script checkbox before the check_skip_script checkbox to be able to * use the object for the toggled handler of check_skip_script checkbox */ check_skip_script = gtk_check_button_new_with_mnemonic(_("Don't use run script")); - ui_widget_set_tooltip_text(check_skip_script, _("Don't use the simple run script which is usually used to display the exit status of the executed program")); + gtk_widget_set_tooltip_text(check_skip_script, _("Don't use the simple run script which is usually used to display the exit status of the executed program")); gtk_widget_set_sensitive(check_skip_script, vc->run_in_vte);
check_run_in_vte = gtk_check_button_new_with_mnemonic(_("Execute programs in VTE")); - ui_widget_set_tooltip_text(check_run_in_vte, _("Run programs in VTE instead of opening a terminal emulation window. Please note, programs executed in VTE cannot be stopped")); + gtk_widget_set_tooltip_text(check_run_in_vte, _("Run programs in VTE instead of opening a terminal emulation window. Please note, programs executed in VTE cannot be stopped")); gtk_container_add(GTK_CONTAINER(box), check_run_in_vte); g_signal_connect(check_run_in_vte, "toggled", G_CALLBACK(check_run_in_vte_toggled), check_skip_script);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.