[gimp] app: add missing tooltips in the text style overlay widget
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app: add missing tooltips in the text style overlay widget
- Date: Mon, 14 Mar 2011 12:06:06 +0000 (UTC)
commit 90058cded79d8092d59477d4ab8a411a7adc3d98
Author: Michael Natterer <mitch gimp org>
Date: Mon Mar 14 13:05:30 2011 +0100
app: add missing tooltips in the text style overlay widget
app/widgets/gimptextstyleeditor.c | 26 ++++++++++++++++++++------
1 files changed, 20 insertions(+), 6 deletions(-)
---
diff --git a/app/widgets/gimptextstyleeditor.c b/app/widgets/gimptextstyleeditor.c
index b0c6578..83c3bc3 100644
--- a/app/widgets/gimptextstyleeditor.c
+++ b/app/widgets/gimptextstyleeditor.c
@@ -69,7 +69,8 @@ static void gimp_text_style_editor_get_property (GObject
static GtkWidget * gimp_text_style_editor_create_toggle (GimpTextStyleEditor *editor,
GtkTextTag *tag,
- const gchar *stock_id);
+ const gchar *stock_id,
+ const gchar *tooltip);
static void gimp_text_style_editor_clear_tags (GtkButton *button,
GimpTextStyleEditor *editor);
@@ -188,6 +189,9 @@ gimp_text_style_editor_init (GimpTextStyleEditor *editor)
FALSE, FALSE, 0);
gtk_widget_show (editor->font_entry);
+ gimp_help_set_help_data (editor->font_entry,
+ _("Change font of selected text"), NULL);
+
editor->size_adjustment =
GTK_ADJUSTMENT (gtk_adjustment_new (0.0, 0.0, 1000.0, 1.0, 10.0, 0.0));
editor->size_spinbutton = gtk_spin_button_new (editor->size_adjustment,
@@ -213,6 +217,9 @@ gimp_text_style_editor_init (GimpTextStyleEditor *editor)
FALSE, FALSE, 0);
gtk_widget_show (editor->color_button);
+ gimp_help_set_help_data (editor->color_button,
+ _("Change color of selected text"), NULL);
+
g_signal_connect (editor->color_button, "color-changed",
G_CALLBACK (gimp_text_style_editor_color_changed),
editor);
@@ -301,13 +308,17 @@ gimp_text_style_editor_constructed (GObject *object)
editor->context);
gimp_text_style_editor_create_toggle (editor, editor->buffer->bold_tag,
- GTK_STOCK_BOLD);
+ GTK_STOCK_BOLD,
+ _("Bold"));
gimp_text_style_editor_create_toggle (editor, editor->buffer->italic_tag,
- GTK_STOCK_ITALIC);
+ GTK_STOCK_ITALIC,
+ _("Italic"));
gimp_text_style_editor_create_toggle (editor, editor->buffer->underline_tag,
- GTK_STOCK_UNDERLINE);
+ GTK_STOCK_UNDERLINE,
+ _("Underline"));
gimp_text_style_editor_create_toggle (editor, editor->buffer->strikethrough_tag,
- GTK_STOCK_STRIKETHROUGH);
+ GTK_STOCK_STRIKETHROUGH,
+ _("Strikethrough"));
g_signal_connect_data (editor->buffer, "changed",
G_CALLBACK (gimp_text_style_editor_update),
@@ -499,7 +510,8 @@ gimp_text_style_editor_list_tags (GimpTextStyleEditor *editor,
static GtkWidget *
gimp_text_style_editor_create_toggle (GimpTextStyleEditor *editor,
GtkTextTag *tag,
- const gchar *stock_id)
+ const gchar *stock_id,
+ const gchar *tooltip)
{
GtkWidget *toggle;
GtkWidget *image;
@@ -509,6 +521,8 @@ gimp_text_style_editor_create_toggle (GimpTextStyleEditor *editor,
gtk_box_pack_start (GTK_BOX (editor->lower_hbox), toggle, FALSE, FALSE, 0);
gtk_widget_show (toggle);
+ gimp_help_set_help_data (toggle, tooltip, NULL);
+
editor->toggles = g_list_append (editor->toggles, toggle);
g_object_set_data (G_OBJECT (toggle), "tag", tag);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]