/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */ /* * e-printable.c * Copyright 2000, 2001, Ximian, Inc. * * Authors: * Chris Lahey * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public * License, version 2, as published by the Free Software Foundation. * * This library is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public * License along with this library; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA * 02111-1307, USA. */ #include #include #include "gal/util/e-util.h" #include "e-printable.h" #define EP_CLASS(e) ((EPrintableClass *)((GtkObject *)e)->klass) #define PARENT_TYPE GTK_TYPE_OBJECT static GtkObjectClass *e_printable_parent_class; enum { PRINT_PAGE, DATA_LEFT, RESET, HEIGHT, WILL_FIT, LAST_SIGNAL }; static guint e_printable_signals [LAST_SIGNAL] = { 0, }; static void e_printable_class_init (GtkObjectClass *object_class) { EPrintableClass *klass = E_PRINTABLE_CLASS(object_class); e_printable_parent_class = g_type_class_ref (PARENT_TYPE); e_printable_signals [PRINT_PAGE] = g_signal_new ("print_page", G_OBJECT_CLASS_TYPE (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (EPrintableClass, print_page), NULL, NULL, e_marshal_NONE__OBJECT_DOUBLE_DOUBLE_BOOLEAN, G_TYPE_NONE, 4, G_TYPE_OBJECT, G_TYPE_DOUBLE, G_TYPE_DOUBLE, G_TYPE_BOOLEAN); e_printable_signals [DATA_LEFT] = g_signal_new ("data_left", G_OBJECT_CLASS_TYPE (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (EPrintableClass, data_left), NULL, NULL, e_marshal_BOOLEAN__NONE, G_TYPE_BOOLEAN, 0, G_TYPE_NONE); e_printable_signals [RESET] = g_signal_new ("reset", G_OBJECT_CLASS_TYPE (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (EPrintableClass, reset), NULL, NULL, e_marshal_NONE__NONE, G_TYPE_NONE, 0, G_TYPE_NONE); e_printable_signals [HEIGHT] = g_signal_new ("height", G_OBJECT_CLASS_TYPE (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (EPrintableClass, height), NULL, NULL, e_marshal_DOUBLE__OBJECT_DOUBLE_DOUBLE_BOOLEAN, G_TYPE_DOUBLE, 4, G_TYPE_OBJECT, G_TYPE_DOUBLE, G_TYPE_DOUBLE, G_TYPE_BOOLEAN); e_printable_signals [WILL_FIT] = g_signal_new ("will_fit", G_OBJECT_CLASS_TYPE (object_class), G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (EPrintableClass, will_fit), NULL, NULL, e_marshal_BOOLEAN__OBJECT_DOUBLE_DOUBLE_BOOLEAN, G_TYPE_BOOLEAN, 4, G_TYPE_OBJECT, G_TYPE_DOUBLE, G_TYPE_DOUBLE, G_TYPE_BOOLEAN); klass->print_page = NULL; klass->data_left = NULL; klass->reset = NULL; klass->height = NULL; klass->will_fit = NULL; } E_MAKE_TYPE (e_printable, "EPrintable", EPrintable, e_printable_class_init, NULL, PARENT_TYPE) EPrintable * e_printable_new(void) { return E_PRINTABLE(g_object_new(E_PRINTABLE_TYPE, NULL)); } void e_printable_print_page (EPrintable *e_printable, GnomePrintContext *context, gdouble width, gdouble height, gboolean quantized) { g_return_if_fail (e_printable != NULL); g_return_if_fail (E_IS_PRINTABLE (e_printable)); g_signal_emit (e_printable, e_printable_signals [PRINT_PAGE], 0, context, width, height, quantized); } gboolean e_printable_data_left (EPrintable *e_printable) { gboolean ret_val; g_return_val_if_fail (e_printable != NULL, FALSE); g_return_val_if_fail (E_IS_PRINTABLE (e_printable), FALSE); g_signal_emit (e_printable, e_printable_signals [DATA_LEFT], 0, &ret_val); return ret_val; } void e_printable_reset (EPrintable *e_printable) { g_return_if_fail (e_printable != NULL); g_return_if_fail (E_IS_PRINTABLE (e_printable)); g_signal_emit (e_printable, e_printable_signals [RESET], 0); } gdouble e_printable_height (EPrintable *e_printable, GnomePrintContext *context, gdouble width, gdouble max_height, gboolean quantized) { gdouble ret_val; g_return_val_if_fail (e_printable != NULL, -1); g_return_val_if_fail (E_IS_PRINTABLE (e_printable), -1); g_signal_emit (e_printable, e_printable_signals [HEIGHT], 0, context, width, max_height, quantized, &ret_val); return ret_val; } gboolean e_printable_will_fit (EPrintable *e_printable, GnomePrintContext *context, gdouble width, gdouble max_height, gboolean quantized) { gboolean ret_val; g_return_val_if_fail (e_printable != NULL, -1); g_return_val_if_fail (E_IS_PRINTABLE (e_printable), -1); g_signal_emit (e_printable, e_printable_signals [WILL_FIT], 0, context, width, max_height, quantized, &ret_val); return ret_val; } /span> | | | | | | 2006-09-04 Harish Krishnaswamy <kharish@novell.com> * C/evolution.xml: Update the doc for Evolution 2.8. Committing on behalf of Radhika Nair <pradhika@novell.com> svn path=/trunk/; revision=32737 * adding localized (german) quick reference card. see bug #307856.Andre Klapper2006-07-135-1/+137 | | | | | | | | | | | | | | 2006-07-13 Andre Klapper <a9016009@gmx.de> * configure.in: * help/quickref/Makefile.am: * help/quickref/de/Makefile.am: * help/quickref/de/quickref.pdf: * help/quickref/de/quickref.tex: adding localized (german) quick reference card. see bug #307856. svn path=/trunk/; revision=32298 * Added Spanish doc translation.Francisco Javier F. Serrador2006-05-171-0/+7063 | | | | | | | | 2006-05-17 Francisco Javier F. Serrador <serrador@cvs.gnome.org> * evolution-doc-2.6.po: Added Spanish doc translation. svn path=/trunk/; revision=31992 * fixing 3 bugs. Fixes bug 339094.Andre Klapper2006-04-252-3/+7 | | | | | | | | 2006-04-25 Andre Klapper <a9016009@gmx.de> * C/evolution.xml: fixing 3 bugs. Fixes bug 339094. svn path=/trunk/; revision=31889 * Updating the doc for 2.6 and fixing bugs which went in by updating the docAndre Klapper2006-03-232-29/+34 | | | | | | | | | 2006-03-23 Andre Klapper <a9016009@gmx.de> * C/evolution.xml: Updating the doc for 2.6 and fixing bugs which went in by updating the doc for 2.6. svn path=/trunk/; revision=31741 * Added new images for the 2.6 documentation.Srinivasa Ragavan2006-03-063-0/+6 | | | | svn path=/trunk/; revision=31665 * Updating the doc for 2.6.Srinivasa Ragavan2006-03-062-330/+774 | | | | | | | | 2006-03-06 Srinivasa Ragavan <sragavan@novell.com> * C/evolution.xml: Updating the doc for 2.6. svn path=/trunk/; revision=31661 * Fixing a typo and pdf.Andre Klapper2006-02-283-1/+4 | | | | | | | 2006-02-27 Andre Klapper <a9016009@gmx.de> * quickref/C/quickref.tex: Fixing a typo and pdf. svn path=/trunk/; revision=31599 * Updating quickref and pdf. Fixes bug 316797.Andre Klapper2006-02-283-41/+50 | | | | | | | | 2006-02-27 Andre Klapper <a9016009@gmx.de> * quickref/C/quickref.tex: Updating quickref and pdf. Fixes bug 316797. svn path=/trunk/; revision=31598 * changing start menu category and description. Fixes bug 325763.Andre Klapper2006-01-202-3/+8 | | | | | | | | | 2006-01-19 Andre Klapper <a9016009@gmx.de> * C/evolution-C.omf: changing start menu category and description. Fixes bug 325763. svn path=/trunk/; revision=31242 * Fix for #316297Harish Krishnaswamy2005-10-052-1/+5 | | | | svn path=/trunk/; revision=30491 * Updating and fixing several typos, wrong keyboard shortcuts andAndre Klapper2005-09-152-18/+26 | | | | | | | | | | | | 2005-06-15 Andre Klapper <a9016009@gmx.de> * quickref/C/quickref.tex: Updating and fixing several typos, wrong keyboard shortcuts and inconsistencies (fixes bug #268024) committed on behalf of Andre since he does not have commit rights -partha svn path=/trunk/; revision=30349 * Doc commit - Quickref.pdf submitted by Andre KlapperHarish Krishnaswamy2005-08-301-0/+0 | | | | | | and reviewed by Mark Moulder svn path=/trunk/; revision=30285 * Committed on behalf of Jessica. Changes are made to the ProxySankar P2005-08-292-30/+20 | | | | | | | | | 2005-08-29 Sankar P <psankar@novell.com> * C/evolution.xml: Committed on behalf of Jessica. Changes are made to the Proxy documentation. svn path=/trunk/; revision=30283 * Update references to bugzilla and related hyperlinks.Harish Krishnaswamy2005-08-262-6/+11 | | | | | | | | | 2006-08-26 Harish Krishnaswamy <kharish@novell.com> * C/evolution.xml: Update references to bugzilla and related hyperlinks. svn path=/trunk/; revision=30257 * Update documentation on behalf of Mark MoulderHarish Krishnaswamy2005-08-262-479/+961 | | | | | | | | | 2006-08-26 Harish Krishnaswamy <kharish@novell.com> * C/evolution.xml: Update documentation on behalf of Mark Moulder svn path=/trunk/; revision=30255 * Change references to the term "vfolder" to use the term "Search Folder"Rodney Dawes2005-08-081-27/+27 | | | | | | | | | 2005-08-07 Rodney Dawes <dobey@novell.com> * help/C/evolution.xml: Change references to the term "vfolder" to use the term "Search Folder" instead svn path=/trunk/; revision=30025 * Pull from 2.10 branchJP Rosevear2005-03-152-1620/+2101 | | | | svn path=/trunk/; revision=29018 * Fixes #71554JP Rosevear2005-02-202-1/+7 | | | | | | | | | | 2005-02-19 JP Rosevear <jpr@novell.com> Fixes #71554 * C/evolution-2.2.xml: add id="index" svn path=/trunk/; revision=28820 * Add new images to figures Update and add new imagesRodney Dawes2004-10-1111-0/+16 | | | | | | | | | | | 2004-10-11 Rodney Dawes <dobey@novell.com> * C/Makefile.am: Add new images to figures * C/figures/*.(png|eps): Update and add new images * C/evolution.xml: Update to lastest version of docs svn path=/trunk/; revision=27536 * Add unversioned xml/omf to EXTRA_DISTRodney Dawes2004-10-052-0/+8 | | | | | | | | 2004-10-04 Rodney Dawes <dobey@novell.com> * C/Makefile.am: Add unversioned xml/omf to EXTRA_DIST svn path=/trunk/; revision=27461 * Don't requires entities hereRodney Dawes2004-09-1441-10689/+3971 | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-09-13 Rodney Dawes <dobey@novell.com> * xmldocs.make: Don't requires entities here * C/Makefile.am: Add new figures to the list of images Generate versioned xml/omf files based on $(BASE_VERSION) Fix up CLEANFILES to include the stuff we generate * C/POTFILES.in: * C/apx-*.xml: * C/config-*.xml: * C/evolution-1.5-C.omf: * C/evolution-1.5.xml: * C/legal.xml: * C/menuref.xml: * C/preface.xml: * C/topic.dat: * C/usage-*.xml: Remove all of these files from CVS * C/evolution-C.omf: * C/evolution.xml: Add these files to replace the removed files above * C/figure/*_a.(png|gif): Add new screenshots svn path=/trunk/; revision=27253 * Mergin the latest translation into headIsmael Olea2004-09-0245-6091/+22590 | | | | svn path=/trunk/; revision=27110 * Obsoletes files.Ismael Olea2004-09-0216-12730/+0 | | | | svn path=/trunk/; revision=27109 * Good enough for government work.Aaron Weber2004-07-234-223/+366 | | | | svn path=/trunk/; revision=26707 * Variety of updatesAaron Weber2004-07-235-938/+599 | | | | svn path=/trunk/; revision=26704 * Remove glossterms in favor of links; add a lot more edits, specialAaron Weber2004-07-1411-336/+344 | | | | | | thanks to Angela Boyle. svn path=/trunk/; revision=26642 * ScrubMonkey submitted comments for preface.xml. Someone put &mdash; ↵Aaron Weber2004-07-096-109/+65 | | | | | | entities in this and I removed them because some parsers will choke especially since we haven't defined them earlier. svn path=/trunk/; revision=26599 * add NNTP section, fix name to conform, mostly, with new novell naming ↵Aaron Weber2004-05-1314-153/+154 | | | | | | conventions. svn path=/trunk/; revision=25885 * Update phrasing. Also the apx-authors file seemed to have been corrupted, so ↵Aaron Weber2004-05-116-128/+24 | | | | | | I replaced it. svn path=/trunk/; revision=25844 * fix a small error.Aaron Weber2004-03-311-9/+3 | | | | svn path=/trunk/; revision=25246 * wide variety of changes.Aaron Weber2004-03-048-131/+113 | | | | svn path=/trunk/; revision=24954 * C2004-02-10 Aaron Weber <aaron@ximian.com>Aaron Weber2004-02-1112-679/+540 | | | | | | | | | | | | | * C/usage-mail.xml: Fix bugs noted by Dimitrios. Special thanks to him for this patch. * C/usage-mail-org.xml: especially to filtering section * C/usage-print.xml: Remove, this is not a useful section. * C/usage-contacts: spelling * C/config-prefs.xml: lots of user-suggested corrections here. * C/Makefile.am: delete printing page and related images. * Also some places in menuref and so forth. svn path=/trunk/; revision=24693 * spamfiltering charsets and input methods. assign copyright to Novell, addAaron Weber2004-01-285-10/+141 | | | | | | | | | | 2004-01-27 Aaron Weber <aaron@ximian.com> * C/usage-mail-org.xml: spamfiltering * C/usage-mail.xml: charsets and input methods. * C/evolution-1.5.xml: assign copyright to Novell, add 2004. * C/legal.xml: Novell/XImian switcheroo svn path=/trunk/; revision=24480 * quick ref docsDavid Trowbridge2004-01-289-1/+18605 | | | | | | | | 2004-01-26 David Trowbridge <trowbrds@cs.colorado.edu> * quick ref docs svn path=/trunk/; revision=24474 * Remove usage-exec-summary.xmlRodney Dawes2004-01-102-1/+4 | | | | | | | | 2004-01-09 Rodney Dawes <dobey@ximian.com> * C/Makefile.am (entities): Remove usage-exec-summary.xml svn path=/trunk/; revision=24141 * remove old graphic files help/C/evolution-1.5.xml updated style notes,Aaron Weber2004-01-0821-1126/+884 | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-01-07 Aaron Weber <aaron@ximian.com> * help/C/Makefile.am: remove old graphic files * help/C/evolution-1.5.xml updated style notes, date, version * help/C/apx-authors.xml: fix <application> usage * help/C/apx-gloss.xml: fix <application> and <guibutton> usage * help/C/config-prefs.xml: same * help/C/config-sync.xml: same * help/C/menuref.xml: same * help/C/usage-calendar.xml: same * help/C/usage-contact.xml: same * help/C/usage-exchange.xml: same * help/C/usage-mail-org.xml: same * help/C/usage-mail.xml: same * help/C/usage-print.xml: same * help/C/usage-sync.xml : same * help/C/usage-mainwindow.xml same, plus * help/C/preface.xml same, plus removed Summary * help/C/topic.dat Remove Summary * help/C/usage-exec-summary.xml: Remove summary * help/C/figures/folder-bar.png: delete * help/C/figures/summary.png: delete svn path=/trunk/; revision=24098 * Fix typo from bug 51686Aaron Weber2003-12-051-1/+1 | | | | svn path=/trunk/; revision=23637 * Switch version to 1.5JP Rosevear2003-11-174-2/+6 | | | | | | | | 2003-11-17 JP Rosevear <jpr@ximian.com> * C/Makefile.am: Switch version to 1.5 svn path=/trunk/; revision=23390 * remove extraneous note.Aaron Weber2003-11-081-24/+0 | | | | svn path=/trunk/; revision=23229 * Merge new-ui-branch into the trunk.Ettore Perazzoli2003-10-2220-19/+21 | | | | svn path=/trunk/; revision=22966 * fixing typos, etcIsmael Olea2003-10-1010-221/+110 | | | | svn path=/trunk/; revision=22859 * *** empty log message ***Aaron Weber2003-10-083-32/+49 | | | | svn path=/trunk/; revision=22810 * Adding the topic.datIsmael Olea2003-08-091-0/+11 | | | | svn path=/trunk/; revision=22150 * Mergin the Spanish translation of Evo 1.2 help with heapIsmael Olea2003-08-0921-5869/+5954 | | | | svn path=/trunk/; revision=22149 * fix typo in encryption section.Aaron Weber2003-07-152-17/+120 | | | | | | | | | | 2003-07-14 Aaron Weber <aaron@ximian.com> * C/usage-mail.xml: fix typo in encryption section. * C/menuref.xml: add command line reference. svn path=/trunk/; revision=21808 * Put the ChangeLog.pre-1-4 in the Makefiles.Ettore Perazzoli2003-06-132-2/+7 | | | | svn path=/trunk/; revision=21426 * Roll over ChangeLogs.Ettore Perazzoli2003-06-104-2085/+2085 | | | | svn path=/trunk/; revision=21387 * New screenshots using the Industrial theme for XD2.Aaron Weber2003-06-0327-4/+2 | | | | svn path=/trunk/; revision=21372 * Removed keybindings and detect links prefs from the composer prefs.Aaron Weber2003-05-221-21/+0 | | | | svn path=/trunk/; revision=21310 * This and some more...Aaron Weber2003-05-207-154/+282 | | | | | | | | | | | | | | | | | | | | | 2003-05-19 Aaron Weber <aaron@ximian.com> * C/config-prefs.xml: fix glossterms not to be inside <guilabel>s. None of these should be inside <term>s anyway. 2003-05-02 Aaron Weber <aaron@ximian.com> * C/usage-mail-org.xml: Filter-new-fig.png * C/figures/filter-assist-fig.png: removed this figure image. Didn't need it and -new. * C/figures/small_desktop.png: removed this figure image. Not sure why we had it. * C/Makefile.am: remove filter-assist-fig.png, 2003-04-15 Aaron Weber <aaron@ximian.com> * C/usage-exchange.xml: delegation svn path=/trunk/; revision=21255 * detailed markupIsmael Olea2003-05-053-79/+80 | | | | svn path=/trunk/; revision=21103 * Correct <figure> tags.Aaron Weber2003-05-013-46/+48 | | | | svn path=/trunk/; revision=21037 * Add figures/outline.png to $(figs)Rodney Dawes2003-04-302-1/+6 | | | | | | | | 2003-04-27 Rodney Dawes <dobey@ximian.com> * C/Makefile.am: Add figures/outline.png to $(figs) svn path=/trunk/; revision=21017 * correcting the order and the callouts filenamesIsmael Olea2003-04-281-7/+7 | | | | svn path=/trunk/; revision=20981 * some Docbook tagginIsmael Olea2003-04-271-4/+4 | | | | svn path=/trunk/; revision=20976 * filter order.Aaron Weber2003-04-261-0/+7 | | | | svn path=/trunk/; revision=20970 * toolbar is not strictly a guilabel: «GUILabel identifies text that appears ↵Ismael Olea2003-04-251-1/+1 | | | | | | as a label in a graphical user interface» svn path=/trunk/; revision=20965 * add seriesid tag, maybe this will help building?Aaron Weber2003-04-191-0/+1 | | | | svn path=/trunk/; revision=20890 * delegationAaron Weber2003-04-162-52/+177 | | | | svn path=/trunk/; revision=20856 * A long list of updates for all these files.Aaron Weber2003-04-14