From b89320e2f3d0a8c69dd6ecfd33b125481cd837d8 Mon Sep 17 00:00:00 2001 From: Chris Toshok Date: Thu, 7 Nov 2002 07:38:30 +0000 Subject: port this to gnome2/gnomeprint2. 2002-11-06 Chris Toshok * printing/e-contact-print-envelope.c: port this to gnome2/gnomeprint2. * printing/e-contact-print-style-editor.c: same. * printing/e-contact-print.c: same. * printing/test-contact-print-style-editor.c: same. * printing/test-print.c: same. * printing/e-contact-print.glade: libglade-convert to libglade-2. * printing/Makefile.am (contact_print_test_LDADD) (contact_print_style_editor_test_LDADD): remove libcamel.la from these for the time being to get things linking. svn path=/trunk/; revision=18628 --- addressbook/printing/Makefile.am | 7 +- addressbook/printing/e-contact-print-envelope.c | 51 +- .../printing/e-contact-print-style-editor.c | 4 +- addressbook/printing/e-contact-print.c | 205 +- addressbook/printing/e-contact-print.glade | 4017 ++++++++++---------- .../printing/test-contact-print-style-editor.c | 15 +- addressbook/printing/test-print.c | 13 +- 7 files changed, 2170 insertions(+), 2142 deletions(-) (limited to 'addressbook/printing') diff --git a/addressbook/printing/Makefile.am b/addressbook/printing/Makefile.am index 015069e51b..5455774779 100644 --- a/addressbook/printing/Makefile.am +++ b/addressbook/printing/Makefile.am @@ -43,7 +43,6 @@ contact_print_test_SOURCES = \ contact_print_test_LDADD = \ $(top_builddir)/addressbook/backend/ebook/libebook.la \ - $(top_builddir)/camel/libcamel.la \ $(top_builddir)/e-util/libeutil.la \ $(top_builddir)/libversit/libversit.a \ $(top_builddir)/e-util/ename/libename.la \ @@ -55,13 +54,17 @@ contact_print_style_editor_test_SOURCES = \ contact_print_style_editor_test_LDADD = \ $(top_builddir)/addressbook/backend/ebook/libebook.la \ - $(top_builddir)/camel/libcamel.la \ $(top_builddir)/e-util/libeutil.la \ $(top_builddir)/libversit/libversit.a \ $(top_builddir)/e-util/ename/libename.la \ libecontactprint.a \ $(EVOLUTION_ADDRESSBOOK_LIBS) +# PENDING_PORT_WORK +# from above two LDADD's +# $(top_builddir)/camel/libcamel.la \ + + EXTRA_DIST = \ $(glade_DATA) \ $(ecps_DATA) diff --git a/addressbook/printing/e-contact-print-envelope.c b/addressbook/printing/e-contact-print-envelope.c index 2f65afa81b..ba57f75ae2 100644 --- a/addressbook/printing/e-contact-print-envelope.c +++ b/addressbook/printing/e-contact-print-envelope.c @@ -22,14 +22,12 @@ #include #include "addressbook/printing/e-contact-print-envelope.h" #include -#include #include +#include #include -#include +#include #include -#include #include -#include #include "addressbook/backend/ebook/e-card.h" #include "addressbook/backend/ebook/e-card-simple.h" @@ -148,9 +146,9 @@ ecpe_print(GnomePrintContext *pc, ECard *ecard, gboolean as_return) address = e_card_simple_get(card, E_CARD_SIMPLE_FIELD_ADDRESS_BUSINESS); linelist = ecpe_break(address); if (as_return) - font = gnome_font_new("Helvetica", 9); + font = gnome_font_find ("Helvetica", 9); else - font = gnome_font_new("Helvetica", 12); + font = gnome_font_find ("Helvetica", 12); ecpe_linelist_dimensions(font, address, linelist, NULL, &y); if (as_return) { x = 36; @@ -160,7 +158,7 @@ ecpe_print(GnomePrintContext *pc, ECard *ecard, gboolean as_return) y = (ENVELOPE_HEIGHT - y) / 2; } ecpe_linelist_print(pc, font, address, linelist, x, y); - gtk_object_unref(GTK_OBJECT(font)); + g_object_unref(font); g_free(linelist); g_free(address); @@ -168,7 +166,7 @@ ecpe_print(GnomePrintContext *pc, ECard *ecard, gboolean as_return) gnome_print_showpage(pc); gnome_print_context_close(pc); - gtk_object_unref(GTK_OBJECT(card)); + g_object_unref(card); } static void @@ -176,14 +174,16 @@ e_contact_print_envelope_button(GnomeDialog *dialog, gint button, gpointer data) { GnomePrintMaster *master; GnomePrintContext *pc; + GnomePrintConfig *config; ECard *card = NULL; GtkWidget *preview; - card = gtk_object_get_data(GTK_OBJECT(dialog), "card"); + card = g_object_get_data(G_OBJECT(dialog), "card"); switch( button ) { - case GNOME_PRINT_PRINT: - master = gnome_print_master_new_from_dialog( GNOME_PRINT_DIALOG(dialog) ); + case GNOME_PRINT_DIALOG_RESPONSE_PRINT: + config = gnome_print_dialog_get_config (GNOME_PRINT_DIALOG (dialog)); + master = gnome_print_master_new_from_config (config); pc = gnome_print_master_get_context( master ); ecpe_print(pc, card, FALSE); @@ -191,8 +191,9 @@ e_contact_print_envelope_button(GnomeDialog *dialog, gint button, gpointer data) gnome_print_master_print(master); gnome_dialog_close(dialog); break; - case GNOME_PRINT_PREVIEW: - master = gnome_print_master_new_from_dialog( GNOME_PRINT_DIALOG(dialog) ); + case GNOME_PRINT_DIALOG_RESPONSE_PREVIEW: + config = gnome_print_dialog_get_config (GNOME_PRINT_DIALOG (dialog)); + master = gnome_print_master_new_from_config (config); pc = gnome_print_master_get_context( master ); ecpe_print(pc, card, FALSE); @@ -200,8 +201,8 @@ e_contact_print_envelope_button(GnomeDialog *dialog, gint button, gpointer data) preview = GTK_WIDGET(gnome_print_master_preview_new(master, "Print Preview")); gtk_widget_show_all(preview); break; - case GNOME_PRINT_CANCEL: - gtk_object_unref(GTK_OBJECT(card)); + case GNOME_PRINT_DIALOG_RESPONSE_CANCEL: + g_object_unref(card); gnome_dialog_close(dialog); break; } @@ -215,11 +216,11 @@ e_contact_print_envelope_dialog_new(ECard *card) dialog = gnome_print_dialog_new(_("Print envelope"), GNOME_PRINT_DIALOG_COPIES); card = e_card_duplicate(card); - gtk_object_set_data(GTK_OBJECT(dialog), "card", card); - gtk_signal_connect(GTK_OBJECT(dialog), - "clicked", GTK_SIGNAL_FUNC(e_contact_print_envelope_button), NULL); - gtk_signal_connect(GTK_OBJECT(dialog), - "close", GTK_SIGNAL_FUNC(e_contact_print_envelope_close), NULL); + g_object_set_data(G_OBJECT(dialog), "card", card); + g_signal_connect(dialog, + "clicked", G_CALLBACK(e_contact_print_envelope_button), NULL); + g_signal_connect(dialog, + "close", G_CALLBACK(e_contact_print_envelope_close), NULL); return dialog; } @@ -236,10 +237,10 @@ e_contact_print_envelope_list_dialog_new(GList *list) dialog = gnome_print_dialog_new(_("Print envelope"), GNOME_PRINT_DIALOG_COPIES); card = e_card_duplicate(list->data); - gtk_object_set_data(GTK_OBJECT(dialog), "card", card); - gtk_signal_connect(GTK_OBJECT(dialog), - "clicked", GTK_SIGNAL_FUNC(e_contact_print_envelope_button), NULL); - gtk_signal_connect(GTK_OBJECT(dialog), - "close", GTK_SIGNAL_FUNC(e_contact_print_envelope_close), NULL); + g_object_set_data(G_OBJECT(dialog), "card", card); + g_signal_connect(dialog, + "clicked", G_CALLBACK(e_contact_print_envelope_button), NULL); + g_signal_connect(dialog, + "close", G_CALLBACK(e_contact_print_envelope_close), NULL); return dialog; } diff --git a/addressbook/printing/e-contact-print-style-editor.c b/addressbook/printing/e-contact-print-style-editor.c index f05a508ed8..9267fc0c99 100644 --- a/addressbook/printing/e-contact-print-style-editor.c +++ b/addressbook/printing/e-contact-print-style-editor.c @@ -101,7 +101,7 @@ e_contact_print_style_editor_init (EContactPrintStyleEditor *e_contact_print_sty GladeXML *gui; /* e_contact_print_style_editor->card = NULL;*/ - gui = glade_xml_new (EVOLUTION_GLADEDIR "/e-contact-print.glade", NULL); + gui = glade_xml_new (EVOLUTION_GLADEDIR "/e-contact-print.glade", NULL, NULL); e_contact_print_style_editor->gui = gui; gtk_widget_reparent(glade_xml_get_widget(gui, "vbox-contact-print-style-editor"), GTK_WIDGET(e_contact_print_style_editor)); @@ -111,7 +111,7 @@ void e_contact_print_style_editor_destroy (GtkObject *object) { EContactPrintStyleEditor *e_contact_print_style_editor = E_CONTACT_PRINT_STYLE_EDITOR(object); - gtk_object_unref(GTK_OBJECT(e_contact_print_style_editor->gui)); + g_object_unref(e_contact_print_style_editor->gui); } GtkWidget* diff --git a/addressbook/printing/e-contact-print.c b/addressbook/printing/e-contact-print.c index 55b5480c6f..9ef1d51bc8 100644 --- a/addressbook/printing/e-contact-print.c +++ b/addressbook/printing/e-contact-print.c @@ -26,20 +26,17 @@ #include #include #include -#include -#include -#include +#include +#include +#include #include -#include #include -#include +#include #include -#include +#include #include -#include -#include -#include -#include +#include +#include #include #include #include @@ -417,9 +414,9 @@ e_contact_get_card_size(ECardSimple *simple, EContactPrintContext *ctxt) height += gnome_font_get_size (ctxt->style->headings_font) * .2; - gtk_object_get(GTK_OBJECT(simple->card), - "file_as", &file_as, - NULL); + g_object_get(simple->card, + "file_as", &file_as, + NULL); height += e_contact_text_height(ctxt->pc, ctxt->style->headings_font, column_width - 4, file_as); height += gnome_font_get_size (ctxt->style->headings_font) * .2; @@ -462,9 +459,9 @@ e_contact_print_card (ECardSimple *simple, EContactPrintContext *ctxt) ctxt->y -= gnome_font_get_size (ctxt->style->headings_font) * .2; - gtk_object_get(GTK_OBJECT(simple->card), - "file_as", &file_as, - NULL); + g_object_get(simple->card, + "file_as", &file_as, + NULL); if (ctxt->style->print_using_grey) e_contact_rectangle(ctxt->pc, ctxt->x, ctxt->y + gnome_font_get_size (ctxt->style->headings_font) * .3, ctxt->x + column_width, ctxt->y - e_contact_text_height(ctxt->pc, ctxt->style->headings_font, column_width - 4, file_as) - gnome_font_get_size (ctxt->style->headings_font) * .3, .85, .85, .85); e_contact_output(ctxt->pc, ctxt->style->headings_font, ctxt->x + 2, ctxt->y, column_width - 4, file_as); @@ -483,7 +480,7 @@ e_contact_print_card (ECardSimple *simple, EContactPrintContext *ctxt) gchar *new_string = g_strdup (e_destination_get_address (dest)); g_free (string); string = new_string; - gtk_object_unref (GTK_OBJECT (dest)); + g_object_unref (dest); } } @@ -543,9 +540,9 @@ complete_sequence(EBookView *book_view, EBookViewStatus status, EContactPrintCon guchar *file_as; gchar *letter_str = NULL; - gtk_object_get(GTK_OBJECT(card), - "file_as", &file_as, - NULL); + g_object_get(card, + "file_as", &file_as, + NULL); if (file_as != NULL) { letter_str = g_strndup (file_as, g_utf8_next_char (file_as) - (gchar *) file_as); } @@ -572,7 +569,7 @@ complete_sequence(EBookView *book_view, EBookViewStatus status, EContactPrintCon ctxt->first_char_on_page = ctxt->last_char_on_page; e_contact_print_card(simple, ctxt); ctxt->first_contact = FALSE; - gtk_object_unref(GTK_OBJECT(simple)); + g_object_unref(simple); } ctxt->last_char_on_page = 'Z'; if ( ctxt->style->letter_tabs ) @@ -581,27 +578,27 @@ complete_sequence(EBookView *book_view, EBookViewStatus status, EContactPrintCon gnome_print_context_close(ctxt->pc); g_free(ctxt->character); if (book_view) - gtk_object_unref(GTK_OBJECT(book_view)); - if (ctxt->type == GNOME_PRINT_PREVIEW) { + g_object_unref(book_view); + if (ctxt->type == GNOME_PRINT_DIALOG_RESPONSE_PREVIEW) { GtkWidget *preview; preview = GTK_WIDGET(gnome_print_master_preview_new(ctxt->master, "Print Preview")); gtk_widget_show_all(preview); } else { gnome_print_master_print(ctxt->master); } - gtk_object_unref(GTK_OBJECT(ctxt->pc)); - gtk_object_unref(GTK_OBJECT(ctxt->master)); + g_object_unref(ctxt->pc); + g_object_unref(ctxt->master); if (ctxt->book) - gtk_object_unref(GTK_OBJECT(ctxt->book)); + g_object_unref(ctxt->book); g_free(ctxt->query); - g_list_foreach(ctxt->cards, (GFunc) gtk_object_unref, NULL); + g_list_foreach(ctxt->cards, (GFunc) g_object_unref, NULL); g_list_free(ctxt->cards); - gtk_object_unref(GTK_OBJECT(ctxt->style->headings_font)); - gtk_object_unref(GTK_OBJECT(ctxt->style->body_font)); - gtk_object_unref(GTK_OBJECT(ctxt->style->header_font)); - gtk_object_unref(GTK_OBJECT(ctxt->style->footer_font)); - gtk_object_unref(GTK_OBJECT(ctxt->letter_heading_font)); - gtk_object_unref(GTK_OBJECT(ctxt->letter_tab_font)); + g_object_unref(ctxt->style->headings_font); + g_object_unref(ctxt->style->body_font); + g_object_unref(ctxt->style->header_font); + g_object_unref(ctxt->style->footer_font); + g_object_unref(ctxt->letter_heading_font); + g_object_unref(ctxt->letter_tab_font); g_free(ctxt->style); g_free(ctxt); } @@ -610,12 +607,12 @@ static int card_compare (ECard *card1, ECard *card2) { if (card1 && card2) { char *file_as1, *file_as2; - gtk_object_get(GTK_OBJECT(card1), - "file_as", &file_as1, - NULL); - gtk_object_get(GTK_OBJECT(card2), - "file_as", &file_as2, - NULL); + g_object_get(card1, + "file_as", &file_as1, + NULL); + g_object_get(card2, + "file_as", &file_as2, + NULL); if (file_as1 && file_as2) return g_utf8_collate(file_as1, file_as2); if (file_as1) @@ -633,7 +630,7 @@ create_card(EBookView *book_view, const GList *cards, EContactPrintContext *ctxt { for(; cards; cards = cards->next) { ECard *card = cards->data; - gtk_object_ref(GTK_OBJECT(card)); + g_object_ref(card); ctxt->cards = g_list_insert_sorted(ctxt->cards, card, (GCompareFunc) card_compare); } } @@ -641,17 +638,17 @@ create_card(EBookView *book_view, const GList *cards, EContactPrintContext *ctxt static void book_view_loaded (EBook *book, EBookStatus status, EBookView *book_view, EContactPrintContext *ctxt) { - gtk_object_ref(GTK_OBJECT(book_view)); + g_object_ref(book_view); - gtk_signal_connect(GTK_OBJECT(book_view), - "card_added", - GTK_SIGNAL_FUNC(create_card), - ctxt); + g_signal_connect(book_view, + "card_added", + G_CALLBACK(create_card), + ctxt); - gtk_signal_connect(GTK_OBJECT(book_view), - "sequence_complete", - GTK_SIGNAL_FUNC(complete_sequence), - ctxt); + g_signal_connect(book_view, + "sequence_complete", + G_CALLBACK(complete_sequence), + ctxt); } static void @@ -855,9 +852,9 @@ static double get_float( char *data ) static void get_font( char *data, GnomeFont **variable ) { if ( data ) { - GnomeFont *font = gnome_font_new_from_full_name( data ); + GnomeFont *font = gnome_font_find_from_full_name( data ); if ( font ) { - gtk_object_unref( GTK_OBJECT(*variable) ); + g_object_unref(*variable); *variable = font; } } @@ -869,6 +866,7 @@ e_contact_build_style(EContactPrintStyle *style) { xmlDocPtr styledoc; gchar *filename; + style->title = g_strdup(""); style->type = E_CONTACT_PRINT_TYPE_CARDS; style->sections_start_new_page = TRUE; @@ -877,8 +875,8 @@ e_contact_build_style(EContactPrintStyle *style) style->letter_tabs = TRUE; style->letter_headings = FALSE; - style->headings_font = gnome_font_new_closest("Helvetica", GNOME_FONT_BOLD, FALSE, 8); - style->body_font = gnome_font_new_closest("Helvetica", GNOME_FONT_BOOK, FALSE, 6); + style->headings_font = gnome_font_find_closest_from_weight_slant ("Helvetica", GNOME_FONT_BOLD, FALSE, 8); + style->body_font = gnome_font_find_closest_from_weight_slant ("Helvetica", GNOME_FONT_BOOK, FALSE, 6); style->print_using_grey = TRUE; style->paper_type = 0; @@ -902,13 +900,13 @@ e_contact_build_style(EContactPrintStyle *style) #endif style->orientation_portrait = FALSE; - style->header_font = gnome_font_new_closest("Helvetica", GNOME_FONT_BOOK, FALSE, 6); + style->header_font = gnome_font_find_closest_from_weight_slant ("Helvetica", GNOME_FONT_BOOK, FALSE, 6); style->left_header = g_strdup(""); style->center_header = g_strdup(""); style->right_header = g_strdup(""); - style->footer_font = gnome_font_new_closest("Helvetica", GNOME_FONT_BOOK, FALSE, 6); + style->footer_font = gnome_font_find_closest_from_weight_slant ("Helvetica", GNOME_FONT_BOOK, FALSE, 6); style->left_footer = g_strdup(""); style->center_footer = g_strdup(""); @@ -920,7 +918,7 @@ e_contact_build_style(EContactPrintStyle *style) if (styledoc) { xmlNodePtr stylenode = xmlDocGetRootElement(styledoc); xmlNodePtr node; - for (node = stylenode->childs; node; node = node->next) { + for (node = stylenode->children; node; node = node->next) { char *data = xmlNodeGetContent ( node ); if ( !strcmp( node->name, "title" ) ) { get_string(data, &(style->title)); @@ -1009,21 +1007,25 @@ e_contact_print_button(GnomeDialog *dialog, gint button, gpointer data) EContactPrintContext *ctxt = g_new(EContactPrintContext, 1); EContactPrintStyle *style = g_new(EContactPrintStyle, 1); GnomePrintMaster *master; + GnomePrintConfig *config; GnomePrintContext *pc; - gboolean uses_book = (gint) gtk_object_get_data(GTK_OBJECT(dialog), "uses_book"); + gboolean uses_book = (gint) g_object_get_data(G_OBJECT(dialog), "uses_book"); EBook *book = NULL; char *query = NULL; ECard *card = NULL; gdouble font_size; + + if (uses_book) { - book = gtk_object_get_data(GTK_OBJECT(dialog), "book"); - query = gtk_object_get_data(GTK_OBJECT(dialog), "query"); + book = g_object_get_data(G_OBJECT(dialog), "book"); + query = g_object_get_data(G_OBJECT(dialog), "query"); } else { - card = gtk_object_get_data(GTK_OBJECT(dialog), "card"); + card = g_object_get_data(G_OBJECT(dialog), "card"); } switch( button ) { - case GNOME_PRINT_PRINT: - master = gnome_print_master_new_from_dialog( GNOME_PRINT_DIALOG(dialog) ); + case GNOME_PRINT_DIALOG_RESPONSE_PRINT: + config = gnome_print_dialog_get_config (GNOME_PRINT_DIALOG(dialog)); + master = gnome_print_master_new_from_config( config ); pc = gnome_print_master_get_context( master ); e_contact_build_style(style); @@ -1034,11 +1036,11 @@ e_contact_print_button(GnomeDialog *dialog, gint button, gpointer data) ctxt->master = master; ctxt->first_section = TRUE; ctxt->first_char_on_page = 'A' - 1; - ctxt->type = GNOME_PRINT_PRINT; + ctxt->type = GNOME_PRINT_DIALOG_RESPONSE_PRINT; font_size = 72 * ctxt->style->page_height / 27.0 / 2.0; - ctxt->letter_heading_font = gnome_font_new(gnome_font_get_name(ctxt->style->headings_font), gnome_font_get_size (ctxt->style->headings_font) * 1.5); - ctxt->letter_tab_font = gnome_font_new(gnome_font_get_name(ctxt->style->headings_font), font_size); + ctxt->letter_heading_font = gnome_font_find (gnome_font_get_name(ctxt->style->headings_font), gnome_font_get_size (ctxt->style->headings_font) * 1.5); + ctxt->letter_tab_font = gnome_font_find (gnome_font_get_name(ctxt->style->headings_font), font_size); ctxt->pc = GNOME_PRINT_CONTEXT(gnome_print_multipage_new_from_sizes(pc, 72 * style->paper_width, @@ -1057,8 +1059,9 @@ e_contact_print_button(GnomeDialog *dialog, gint button, gpointer data) } gnome_dialog_close(dialog); break; - case GNOME_PRINT_PREVIEW: - master = gnome_print_master_new_from_dialog( GNOME_PRINT_DIALOG(dialog) ); + case GNOME_PRINT_DIALOG_RESPONSE_PREVIEW: + config = gnome_print_dialog_get_config (GNOME_PRINT_DIALOG(dialog)); + master = gnome_print_master_new_from_config( config ); pc = gnome_print_master_get_context( master ); e_contact_build_style(style); @@ -1069,11 +1072,11 @@ e_contact_print_button(GnomeDialog *dialog, gint button, gpointer data) ctxt->master = master; ctxt->first_section = TRUE; ctxt->first_char_on_page = 'A' - 1; - ctxt->type = GNOME_PRINT_PREVIEW; + ctxt->type = GNOME_PRINT_DIALOG_RESPONSE_PREVIEW; font_size = 72 * ctxt->style->page_height / 27.0 / 2.0; - ctxt->letter_heading_font = gnome_font_new(gnome_font_get_name(ctxt->style->headings_font), gnome_font_get_size (ctxt->style->headings_font) * 1.5); - ctxt->letter_tab_font = gnome_font_new(gnome_font_get_name(ctxt->style->headings_font), font_size); + ctxt->letter_heading_font = gnome_font_find (gnome_font_get_name(ctxt->style->headings_font), gnome_font_get_size (ctxt->style->headings_font) * 1.5); + ctxt->letter_tab_font = gnome_font_find (gnome_font_get_name(ctxt->style->headings_font), font_size); ctxt->pc = GNOME_PRINT_CONTEXT(gnome_print_multipage_new_from_sizes(pc, 72 * style->paper_width, @@ -1085,19 +1088,19 @@ e_contact_print_button(GnomeDialog *dialog, gint button, gpointer data) ctxt->query = g_strdup(query); if (uses_book) { ctxt->cards = NULL; - gtk_object_ref(GTK_OBJECT(book)); + g_object_ref(book); e_contact_do_print(book, ctxt->query, ctxt); } else { ctxt->cards = g_list_append(NULL, card); - gtk_object_ref(GTK_OBJECT(card)); + g_object_ref(card); complete_sequence(NULL, E_BOOK_VIEW_STATUS_SUCCESS, ctxt); } break; - case GNOME_PRINT_CANCEL: + case GNOME_PRINT_DIALOG_RESPONSE_CANCEL: if (uses_book) - gtk_object_unref(GTK_OBJECT(book)); + g_object_unref(book); else - gtk_object_unref(GTK_OBJECT(card)); + g_object_unref(card); g_free(query); gnome_dialog_close(dialog); g_free(style); @@ -1116,14 +1119,14 @@ e_contact_print_dialog_new(EBook *book, char *query) gnome_print_dialog_construct_range_any(GNOME_PRINT_DIALOG(dialog), GNOME_PRINT_RANGE_ALL | GNOME_PRINT_RANGE_SELECTION, NULL, NULL, NULL); - gtk_object_ref(GTK_OBJECT(book)); - gtk_object_set_data(GTK_OBJECT(dialog), "uses_book", (void *) 1); - gtk_object_set_data(GTK_OBJECT(dialog), "book", book); - gtk_object_set_data(GTK_OBJECT(dialog), "query", g_strdup(query)); - gtk_signal_connect(GTK_OBJECT(dialog), - "clicked", GTK_SIGNAL_FUNC(e_contact_print_button), NULL); - gtk_signal_connect(GTK_OBJECT(dialog), - "close", GTK_SIGNAL_FUNC(e_contact_print_close), NULL); + g_object_ref(book); + g_object_set_data(G_OBJECT(dialog), "uses_book", (void *) 1); + g_object_set_data(G_OBJECT(dialog), "book", book); + g_object_set_data(G_OBJECT(dialog), "query", g_strdup(query)); + g_signal_connect(dialog, + "clicked", G_CALLBACK(e_contact_print_button), NULL); + g_signal_connect(dialog, + "close", G_CALLBACK(e_contact_print_close), NULL); return dialog; } @@ -1134,10 +1137,12 @@ e_contact_print_preview(EBook *book, char *query) EContactPrintStyle *style = g_new(EContactPrintStyle, 1); GnomePrintMaster *master; GnomePrintContext *pc; + GnomePrintConfig *config; gdouble font_size; master = gnome_print_master_new(); - gnome_print_master_set_copies (master, 1, FALSE); + config = gnome_print_master_get_config (master); + gnome_print_config_set_int (config, GNOME_PRINT_KEY_NUM_COPIES, 1); pc = gnome_print_master_get_context (master); e_contact_build_style (style); @@ -1148,11 +1153,11 @@ e_contact_print_preview(EBook *book, char *query) ctxt->master = master; ctxt->first_section = TRUE; ctxt->first_char_on_page = 'A' - 1; - ctxt->type = GNOME_PRINT_PREVIEW; + ctxt->type = GNOME_PRINT_DIALOG_RESPONSE_PREVIEW; font_size = 72 * ctxt->style->page_height / 27.0 / 2.0; - ctxt->letter_heading_font = gnome_font_new(gnome_font_get_name(ctxt->style->headings_font), gnome_font_get_size (ctxt->style->headings_font) * 1.5); - ctxt->letter_tab_font = gnome_font_new(gnome_font_get_name(ctxt->style->headings_font), font_size); + ctxt->letter_heading_font = gnome_font_find (gnome_font_get_name(ctxt->style->headings_font), gnome_font_get_size (ctxt->style->headings_font) * 1.5); + ctxt->letter_tab_font = gnome_font_find (gnome_font_get_name(ctxt->style->headings_font), font_size); ctxt->pc = GNOME_PRINT_CONTEXT(gnome_print_multipage_new_from_sizes(pc, 72 * style->paper_width, @@ -1163,7 +1168,7 @@ e_contact_print_preview(EBook *book, char *query) ctxt->book = book; ctxt->query = g_strdup(query); ctxt->cards = NULL; - gtk_object_ref(GTK_OBJECT(book)); + g_object_ref(book); e_contact_do_print(book, ctxt->query, ctxt); } @@ -1175,12 +1180,12 @@ e_contact_print_card_dialog_new(ECard *card) dialog = gnome_print_dialog_new(_("Print card"), GNOME_PRINT_DIALOG_COPIES); card = e_card_duplicate(card); - gtk_object_set_data(GTK_OBJECT(dialog), "card", card); - gtk_object_set_data(GTK_OBJECT(dialog), "uses_book", (void *) 0); - gtk_signal_connect(GTK_OBJECT(dialog), - "clicked", GTK_SIGNAL_FUNC(e_contact_print_button), NULL); - gtk_signal_connect(GTK_OBJECT(dialog), - "close", GTK_SIGNAL_FUNC(e_contact_print_close), NULL); + g_object_set_data(G_OBJECT(dialog), "card", card); + g_object_set_data(G_OBJECT(dialog), "uses_book", (void *) 0); + g_signal_connect(dialog, + "clicked", G_CALLBACK(e_contact_print_button), NULL); + g_signal_connect(dialog, + "close", G_CALLBACK(e_contact_print_close), NULL); return dialog; } @@ -1197,11 +1202,11 @@ e_contact_print_card_list_dialog_new(GList *list) dialog = gnome_print_dialog_new(_("Print card"), GNOME_PRINT_DIALOG_COPIES); card = e_card_duplicate(list->data); - gtk_object_set_data(GTK_OBJECT(dialog), "card", card); - gtk_object_set_data(GTK_OBJECT(dialog), "uses_book", (void *) 0); - gtk_signal_connect(GTK_OBJECT(dialog), - "clicked", GTK_SIGNAL_FUNC(e_contact_print_button), NULL); - gtk_signal_connect(GTK_OBJECT(dialog), - "close", GTK_SIGNAL_FUNC(e_contact_print_close), NULL); + g_object_set_data(G_OBJECT(dialog), "card", card); + g_object_set_data(G_OBJECT(dialog), "uses_book", (void *) 0); + g_signal_connect(dialog, + "clicked", G_CALLBACK(e_contact_print_button), NULL); + g_signal_connect(dialog, + "close", G_CALLBACK(e_contact_print_close), NULL); return dialog; } diff --git a/addressbook/printing/e-contact-print.glade b/addressbook/printing/e-contact-print.glade index 292fc8cc85..d1721e3509 100644 --- a/addressbook/printing/e-contact-print.glade +++ b/addressbook/printing/e-contact-print.glade @@ -1,2003 +1,2018 @@ - - - - - Printing - printing - - - pixmaps - C - False - False - False - False - False - - - - GnomeDialog - print-edit-style - False - Page Setup: - GTK_WINDOW_TOPLEVEL - GTK_WIN_POS_NONE - False - False - False - False - False - False - - - GtkVBox - GnomeDialog:vbox - dialog-vbox1 - False - 8 - - 4 - True - True - - - - GtkHButtonBox - GnomeDialog:action_area - dialog-action_area1 - GTK_BUTTONBOX_END - 8 - 85 - 27 - 7 - 0 - - 0 - False - True - GTK_PACK_END - - - - GtkButton - button1 - True - True - GNOME_STOCK_BUTTON_OK - - - - GtkButton - button2 - True - True - GNOME_STOCK_BUTTON_APPLY - - - - GtkButton - button3 - True - True - GNOME_STOCK_BUTTON_CANCEL + + + + + + no + Page Setup: + GTK_WINDOW_TOPLEVEL + no + no + no + GTK_WIN_POS_NONE + + + + no + 8 + yes + + + + GTK_BUTTONBOX_END + 8 + yes + + + + yes + yes + yes + gtk-ok + yes + yes + + + + + + yes + yes + yes + gtk-apply + yes + yes + + + + + + yes + yes + yes + gtk-cancel + yes + yes + + + + + 0 + no + yes + GTK_PACK_END + + + + + + no + 5 + yes + + + + 5 + no + 16 + yes + + + + Style name: + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + no + + 0 + yes + yes + + + 0 + no + no + + + + + 0 + yes + yes + + + + + + yes + yes + yes + GTK_POS_TOP + no + 2 + 2 + no + yes + + + + 5 + no + 5 + yes + + + + 0.5 + 0.5 + 0 + 0 + yes + + + + Preview: + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + + + + + + 0 + yes + yes + + + + + + yes + 7 + yes + + + + Options + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + 0 + 0 + 0 + 0 + yes + + + + 8 + no + 0 + 0 + 6 + 5 + yes + + + + Include: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + 1 + 4 + 5 + 0 + 0 + fill + fill + + + + + + Sections: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + 1 + 0 + 1 + 0 + 0 + fill + fill + + + + + + 0 + 0.5 + 0 + 0 + yes + + + + yes + Immediately follow each other + yes + yes + yes + + + + + 1 + 5 + 0 + 1 + 0 + 0 + fill + fill + + + + + + yes + Letter tabs on side + no + yes + yes + + + 1 + 5 + 4 + 5 + 0 + 0 + fill + fill + + + + + + yes + Headings for each letter + no + yes + yes + + + 1 + 5 + 5 + 6 + 0 + 0 + fill + fill + + + + + + 0 + 0.5 + 0 + 0 + yes + + + + yes + Start on a new page + no + yes + yes + + + + + 1 + 5 + 1 + 2 + 0 + 0 + fill + fill + + + + + + Number of columns: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + 3 + 2 + 3 + 0 + 2 + fill + fill + + + + + + Blank forms at end: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + 3 + 3 + 4 + 0 + 2 + fill + fill + + + + + + 0 + 0.5 + 0 + 0 + yes + + + + yes + 1 + 0 + no + GTK_UPDATE_ALWAYS + no + no + yes + 2 0 100 1 10 10 + + + + + 3 + 4 + 3 + 4 + 0 + 2 + fill + fill + + + + + + 0 + 0.5 + 0 + 0 + yes + + + + yes + 1 + 0 + no + GTK_UPDATE_ALWAYS + no + 45 + no + yes + 1 0 100 1 10 10 + + + + + 3 + 4 + 2 + 3 + 0 + 2 + fill + fill + + + + + + + + + 0 + yes + yes + + + + + + no + 8 + yes + + + + Fonts + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + 8 + no + 13 + 8 + 2 + 2 + yes + + + + 0.5 + 1 + 1 + 0 + yes + + + + yes + F_ont... + GTK_RELIEF_NORMAL + yes + yes + + + + + 1 + 2 + 1 + 2 + 0 + 0 + fill + fill + + + + + + 0.5 + 1 + 1 + 0 + yes + + + + yes + _Font... + GTK_RELIEF_NORMAL + 90 + yes + yes + + + + + 1 + 2 + 0 + 1 + 0 + 0 + fill + fill + + + + + + no + 0 + yes + + + + Headings + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + yes + 10 pt. Tahoma + 100 + 0 + yes + yes + + + 0 + no + no + + + + + 0 + 1 + 0 + 1 + 0 + 0 + expand|fill + fill + + + + + + no + 0 + yes + + + + Body + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + yes + 8 pt. Tahoma + 100 + 0 + yes + yes + + + 0 + no + no + + + + + 0 + 1 + 1 + 2 + 0 + 0 + expand|fill + fill + + + + + + + 0 + yes + yes + + + + + + Shading + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + yes + Print using gray shading + no + yes + yes + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + + + + Format + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + tab + + + + + + yes + 0 + yes + + + + no + 0 + yes + + + + Paper + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + 10 + no + 0 + yes + + + + no + 0 + yes + + + + Type: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + GTK_POLICY_ALWAYS + GTK_POLICY_ALWAYS + GTK_SHADOW_IN + yes + + + + yes + no + yes + + + + CList:title + label26 + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + + + + + + GTK_UPDATE_CONTINUOUS + yes + + + + + + GTK_UPDATE_CONTINUOUS + yes + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + + no + 0 + yes + + + + Dimensions: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + 0 + yes + + + + Width: + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + yes + + 1 + 0 + yes + yes + + + 0 + yes + yes + + + + + + Height: + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + yes + + 1 + 0 + yes + yes + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + + no + 0 + yes + + + + Paper source: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + no + no + yes + no + yes + yes + + + + yes + yes + + 0 + yes + yes + + + + + + yes + + + + yes + + + + + 0.0 + yes + + + + + + + + + 0 + no + no + + + + + 0 + yes + yes + + + + + + + 0 + yes + yes + + + + + + Margins + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + 15 + yes + 6 + 9 + 2 + 4 + yes + + + + Top: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + 1 + 0 + 1 + 0 + 0 + fill + expand|fill + + + + + + Bottom: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + 1 + 1 + 2 + 0 + 0 + fill + expand|fill + + + + + + Left: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 2 + 3 + 0 + 1 + 0 + 0 + fill + expand|fill + + + + + + yes + yes + + 1 + 0 + yes + yes + + + 1 + 2 + 0 + 1 + 0 + 0 + expand|fill + + + + + + + yes + yes + + 1 + 0 + yes + yes + + + 3 + 4 + 0 + 1 + 0 + 0 + expand|fill + + + + + + + yes + yes + + 1 + 0 + yes + yes + + + 3 + 4 + 1 + 2 + 0 + 0 + expand|fill + + + + + + + yes + yes + + 1 + 0 + yes + yes + + + 1 + 2 + 1 + 2 + 0 + 0 + expand|fill + + + + + + + Right: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 2 + 3 + 1 + 2 + 0 + 0 + fill + expand|fill + + + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + + no + 0 + yes + + + + Page + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + 10 + no + 0 + yes + + + + no + 0 + yes + + + + Size: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + GTK_POLICY_ALWAYS + GTK_POLICY_ALWAYS + GTK_SHADOW_IN + yes + + + + yes + no + yes + + + + CList:title + label26 + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + + + + + + GTK_UPDATE_CONTINUOUS + yes + + + + + + GTK_UPDATE_CONTINUOUS + yes + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + + no + 0 + yes + + + + Dimensions: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + 0 + yes + + + + Width: + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + yes + + 1 + 0 + yes + yes + + + 0 + yes + yes + + + + + + Height: + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + yes + + 1 + 0 + yes + yes + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + + + 0 + yes + yes + + + + + + Orientation + 0 + GTK_SHADOW_ETCHED_IN + yes + + + + no + 10 + yes + + + + + + + + no + 5 + yes + + + + 0 + 1 + 0 + 0 + yes + + + + yes + Portrait + no + yes + yes + + + + + 0 + yes + yes + + + + + + 0 + 0 + 0 + 0 + yes + + + + yes + Landscape + no + yes + yes + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + + + + + + + Paper + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + tab + + + + + + 8 + no + 0 + yes + + + + yes + 4 + 4 + 4 + 3 + yes + + + + 0 + 1 + 0 + 0 + yes + + + + yes + F_ont... + GTK_RELIEF_NORMAL + yes + yes + + + + + 1 + 2 + 2 + 3 + 0 + 0 + fill + fill + + + + + + yes + no + + GTK_WRAP_WORD + 50 + yes + + + 0 + 1 + 1 + 2 + 0 + 0 + fill + expand|fill + + + + + + yes + no + + GTK_WRAP_WORD + 50 + yes + + + 2 + 3 + 1 + 2 + 0 + 0 + expand|fill + fill + + + + + + yes + no + + GTK_WRAP_WORD + 50 + yes + + + 1 + 2 + 1 + 2 + 0 + 0 + fill + fill + + + + + + yes + no + + GTK_WRAP_WORD + 50 + yes + + + 0 + 1 + 3 + 4 + 0 + 0 + fill + expand|fill + + + + + + yes + no + + GTK_WRAP_WORD + 5 + yes + + + 1 + 2 + 3 + 4 + 0 + 0 + fill + fill + + + + + + yes + no + + GTK_WRAP_WORD + 50 + yes + + + 2 + 3 + 3 + 4 + 0 + 0 + fill + fill + + + + + + 0.5 + 1 + 1 + 0 + yes + + + + no + 0 + yes + + + + Header + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + yes + + 0 + yes + yes + + + 0 + no + no + + + + + + + 0 + 1 + 0 + 1 + 0 + 0 + expand|fill + fill + + + + + + 0.5 + 1 + 1 + 0 + yes + + + + no + 0 + yes + + + + Footer: + GTK_JUSTIFY_CENTER + no + 0 + 0.5 + 0 + 0 + yes + + + 0 + no + no + + + + + + yes + yes + + 0 + yes + yes + + + 0 + no + no + + + + + + + 0 + 1 + 2 + 3 + 0 + 0 + expand|fill + fill + + + + + + 0 + 1 + 0 + 0 + yes + + + + yes + _Font... + GTK_RELIEF_NORMAL + yes + yes + + + + + 1 + 2 + 0 + 1 + 0 + 0 + fill + fill + + + + + 0 + yes + yes + + + + + + no + 0 + yes + + + + GTK_ORIENTATION_HORIZONTAL + GTK_TOOLBAR_ICONS + yes + + + + + + + + + + + + + + + + + + + + + + + 0 + yes + no + + + + + 0 + no + yes + + + + + + yes + Reverse on even pages + no + yes + yes + + + 0 + no + no + + + + + + + + Header/Footer + GTK_JUSTIFY_CENTER + no + 0.5 + 0.5 + 0 + 0 + yes + + + tab + + + + + 0 + yes + yes + + + + + 0 + yes + yes + + - - - - GtkVBox - vbox-contact-print-style-editor - False - 5 - - 0 - True - True - - - - GtkHBox - hbox2 - 5 - False - 16 - - 0 - True - True - - - - GtkLabel - label8 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - label-style-name - True - False - True - 0 - - - 0 - False - False - - - - - - GtkNotebook - notebook1 - True - True - True - GTK_POS_TOP - False - 2 - 2 - False - - 0 - True - True - - - - GtkVBox - vbox2 - 5 - False - 5 - - - GtkAlignment - alignment1 - 0.5 - 0.5 - 0 - 0 - - 0 - True - True - - - - GtkFrame - frame5 - - 0 - GTK_SHADOW_ETCHED_IN - - - Placeholder - - - - - - GtkHBox - hbox1 - True - 7 - - 0 - True - True - - - - GtkFrame - frame6 - - 0 - GTK_SHADOW_ETCHED_IN - - 0 - True - True - - - - GtkAlignment - alignment4 - 0 - 0 - 0 - 0 - - - GtkTable - table1 - 8 - 6 - 5 - False - 0 - 0 - - - GtkLabel - label5 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - 1 - 4 - 5 - 0 - 0 - False - False - False - False - True - True - - - - - GtkLabel - label4 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - 1 - 0 - 1 - 0 - 0 - False - False - False - False - True - True - - - - - GtkAlignment - alignment2 - 0 - 0.5 - 0 - 0 - - 1 - 5 - 0 - 1 - 0 - 0 - False - False - False - False - True - True - - - - GtkRadioButton - radiobutton1 - True - - True - True - - - - - GtkCheckButton - checkbutton1 - True - - False - True - - 1 - 5 - 4 - 5 - 0 - 0 - False - False - False - False - True - True - - - - - GtkCheckButton - checkbutton2 - True - - False - True - - 1 - 5 - 5 - 6 - 0 - 0 - False - False - False - False - True - True - - - - - GtkAlignment - alignment3 - 0 - 0.5 - 0 - 0 - - 1 - 5 - 1 - 2 - 0 - 0 - False - False - False - False - True - True - - - - GtkRadioButton - radiobutton2 - True - - False - True - - - - - GtkLabel - label6 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - 3 - 2 - 3 - 0 - 2 - False - False - False - False - True - True - - - - - GtkLabel - label7 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - 3 - 3 - 4 - 0 - 2 - False - False - False - False - True - True - - - - - GtkAlignment - alignment6 - 0 - 0.5 - 0 - 0 - - 3 - 4 - 3 - 4 - 0 - 2 - False - False - False - False - True - True - - - - GtkSpinButton - spinbutton2 - True - 1 - 0 - False - GTK_UPDATE_ALWAYS - False - False - 2 - 0 - 100 - 1 - 10 - 10 - - - - - GtkAlignment - alignment5 - 0 - 0.5 - 0 - 0 - - 3 - 4 - 2 - 3 - 0 - 2 - False - False - False - False - True - True - - - - GtkSpinButton - spinbutton1 - 45 - True - 1 - 0 - False - GTK_UPDATE_ALWAYS - False - False - 1 - 0 - 100 - 1 - 10 - 10 - - - - - - - - GtkVBox - vbox3 - False - 8 - - 0 - True - True - - - - GtkFrame - frame7 - - 0 - GTK_SHADOW_ETCHED_IN - - 0 - True - True - - - - GtkTable - table2 - 8 - 2 - 2 - False - 13 - 8 - - - GtkAlignment - alignment7 - 0.5 - 1 - 1 - 0 - - 1 - 2 - 1 - 2 - 0 - 0 - False - False - False - False - True - True - - - - GtkButton - button6 - True - - GTK_RELIEF_NORMAL - - - - - GtkAlignment - alignment8 - 0.5 - 1 - 1 - 0 - - 1 - 2 - 0 - 1 - 0 - 0 - False - False - False - False - True - True - - - - GtkButton - button5 - 90 - True - - GTK_RELIEF_NORMAL - - - - - GtkVBox - vbox4 - False - 0 - - 0 - 1 - 0 - 1 - 0 - 0 - True - False - False - False - True - True - - - - GtkLabel - label10 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - entry3 - 100 - True - True - True - 0 - 10 pt. Tahoma - - 0 - False - False - - - - - - GtkVBox - vbox5 - False - 0 - - 0 - 1 - 1 - 2 - 0 - 0 - True - False - False - False - True - True - - - - GtkLabel - label9 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - entry2 - 100 - True - True - True - 0 - 8 pt. Tahoma - - 0 - False - False - - - - - - - - GtkFrame - frame8 - - 0 - GTK_SHADOW_ETCHED_IN - - 0 - True - True - - - - GtkCheckButton - checkbutton3 - True - - False - True - - - - - - - - GtkLabel - Notebook:tab - label1 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - GtkHBox - hbox3 - True - 0 - - - GtkVBox - vbox6 - False - 0 - - 0 - True - True - - - - GtkFrame - frame9 - - 0 - GTK_SHADOW_ETCHED_IN - - 0 - True - True - - - - GtkVBox - vbox16 - 10 - False - 0 - - - GtkVBox - vbox17 - False - 0 - - 0 - True - True - - - - GtkLabel - label21 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkScrolledWindow - scrolledwindow1 - GTK_POLICY_ALWAYS - GTK_POLICY_ALWAYS - GTK_UPDATE_CONTINUOUS - GTK_UPDATE_CONTINUOUS - - 0 - True - True - - - - GtkCList - clist1 - True - 1 - 80 - GTK_SELECTION_SINGLE - False - GTK_SHADOW_IN - - - GtkLabel - CList:title - label26 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - - - - GtkVBox - vbox18 - False - 0 - - 0 - True - True - - - - GtkLabel - label24 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkHBox - hbox5 - True - 0 - - 0 - True - True - - - - GtkLabel - label27 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - entry9 - 1 - True - True - True - 0 - - - 0 - True - True - - - - - GtkLabel - label28 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - entry10 - 1 - True - True - True - 0 - - - 0 - True - True - - - - - - - GtkVBox - vbox19 - False - 0 - - 0 - True - True - - - - GtkLabel - label25 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkCombo - combo1 - False - True - False - True - False - - - 0 - False - False - - - - GtkEntry - GtkCombo:entry - combo-entry1 - True - True - True - 0 - - - - - - - - - GtkFrame - frame10 - - 0 - GTK_SHADOW_ETCHED_IN - - 0 - True - True - - - - GtkTable - table4 - 15 - 2 - 4 - True - 6 - 9 - - - GtkLabel - label29 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - 1 - 0 - 1 - 0 - 0 - False - True - False - False - True - True - - - - - GtkLabel - label30 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - 1 - 1 - 2 - 0 - 0 - False - True - False - False - True - True - - - - - GtkLabel - label31 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 2 - 3 - 0 - 1 - 0 - 0 - False - True - False - False - True - True - - - - - GtkEntry - entry11 - 1 - True - True - True - 0 - - - 1 - 2 - 0 - 1 - 0 - 0 - True - False - False - False - True - False - - - - - GtkEntry - entry12 - 1 - True - True - True - 0 - - - 3 - 4 - 0 - 1 - 0 - 0 - True - False - False - False - True - False - - - - - GtkEntry - entry13 - 1 - True - True - True - 0 - - - 3 - 4 - 1 - 2 - 0 - 0 - True - False - False - False - True - False - - - - - GtkEntry - entry14 - 1 - True - True - True - 0 - - - 1 - 2 - 1 - 2 - 0 - 0 - True - False - False - False - True - False - - - - - GtkLabel - label32 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 2 - 3 - 1 - 2 - 0 - 0 - False - True - False - False - True - True - - - - - - - - GtkVBox - vbox7 - False - 0 - - 0 - True - True - - - - GtkFrame - frame11 - - 0 - GTK_SHADOW_ETCHED_IN - - 0 - True - True - - - - GtkVBox - vbox8 - 10 - False - 0 - - - GtkVBox - vbox20 - False - 0 - - 0 - True - True - - - - GtkLabel - label33 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkScrolledWindow - scrolledwindow2 - GTK_POLICY_ALWAYS - GTK_POLICY_ALWAYS - GTK_UPDATE_CONTINUOUS - GTK_UPDATE_CONTINUOUS - - 0 - True - True - - - - GtkCList - clist2 - True - 1 - 80 - GTK_SELECTION_SINGLE - False - GTK_SHADOW_IN - - - GtkLabel - CList:title - label35 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - - - - GtkVBox - vbox21 - False - 0 - - 0 - True - True - - - - GtkLabel - label34 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkHBox - hbox6 - True - 0 - - 0 - True - True - - - - GtkLabel - label36 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - entry15 - 1 - True - True - True - 0 - - - 0 - True - True - - - - - GtkLabel - label37 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - entry16 - 1 - True - True - True - 0 - - - 0 - True - True - - - - - - - - - GtkFrame - frame12 - - 0 - GTK_SHADOW_ETCHED_IN - - 0 - True - True - - - - GtkHBox - hbox4 - False - 10 - - - Placeholder - - - - GtkVBox - vbox9 - False - 5 - - 0 - True - True - - - - GtkAlignment - alignment9 - 0 - 1 - 0 - 0 - - 0 - True - True - - - - GtkRadioButton - radiobutton3 - True - - False - True - - - - - GtkAlignment - alignment10 - 0 - 0 - 0 - 0 - - 0 - True - True - - - - GtkRadioButton - radiobutton4 - True - - False - True - - - - - - - - - - GtkLabel - Notebook:tab - label2 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - - GtkVBox - vbox10 - 8 - False - 0 - - - GtkTable - table5 - 4 - 3 - True - 4 - 4 - - 0 - True - True - - - - GtkAlignment - alignment15 - 0 - 1 - 0 - 0 - - 1 - 2 - 2 - 3 - 0 - 0 - False - False - False - False - True - True - - - - GtkButton - button11 - True - - GTK_RELIEF_NORMAL - - - - - GtkText - text10 - 50 - True - False - - - 0 - 1 - 1 - 2 - 0 - 0 - False - True - False - False - True - True - - - - - GtkText - text11 - 50 - True - False - - - 2 - 3 - 1 - 2 - 0 - 0 - True - False - False - False - True - True - - - - - GtkText - text12 - 50 - True - False - - - 1 - 2 - 1 - 2 - 0 - 0 - False - False - False - False - True - True - - - - - GtkText - text13 - 50 - True - False - - - 0 - 1 - 3 - 4 - 0 - 0 - False - True - False - False - True - True - - - - - GtkText - text14 - 5 - True - False - - - 1 - 2 - 3 - 4 - 0 - 0 - False - False - False - False - True - True - - - - - GtkText - text15 - 50 - True - False - - - 2 - 3 - 3 - 4 - 0 - 0 - False - False - False - False - True - True - - - - - GtkAlignment - alignment16 - 0.5 - 1 - 1 - 0 - - 0 - 1 - 0 - 1 - 0 - 0 - True - False - False - False - True - True - - - - GtkVBox - vbox14 - False - 0 - - - GtkLabel - label14 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - entry7 - True - True - True - 0 - - - 0 - False - False - - - - - - - GtkAlignment - alignment17 - 0.5 - 1 - 1 - 0 - - 0 - 1 - 2 - 3 - 0 - 0 - True - False - False - False - True - True - - - - GtkVBox - vbox15 - False - 0 - - - GtkLabel - label15 - - GTK_JUSTIFY_CENTER - False - 0 - 0.5 - 0 - 0 - - 0 - False - False - - - - - GtkEntry - entry8 - True - True - True - 0 - - - 0 - False - False - - - - - - - GtkAlignment - alignment14 - 0 - 1 - 0 - 0 - - 1 - 2 - 0 - 1 - 0 - 0 - False - False - False - False - True - True - - - - GtkButton - button10 - True - - GTK_RELIEF_NORMAL - - - - - - GtkHBox - hbox7 - False - 0 - - 0 - False - True - - - - GtkToolbar - toolbar1 - GTK_ORIENTATION_HORIZONTAL - GTK_TOOLBAR_ICONS - 5 - GTK_TOOLBAR_SPACE_EMPTY - GTK_RELIEF_NORMAL - True - - 0 - True - False - - - - Placeholder - - - - Placeholder - - - - Placeholder - - - - Placeholder - - - - Placeholder - - - - - - GtkCheckButton - checkbutton4 - True - - False - True - - 0 - False - False - - - - - - GtkLabel - Notebook:tab - label3 - - GTK_JUSTIFY_CENTER - False - 0.5 - 0.5 - 0 - 0 - - - + + 4 + yes + yes + + - - - + diff --git a/addressbook/printing/test-contact-print-style-editor.c b/addressbook/printing/test-contact-print-style-editor.c index 0ac169468c..48bed93450 100644 --- a/addressbook/printing/test-contact-print-style-editor.c +++ b/addressbook/printing/test-contact-print-style-editor.c @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include "e-contact-print-style-editor.h" /* This is a horrible thing to do, but it is just a test. */ @@ -65,7 +65,10 @@ int main( int argc, char *argv[] ) /* bindtextdomain (PACKAGE, GNOMELOCALEDIR); textdomain (PACKAGE);*/ - gnome_init( "Contact Print Style Editor Test", VERSION, argc, argv); + gnome_program_init ("Contact Print Style Editor Test", VERSION, + LIBGNOMEUI_MODULE, + argc, argv, + NULL); glade_gnome_init (); @@ -76,13 +79,13 @@ int main( int argc, char *argv[] ) gnome_app_set_contents( GNOME_APP( app ), editor ); /* Connect the signals */ - gtk_signal_connect( GTK_OBJECT( app ), "destroy", - GTK_SIGNAL_FUNC( destroy_callback ), - ( gpointer ) app ); + g_signal_connect( app, "destroy", + G_CALLBACK ( destroy_callback ), + ( gpointer ) app ); gtk_widget_show_all( app ); - gtk_main(); + bonobo_main(); /* Not reached. */ return 0; diff --git a/addressbook/printing/test-print.c b/addressbook/printing/test-print.c index fc868318d8..b9d0592474 100644 --- a/addressbook/printing/test-print.c +++ b/addressbook/printing/test-print.c @@ -23,10 +23,8 @@ #include #include -#include -#include #include -#include +#include #include #include "e-contact-print.h" @@ -66,7 +64,10 @@ int main( int argc, char *argv[] ) /* bindtextdomain (PACKAGE, GNOMELOCALEDIR); textdomain (PACKAGE);*/ - gnome_init( "Contact Print Test", VERSION, argc, argv); + gnome_program_init ("Contact Print Test", VERSION, + LIBGNOMEUI_MODULE, + argc, argv, + NULL); glade_gnome_init (); @@ -77,9 +78,9 @@ int main( int argc, char *argv[] ) print = e_contact_print_dialog_new(NULL, NULL); gtk_widget_show_all(print); - gtk_signal_connect(GTK_OBJECT(print), "close", GTK_SIGNAL_FUNC(test_close), NULL); + g_signal_connect(print, "close", G_CALLBACK(test_close), NULL); - gtk_main(); + bonobo_main(); /* Not reached. */ return 0; -- cgit v1.2.3