| 1236 void gtk_imhtmltoolbar_associate_smileys(GtkIMHtmlToolbar *toolbar, const char *proto_id) |
1236 void gtk_imhtmltoolbar_associate_smileys(GtkIMHtmlToolbar *toolbar, const char *proto_id) |
| 1237 { |
1237 { |
| 1238 g_free(toolbar->sml); |
1238 g_free(toolbar->sml); |
| 1239 toolbar->sml = g_strdup(proto_id); |
1239 toolbar->sml = g_strdup(proto_id); |
| 1240 } |
1240 } |
| |
1241 g_signal_connect(G_OBJECT(imhtml), "format_function_update", G_CALLBACK(update_format_cb), toolbar); |
| |
1242 g_signal_connect_after(G_OBJECT(GTK_IMHTML(imhtml)->text_buffer), "mark-set", G_CALLBACK(mark_set_cb), toolbar); |
| |
1243 |
| |
1244 buttons = gtk_imhtml_get_format_functions(GTK_IMHTML(imhtml)); |
| |
1245 update_buttons_cb(GTK_IMHTML(imhtml), buttons, toolbar); |
| |
1246 |
| |
1247 gtk_imhtml_get_current_format(GTK_IMHTML(imhtml), &bold, &italic, &underline); |
| |
1248 |
| |
1249 update_buttons(toolbar); |
| |
1250 } |
| |
1251 |
| |
1252 void gtk_imhtmltoolbar_associate_smileys(GtkIMHtmlToolbar *toolbar, const char *proto_id) |
| |
1253 { |
| |
1254 g_free(toolbar->sml); |
| |
1255 toolbar->sml = g_strdup(proto_id); |
| |
1256 } |