comparison src/gtkdebug.c @ 10175:53410b84336f

[gaim-migrate @ 11290] I wrote a helper function that creates the imhtml and toolbar and puts them in a widget and what not. And I changed some places to use this. And I removed some whitespace from log.c. And I changed the conversation colors back to normal. And I'm not committing everything in my tree, so let me know if this doesn't compile. And that's all. committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Sun, 14 Nov 2004 01:52:25 +0000
parents 9fdbfe832fac
children ec140184437b
comparison
equal deleted inserted replaced
10174:8dd4535dd359 10175:53410b84336f
226 debug_window_new(void) 226 debug_window_new(void)
227 { 227 {
228 DebugWindow *win; 228 DebugWindow *win;
229 GtkWidget *vbox; 229 GtkWidget *vbox;
230 GtkWidget *toolbar; 230 GtkWidget *toolbar;
231 GtkWidget *sw; 231 GtkWidget *frame;
232 GtkWidget *button; 232 GtkWidget *button;
233 GtkWidget *image; 233 GtkWidget *image;
234 int width, height; 234 int width, height;
235 235
236 win = g_new0(DebugWindow, 1); 236 win = g_new0(DebugWindow, 1);
297 297
298 gaim_prefs_connect_callback(gaim_gtk_debug_get_handle(), "/gaim/gtk/debug/timestamps", 298 gaim_prefs_connect_callback(gaim_gtk_debug_get_handle(), "/gaim/gtk/debug/timestamps",
299 timestamps_pref_cb, button); 299 timestamps_pref_cb, button);
300 } 300 }
301 301
302 /* Now our scrolled window... */ 302 /* Add the gtkimhtml */
303 sw = gtk_scrolled_window_new(NULL, NULL); 303 frame = gaim_gtk_create_imhtml(FALSE, &win->text, NULL);
304 gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(sw), 304 gtk_box_pack_start(GTK_BOX(vbox), frame, TRUE, TRUE, 0);
305 GTK_POLICY_AUTOMATIC, GTK_POLICY_ALWAYS); 305 gtk_widget_show(frame);
306 gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(sw),
307 GTK_SHADOW_IN);
308
309 /* ... which has a gtkimhtml in it. */
310 win->text = gtk_imhtml_new(NULL, NULL);
311
312 gtk_container_add(GTK_CONTAINER(sw), win->text);
313
314 /* Pack it in... Not like that, sicko. */
315 gtk_box_pack_start(GTK_BOX(vbox), sw, TRUE, TRUE, 0);
316 306
317 gtk_widget_show_all(win->window); 307 gtk_widget_show_all(win->window);
318 308
319 return win; 309 return win;
320 } 310 }