diff options
author | Thomas White <taw@bitwiz.org.uk> | 2011-11-22 21:04:26 +0100 |
---|---|---|
committer | Thomas White <taw@bitwiz.org.uk> | 2011-11-22 21:04:26 +0100 |
commit | 4c98abb02ad47d13de2694f2bfe2e994f17b3095 (patch) | |
tree | ca3ca222d48f681132b32792a2672c2d8414255a /src/tool_text.c | |
parent | 096fb6d129ded7b7f72bc5b36c932fd84d45ed22 (diff) |
Let tools add stuff to the toolbar
Diffstat (limited to 'src/tool_text.c')
-rw-r--r-- | src/tool_text.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/tool_text.c b/src/tool_text.c index 7b9d377..d011c49 100644 --- a/src/tool_text.c +++ b/src/tool_text.c @@ -732,10 +732,14 @@ static int valid_object(struct object *o) } -static void realise(struct toolinfo *tip, GtkWidget *w) +static void realise(struct toolinfo *ti, GtkWidget *w) { - struct text_toolinfo *ti = (struct text_toolinfo *)tip; - ti->pc = gtk_widget_get_pango_context(w); + struct text_toolinfo *tip = (struct text_toolinfo *)ti; + tip->pc = gtk_widget_get_pango_context(w); + + ti->tbox = gtk_label_new("Text tool"); + g_object_ref(ti->tbox); + gtk_widget_show(ti->tbox); } |